diff options
-rw-r--r-- | python/examples/iface.py | 4 | ||||
-rw-r--r-- | python/examples/wiphy.py | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/python/examples/iface.py b/python/examples/iface.py index 8cc8df5..afeafff 100644 --- a/python/examples/iface.py +++ b/python/examples/iface.py @@ -63,7 +63,7 @@ def msg_handler(m, a): sys.stdout.write("\n") return nl.NL_SKIP - except Exception as e: + except Exception: (t, v, tb) = sys.exc_info() print(v.message) traceback.print_tb(tb) @@ -106,7 +106,7 @@ try: while cbd.done > 0 and not err < 0: err = nl.nl_recvmsgs(s, rx_cb) -except Exception as e: +except Exception: (t, v, tb) = sys.exc_info() print(v.message) traceback.print_tb(tb) diff --git a/python/examples/wiphy.py b/python/examples/wiphy.py index 777ac69..572e95a 100644 --- a/python/examples/wiphy.py +++ b/python/examples/wiphy.py @@ -113,7 +113,7 @@ def msg_handler(m, a): for nl_mode in ifattr: print("\t\t* %s" % nl80211.nl80211_iftype2str[nl.nla_type(nl_mode)]) return nl.NL_SKIP - except Exception as e: + except Exception: (t, v, tb) = sys.exc_info() print(v.message) traceback.print_tb(tb) @@ -155,7 +155,7 @@ try: while cbd.done > 0 and not err < 0: err = nl.nl_recvmsgs(s, rx_cb) -except Exception as e: +except Exception: (t, v, tb) = sys.exc_info() print(v.message) traceback.print_tb(tb) |