]> git.michaelhowe.org Git - packages/p/paho-mqtt.git/commitdiff
Print retain as int not bool.
authorRoger Light <roger@atchoo.org>
Sat, 22 Jun 2013 21:15:17 +0000 (22:15 +0100)
committerRoger Light <roger@atchoo.org>
Mon, 3 Feb 2014 21:16:20 +0000 (21:16 +0000)
src/paho/mqtt/client.py

index fabef9b4540cab2836b11c15831ac2d168d73617..d87e2820ca0bdd2f6059f13ac901cc2336951abe 100755 (executable)
@@ -1323,10 +1323,10 @@ class Client:
         packet.extend(struct.pack("!B", command))
         if payload == None:
             remaining_length = 2+len(topic)
-            self._easy_log(MQTT_LOG_DEBUG, "Sending PUBLISH (d"+str(dup)+", q"+str(qos)+", r"+str(retain)+", m"+str(mid)+", '"+topic+"' (NULL payload)")
+            self._easy_log(MQTT_LOG_DEBUG, "Sending PUBLISH (d"+str(dup)+", q"+str(qos)+", r"+str(int(retain))+", m"+str(mid)+", '"+topic+"' (NULL payload)")
         else:
             remaining_length = 2+len(topic) + len(payload)
-            self._easy_log(MQTT_LOG_DEBUG, "Sending PUBLISH (d"+str(dup)+", q"+str(qos)+", r"+str(retain)+", m"+str(mid)+", '"+topic+"', ... ("+str(len(payload))+" bytes)")
+            self._easy_log(MQTT_LOG_DEBUG, "Sending PUBLISH (d"+str(dup)+", q"+str(qos)+", r"+str(int(retain))+", m"+str(mid)+", '"+topic+"', ... ("+str(len(payload))+" bytes)")
 
         if qos > 0:
             # For message id