common: also accept single digit values for mnclen

when using the --mnclen option it is easy to get confused with the
parameter. The parameter has to be a two digit hex value. To make things
easier lets convert a single digit hex value to two digit one
automatically.
master
Philipp Maier 5 months ago
parent 1b44d0e651
commit 7c6777d127

@ -84,6 +84,8 @@ class Common():
elif opt in ("-n", "--mnclen"):
self.show_mnclen = True
elif opt in ("-N", "--set-mnclen"):
if len(arg) == 1:
arg = "0" + arg
self.write_mnclen = asciihex_to_list(arg)
elif opt in ("-l", "--milenage"):
self.show_milenage = True

Loading…
Cancel
Save