diff --git a/src/rt/rust_chan.cpp b/src/rt/rust_chan.cpp index d77b196fd35c..44d45f693e73 100644 --- a/src/rt/rust_chan.cpp +++ b/src/rt/rust_chan.cpp @@ -53,9 +53,8 @@ bool rust_chan::is_associated() { void rust_chan::disassociate() { A(kernel, is_associated(), "Channel must be associated with a port."); - + scoped_lock with(port->referent()->lock); if (port->is_proxy() == false) { - scoped_lock with(port->referent()->lock); KLOG(kernel, task, "disassociating chan: 0x%" PRIxPTR " from port: 0x%" PRIxPTR, this, port->referent());