about summary refs log tree commit diff
path: root/src/rt/rust_builtin.cpp
diff options
context:
space:
mode:
authorBrian Anderson <banderson@mozilla.com>2012-05-15 11:34:52 -0700
committerBrian Anderson <banderson@mozilla.com>2012-05-15 16:13:42 -0700
commit7277cd71984e6a09bc2f8a8a828a5e213b485d00 (patch)
tree1bab4372580c8f39c7514923f13fef9da33219e8 /src/rt/rust_builtin.cpp
parent8fe0461f06ac4a7fe9705d2cd62e8bb547975c8f (diff)
downloadrust-7277cd71984e6a09bc2f8a8a828a5e213b485d00.tar.gz
rust-7277cd71984e6a09bc2f8a8a828a5e213b485d00.zip
core: Add task::unkillable
Diffstat (limited to 'src/rt/rust_builtin.cpp')
-rw-r--r--src/rt/rust_builtin.cpp12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/rt/rust_builtin.cpp b/src/rt/rust_builtin.cpp
index 4ba6c299c62..8f5c3c6fa14 100644
--- a/src/rt/rust_builtin.cpp
+++ b/src/rt/rust_builtin.cpp
@@ -805,6 +805,18 @@ rust_global_env_chan_ptr() {
     return task->kernel->get_global_env_chan();
 }
 
+extern "C" void
+rust_task_inhibit_kill() {
+    rust_task *task = rust_get_current_task();
+    task->inhibit_kill();
+}
+
+extern "C" void
+rust_task_allow_kill() {
+    rust_task *task = rust_get_current_task();
+    task->allow_kill();
+}
+
 //
 // Local Variables:
 // mode: C++