fixed the wrong argument handling problem
This commit is contained in:
		| @ -9,6 +9,6 @@ | ||||
| #include 'Process.moo'. | ||||
|  | ||||
| (* -------------------------------------------------------------------------- *) | ||||
| #include 'FFI.moo'. | ||||
| ## #include 'FFI.moo'. | ||||
| #include 'Stdio.moo'. | ||||
| #include 'Console.moo'. | ||||
| ## #include 'Console.moo'. | ||||
|  | ||||
| @ -237,25 +237,23 @@ method(#class,#abstract) xxx. => method(#class) xxx { self subclassResponsibilit | ||||
| 		## arrange the processor to notify upon timeout. | ||||
| 		System signal: s after: seconds. | ||||
|  | ||||
| 		[ | ||||
| 		[  | ||||
| 			## wait on the semaphore group. | ||||
| 			r := self wait. | ||||
| 		] on: Exception do: [:ex | | ||||
| 			r := self wait.  | ||||
|  | ||||
| 			## if the internal semaphore has been signaled,  | ||||
| 			## arrange to return nil to indicate timeout. | ||||
| 			if (r == s) { r := nil } | ||||
| 			elsif (r signalAction notNil) { r signalAction value: r }. | ||||
| 		] ensure: [ | ||||
|  | ||||
| 			## nullify the membership | ||||
| 			self removeSemaphore: s. | ||||
|  | ||||
| 			## cancel the notification arrangement in case it didn't time out. | ||||
| 			System unsignal: s. | ||||
| 			ex throw | ||||
| 		]. | ||||
|  | ||||
| 		## if the internal semaphore has been signaled,  | ||||
| 		## arrange to return nil to indicate timeout. | ||||
| 		if (r == s) { r := nil } | ||||
| 		elsif (r signalAction notNil) { r signalAction value: r }. | ||||
|  | ||||
| 		## nullify the membership | ||||
| 		self removeSemaphore: s. | ||||
|  | ||||
| 		## cancel the notification arrangement in case it didn't time out. | ||||
| 		System unsignal: s. | ||||
|  | ||||
| 		^r. | ||||
| 	}  | ||||
| } | ||||
|  | ||||
		Reference in New Issue
	
	Block a user