diff options
author | Tom Nichols <tmnichols@gmail.com> | 2010-06-28 11:10:34 -0400 |
---|---|---|
committer | Tom Nichols <tmnichols@gmail.com> | 2010-06-28 11:10:34 -0400 |
commit | 8bdfa770245ec02efbecf81bc598faa2b66a64f4 (patch) | |
tree | 64bf60ccead6ea9cf436f19c9cb4dfd237ba9ec8 /sleekxmpp | |
parent | 15ac3e9fba8fe63b4de64564533d7269def9041e (diff) | |
parent | bf2bf29fc69fa82d8b0a882c99395ae25b11ab69 (diff) | |
download | slixmpp-8bdfa770245ec02efbecf81bc598faa2b66a64f4.tar.gz slixmpp-8bdfa770245ec02efbecf81bc598faa2b66a64f4.tar.bz2 slixmpp-8bdfa770245ec02efbecf81bc598faa2b66a64f4.tar.xz slixmpp-8bdfa770245ec02efbecf81bc598faa2b66a64f4.zip |
Merge branch 'hacks' of git@github.com:tomstrummer/SleekXMPP into hackssleek-0.9-conn-fixes20.9-conn-fixes2
Diffstat (limited to 'sleekxmpp')
-rw-r--r-- | sleekxmpp/xmlstream/statemachine.py | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/sleekxmpp/xmlstream/statemachine.py b/sleekxmpp/xmlstream/statemachine.py index c6e0ea41..67b514a2 100644 --- a/sleekxmpp/xmlstream/statemachine.py +++ b/sleekxmpp/xmlstream/statemachine.py @@ -97,7 +97,7 @@ class StateMachine(object): logging.debug(' ==== TRANSITION %s -> %s', self.__current_state, to_state) self.__current_state = to_state - self.lock.notifyAll() + self.lock.notify_all() return return_val # some 'true' value returned by func or True if func was None else: logging.error( "StateMachine bug!! The lock should ensure this doesn't happen!" ) @@ -126,13 +126,13 @@ class StateMachine(object): The other main difference between this method and `transition()` is that the - state machine is locked for the duration of the `with` statement (normally, - after a `transition() occurs, the state machine is immediately unlocked and + state machine is locked for the duration of the `with` statement. Normally, + after a `transition()` occurs, the state machine is immediately unlocked and available to another thread to call `transition()` again. ''' if not from_state in self.__states: - raise ValueError( "StateMachine does not contain from_state %s." % state ) + raise ValueError( "StateMachine does not contain from_state %s." % from_state ) if not to_state in self.__states: raise ValueError( "StateMachine does not contain to_state %s." % to_state ) @@ -228,7 +228,7 @@ class _StateCtx: self.state_machine.current_state(), self.to_state) self.state_machine._set_state( self.to_state ) - self.state_machine.lock.notifyAll() + self.state_machine.lock.notify_all() self.state_machine.lock.release() return False # re-raise any exception |