Updated examples
This commit is contained in:
parent
ad67c553d7
commit
5ccbc825fd
@ -170,7 +170,7 @@ def client(destination_hexhash, configpath, timeout=None):
|
|||||||
# the packet times out.
|
# the packet times out.
|
||||||
if timeout != None:
|
if timeout != None:
|
||||||
packet_receipt.set_timeout(timeout)
|
packet_receipt.set_timeout(timeout)
|
||||||
packet_receipt.timeout_callback(packet_timed_out)
|
packet_receipt.set_timeout_callback(packet_timed_out)
|
||||||
|
|
||||||
# We can then set a delivery callback on the receipt.
|
# We can then set a delivery callback on the receipt.
|
||||||
# This will get automatically called when a proof for
|
# This will get automatically called when a proof for
|
||||||
|
@ -115,7 +115,7 @@ def client_connected(link):
|
|||||||
list_receipt = list_packet.send()
|
list_receipt = list_packet.send()
|
||||||
list_receipt.set_timeout(APP_TIMEOUT)
|
list_receipt.set_timeout(APP_TIMEOUT)
|
||||||
list_receipt.set_delivery_callback(list_delivered)
|
list_receipt.set_delivery_callback(list_delivered)
|
||||||
list_receipt.timeout_callback(list_timeout)
|
list_receipt.set_timeout_callback(list_timeout)
|
||||||
else:
|
else:
|
||||||
RNS.log("Too many files in served directory!", RNS.LOG_ERROR)
|
RNS.log("Too many files in served directory!", RNS.LOG_ERROR)
|
||||||
RNS.log("You should implement a function to split the filelist over multiple packets.", RNS.LOG_ERROR)
|
RNS.log("You should implement a function to split the filelist over multiple packets.", RNS.LOG_ERROR)
|
||||||
|
Loading…
Reference in New Issue
Block a user