mirror of
https://github.com/gryf/wicd.git
synced 2025-12-19 12:28:08 +01:00
Merge fox 2011-08-09 fixing exception for cli/wicd-cli.py --wireless -c
This commit is contained in:
@@ -175,6 +175,7 @@ if options.disconnect:
|
|||||||
op_performed = True
|
op_performed = True
|
||||||
|
|
||||||
if options.connect:
|
if options.connect:
|
||||||
|
check = None
|
||||||
if options.wireless and options.network > -1:
|
if options.wireless and options.network > -1:
|
||||||
is_valid_wireless_network_id(options.network)
|
is_valid_wireless_network_id(options.network)
|
||||||
name = wireless.GetWirelessProperty(options.network, 'essid')
|
name = wireless.GetWirelessProperty(options.network, 'essid')
|
||||||
@@ -194,17 +195,18 @@ if options.connect:
|
|||||||
|
|
||||||
# update user on what the daemon is doing
|
# update user on what the daemon is doing
|
||||||
last = None
|
last = None
|
||||||
while check():
|
if check:
|
||||||
next = message()
|
while check():
|
||||||
if next != last:
|
next = message()
|
||||||
# avoid a race condition where status is updated to "done" after the
|
if next != last:
|
||||||
# loop check
|
# avoid a race condition where status is updated to "done" after the
|
||||||
if next == "done":
|
# loop check
|
||||||
break
|
if next == "done":
|
||||||
print "%s..." % next.replace("_", " ")
|
break
|
||||||
last = next
|
print "%s..." % next.replace("_", " ")
|
||||||
print "done!"
|
last = next
|
||||||
op_performed = True
|
print "done!"
|
||||||
|
op_performed = True
|
||||||
|
|
||||||
# pretty print optional and required properties
|
# pretty print optional and required properties
|
||||||
def str_properties(prop):
|
def str_properties(prop):
|
||||||
|
|||||||
Reference in New Issue
Block a user