about summary refs log tree commit diff
path: root/src/rt/rust_port.cpp
diff options
context:
space:
mode:
authorBrian Anderson <banderson@mozilla.com>2012-03-14 17:24:19 -0700
committerBrian Anderson <banderson@mozilla.com>2012-03-15 11:10:52 -0700
commitb278d675a231fdfe825c72e499d59e8a3d07ffaa (patch)
tree426a39a89561d56ac72e328aecc64c045a578e18 /src/rt/rust_port.cpp
parent337d860a8777a761267daaad9b561787b10e7c87 (diff)
downloadrust-b278d675a231fdfe825c72e499d59e8a3d07ffaa.tar.gz
rust-b278d675a231fdfe825c72e499d59e8a3d07ffaa.zip
rt: Look up ports through a single port table
Instead of a two-level lookup, just use one big table
Diffstat (limited to 'src/rt/rust_port.cpp')
-rw-r--r--src/rt/rust_port.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/rt/rust_port.cpp b/src/rt/rust_port.cpp
index e28dea0c02e..cf75e113c06 100644
--- a/src/rt/rust_port.cpp
+++ b/src/rt/rust_port.cpp
@@ -11,7 +11,7 @@ rust_port::rust_port(rust_task *task, size_t unit_sz)
         PRIxPTR, (uintptr_t)task, unit_sz, (uintptr_t)this);
 
     task->ref();
-    id = task->register_port(this);
+    id = kernel->register_port(this);
 }
 
 rust_port::~rust_port() {
@@ -39,7 +39,7 @@ void rust_port::deref() {
 void rust_port::begin_detach(uintptr_t *yield) {
     *yield = false;
 
-    task->release_port(id);
+    kernel->release_port_id(id);
 
     scoped_lock with(ref_lock);
     ref_count--;