src/JavaMonitor.st
branchjk_new_structure
changeset 1169 8f727dc66647
parent 1159 afe8ab363ca3
child 1172 7795b5618017
--- a/src/JavaMonitor.st	Sun Nov 27 22:56:33 2011 +0000
+++ b/src/JavaMonitor.st	Mon Nov 28 13:03:05 2011 +0000
@@ -205,8 +205,8 @@
 exit
     | thisProcess |
     thisProcess := self activeProcess.
-    (self isOwnedBy: thisProcess) ifTrue: [ self release. ].
-    processesEntered remove: thisProcess.
+    (self isOwnedBy: thisProcess) ifTrue: [ self release. ].    
+    processesEntered remove: thisProcess ifAbsent: nil.
 
     "Created: / 20-11-2011 / 13:21:54 / Marcel Hlopko <hlopkmar@fel.cvut.cz>"
 !
@@ -269,10 +269,8 @@
     self assert: (self isOwnedBy: thisProcess).
     self processesWaitingAdd: thisProcess.
     self releaseAll.
-    "JV@2011-11-25: zero timeout means wait without timeout!!!!!!"
-    timeOut == 0 ifTrue:[
-        waitingSema wait
-    ] ifFalse:[        
+     "JV@2011-11-25: zero timeout means wait without timeout!!!!!!"
+    timeOut == 0 ifTrue: [ waitingSema wait ] ifFalse: [
         waitingSema waitWithTimeoutMs: timeOut
     ].
     self acquire.
@@ -280,6 +278,7 @@
 
     "Created: / 22-11-2011 / 12:52:45 / Marcel Hlopko <hlopkmar@fel.cvut.cz>"
     "Modified (comment): / 25-11-2011 / 18:30:59 / Jan Vrany <jan.vrany@fit.cvut.cz>"
+    "Modified: / 28-11-2011 / 14:01:25 / Marcel Hlopko <hlopkmar@fel.cvut.cz>"
 ! !
 
 !JavaMonitor methodsFor:'queries'!