diff options
author | rsc <devnull@localhost> | 2005-01-07 20:52:07 +0000 |
---|---|---|
committer | rsc <devnull@localhost> | 2005-01-07 20:52:07 +0000 |
commit | 1aa9c533e0778d9917cdb19f71e3bc7416e8d528 (patch) | |
tree | bdee3906670f8f99083e3e9d18aeff9f4a700c7a /src | |
parent | 8b549a62142839c7e184939fe56850987dded578 (diff) | |
download | plan9port-1aa9c533e0778d9917cdb19f71e3bc7416e8d528.tar.gz plan9port-1aa9c533e0778d9917cdb19f71e3bc7416e8d528.tar.bz2 plan9port-1aa9c533e0778d9917cdb19f71e3bc7416e8d528.zip |
allow lock passing
Diffstat (limited to 'src')
-rw-r--r-- | src/libthread/thread.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/libthread/thread.c b/src/libthread/thread.c index 8a028aa4..120e6514 100644 --- a/src/libthread/thread.c +++ b/src/libthread/thread.c @@ -344,9 +344,10 @@ threadqunlock(QLock *l, ulong pc) { lock(&l->l); //print("qlock unlock %p @%#x by %p (owner %p)\n", l, pc, (*threadnow)(), l->owner); - if(l->owner != (*threadnow)()){ + if(l->owner == 0){ fprint(2, "%s: qunlock pc=0x%lux owner=%p self=%p oops\n", argv0, pc, l->owner, (*threadnow)()); + abort(); } if((l->owner = l->waiting.head) != nil){ delthread(&l->waiting, l->owner); |