send-blocking: don't create Transit unless we need it
This commit is contained in:
parent
dba42aff01
commit
142f3fc154
|
@ -17,12 +17,13 @@ def send_blocking(args):
|
||||||
print(u"On the other computer, please run: %s" % other_cmd,
|
print(u"On the other computer, please run: %s" % other_cmd,
|
||||||
file=args.stdout)
|
file=args.stdout)
|
||||||
|
|
||||||
transit_sender = TransitSender(args.transit_helper)
|
if fd_to_send is not None:
|
||||||
transit_data = {
|
transit_sender = TransitSender(args.transit_helper)
|
||||||
"direct_connection_hints": transit_sender.get_direct_hints(),
|
transit_data = {
|
||||||
"relay_connection_hints": transit_sender.get_relay_hints(),
|
"direct_connection_hints": transit_sender.get_direct_hints(),
|
||||||
}
|
"relay_connection_hints": transit_sender.get_relay_hints(),
|
||||||
phase1["transit"] = transit_data
|
}
|
||||||
|
phase1["transit"] = transit_data
|
||||||
|
|
||||||
with Wormhole(APPID, args.relay_url) as w:
|
with Wormhole(APPID, args.relay_url) as w:
|
||||||
if args.code:
|
if args.code:
|
||||||
|
|
Loading…
Reference in New Issue
Block a user