diff options
| author | Brian Anderson <banderson@mozilla.com> | 2012-03-05 20:02:25 -0800 |
|---|---|---|
| committer | Brian Anderson <banderson@mozilla.com> | 2012-03-05 20:02:25 -0800 |
| commit | ee991cae81c644a5f536acb49fff59ec769e61c7 (patch) | |
| tree | 81e5a7becf8a6e12dba9c633ae718feba410ae5f /src/rt/rust_builtin.cpp | |
| parent | 32f7818e7f08c67417720c7883f1400199632766 (diff) | |
| download | rust-ee991cae81c644a5f536acb49fff59ec769e61c7.tar.gz rust-ee991cae81c644a5f536acb49fff59ec769e61c7.zip | |
rt: Add a hack to fix a port detach bug
Diffstat (limited to 'src/rt/rust_builtin.cpp')
| -rw-r--r-- | src/rt/rust_builtin.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/rt/rust_builtin.cpp b/src/rt/rust_builtin.cpp index 14b6d0f1962..14b18a99252 100644 --- a/src/rt/rust_builtin.cpp +++ b/src/rt/rust_builtin.cpp @@ -489,11 +489,15 @@ rust_port_begin_detach(rust_port *port, uintptr_t *yield) { } extern "C" CDECL void +rust_port_end_detach(rust_port *port) { + port->end_detach(); +} + +extern "C" CDECL void del_port(rust_port *port) { rust_task *task = rust_task_thread::get_task(); LOG(task, comm, "del_port(0x%" PRIxPTR ")", (uintptr_t) port); A(task->thread, port->get_ref_count() == 0, "Expected port ref_count == 0"); - port->end_detach(); delete port; } |
