diff options
author | Andrew Jeffery <andrew@aj.id.au> | 2017-10-11 18:02:51 +1030 |
---|---|---|
committer | Brad Bishop <bradleyb@fuzziesquirrel.com> | 2017-10-16 16:00:26 +0000 |
commit | 554a0e5c82e94dc7fbbe40791872fa89399a171a (patch) | |
tree | 33c7d2eaa0ae1a83c363f498ceae4da996902975 /pytools | |
parent | 849ebeb7a0067341d5eb8073a8ee6493ae1ca614 (diff) | |
download | blackbird-skeleton-554a0e5c82e94dc7fbbe40791872fa89399a171a.tar.gz blackbird-skeleton-554a0e5c82e94dc7fbbe40791872fa89399a171a.zip |
pytools: obmcutil: Drop redundant prop assignment and test
Change-Id: I0b1b023aeac7103f0be92201c2475193b0f69e5c
Signed-off-by: Andrew Jeffery <andrew@aj.id.au>
Diffstat (limited to 'pytools')
-rw-r--r-- | pytools/obmcutil | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/pytools/obmcutil b/pytools/obmcutil index 3cdfed9..ab5e884 100644 --- a/pytools/obmcutil +++ b/pytools/obmcutil @@ -88,8 +88,6 @@ def main(): print "\t" + name + " -> " + ",".join(multicmd_objects[name]) exit(0) - prop = None - sys.argv.pop(0) cmd = [sys.argv.pop(0)] @@ -99,15 +97,14 @@ def main(): for c in cmd: objinfo = dbus_objects[c] - if (objinfo.has_key('property')): - prop = objinfo['property'] bus = objinfo['bus_name'] obj = objinfo['object_name'] iface = objinfo['interface_name'] dbus_obj = dbus_bus.get_object(bus, obj) - if prop: + if (objinfo.has_key('property')): + prop = objinfo['property'] dbus_iface = dbus.Interface(dbus_obj, "org.freedesktop.DBus.Properties") if objinfo.has_key('value'): dbus_iface.Set(iface, prop, objinfo['value']) |