The following code can be used to demonstrate a bug in ns_cond - has anyone
ran into this, and is there a fix out there?
nsv_set global cond [ns_cond create]
nsv_set global mutex [ns_mutex create]
proc foo {} {
set cond [nsv_get global cond]
set lock [nsv_get global mutex]
ns_cond wait $cond $lock
}
proc bar {} {
ns_cond boadcast [nsv_get global cond]
}
You run foo as many times as you want in different threads of AOLServer,
then you run bar from another thread, and only one of the other threads
wakes up. All other threads are stuck until you bounce your virtual server.
Thoughts?
---
AOLServer 3.4 / Linux