Commits

Anonymous committed 9a6c4cb

FIX: Pings were sent only when the next ping had already been received

  • Participants
  • Parent commits fbd4347

Comments (0)

Files changed (1)

             new_style_msgid = data["msgid"][8] == 255 and data["msgid"][15] == 0
 
             # Pings are uninteresting to anyone but this single connection, so we process them directly. 
-            if data["payload_type"] == "ping" and self.unprocessed_data[23+data["payload_length"]:]:
+            if data["payload_type"] == "ping" and self.unprocessed_data[22+data["payload_length"]:]:
                 self.send_pong(data["msgid"], 7, 0, # msgid, ttl, hops
                                shared_data["my_address"], # IP, Port
                                shared_data["shared_files"], # number of shared files