Skip to content

Commit 55608a7

Browse files
committed
---
yaml --- r: 6516 b: refs/heads/master c: 06f4cb4 h: refs/heads/master v: v3
1 parent 1e9be91 commit 55608a7

File tree

3 files changed

+7
-3
lines changed

3 files changed

+7
-3
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
---
2-
refs/heads/master: 766e29c0e1c31f26a44e6c9bc9c30f9be758544d
2+
refs/heads/master: 06f4cb43f6bffe870116f2688dd5d5fc3d0af043

trunk/src/rt/rust_task.cpp

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -178,7 +178,10 @@ rust_task::~rust_task()
178178
I(sched, ref_count == 0); // ||
179179
// (ref_count == 1 && this == sched->root_task));
180180

181-
del_stk(this, stk);
181+
// Delete all the stacks. There may be more than one if the task failed
182+
while (stk != NULL) {
183+
del_stk(this, stk);
184+
}
182185
}
183186

184187
struct spawn_args {

trunk/src/test/run-fail/morestack1.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
// xfail-test
22
// compile-flags:--stack-growth
3+
// error-pattern:explicit failure
34
fn getbig(i: int) {
45
if i != 0 {
56
getbig(i - 1);
@@ -9,5 +10,5 @@ fn getbig(i: int) {
910
}
1011

1112
fn main() {
12-
getbig(10000000);
13+
getbig(100000);
1314
}

0 commit comments

Comments
 (0)