Changeset 9c51166


Ignore:
Timestamp:
2010-12-22T19:08:41Z (13 years ago)
Author:
Philippe Crama <pcfeb0009@…>
Branches:
master
Children:
d45adcf
Parents:
e530abd
Message:

Bugfixes: when skipping PINGing bitlbee, update PONG timestamp, watch input socket for exceptional situations

File:
1 edited

Legend:

Unmodified
Added
Removed
  • skype/skyped.py

    re530abd r9c51166  
    284284        while (len(in_error) == 0) and handler_ok and options.conn:
    285285                ready_to_read, ready_to_write, in_error = \
    286                         select.select([options.conn], [], [], timeout)
     286                        select.select([options.conn], [], [options.conn], \
     287                                timeout)
    287288                now = time.time()
    288                 handler_ok = True
    289                 if len(ready_to_read) == 1:
     289                handler_ok = len(in_error) == 0
     290                if (len(ready_to_read) == 1) and handler_ok:
    290291                        handler_ok = input_handler(ready_to_read.pop())
    291292                        # don't ping bitlbee/skype if they already received data
     293                        now = time.time() # allow for the input_handler to take some time
    292294                        bitlbee_ping_start_time = now
    293295                        skype_ping_start_time = now
     296                        options.last_bitlbee_pong = now
    294297                if (now - skype_ping_period > skype_ping_start_time) and handler_ok:
    295298                        handler_ok = skype_idle_handler(skype)
Note: See TracChangeset for help on using the changeset viewer.