fix #4219 - recursive mutex lock
This commit is contained in:
1 parent
e72d0ba804
commit
75dd562a0a
1 file changed
+1
-1
@@ -433,7 +433,7 @@ can_recv :: proc "contextless" (c: ^Raw_Chan) -> bool {
|
||||
can_send :: proc "contextless" (c: ^Raw_Chan) -> bool {
|
||||
sync.guard(&c.mutex)
|
||||
if is_buffered(c) {
|
||||
return len(c) < cap(c)
|
||||
return c.queue.len < c.queue.cap
|
||||
}
|
||||
return sync.atomic_load(&c.r_waiting) > 0
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user