From d63f8340a5e947cdf6b3ad34d3683f2ae9e5cf84 Mon Sep 17 00:00:00 2001 From: Eric Holk Date: Sat, 13 Aug 2011 18:15:56 -0700 Subject: Properly ref counting to fix valgrind issues on linux. --- src/rt/rust_kernel.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'src/rt/rust_kernel.cpp') diff --git a/src/rt/rust_kernel.cpp b/src/rt/rust_kernel.cpp index 89c06885683..c11a5b69b73 100644 --- a/src/rt/rust_kernel.cpp +++ b/src/rt/rust_kernel.cpp @@ -160,6 +160,7 @@ rust_kernel::get_task_by_id(rust_task_id id) { rust_task *task = NULL; // get leaves task unchanged if not found. task_table.get(id, &task); + if(task) task->ref(); return task; } -- cgit 1.4.1-3-g733a5