mirror of
https://github.com/gryf/wicd.git
synced 2026-01-07 06:14:16 +01:00
Fixed wicd-client to actually show the error dialog, by checking e.get_dbus_name() instead of just e.
This commit is contained in:
@@ -86,9 +86,10 @@ def catchdbus(func):
|
||||
def wrapper(*args, **kwargs):
|
||||
try:
|
||||
return func(*args, **kwargs)
|
||||
except DBusException, e:
|
||||
if "DBus.Error.AccessDenied" in e:
|
||||
except DBusException as e:
|
||||
if e.get_dbus_name() != None and "DBus.Error.AccessDenied" in e.get_dbus_name():
|
||||
error(None, language['access_denied'])
|
||||
#raise
|
||||
raise DBusException(e)
|
||||
else:
|
||||
print "warning: ignoring exception %s" % e
|
||||
|
||||
Reference in New Issue
Block a user