chiark / gitweb /
systemctl: drop useless DBus calls from 'systemctl show foo.service'
authorMichal Schmidt <mschmidt@redhat.com>
Mon, 21 May 2012 10:54:43 +0000 (12:54 +0200)
committerMichal Schmidt <mschmidt@redhat.com>
Mon, 21 May 2012 10:59:00 +0000 (12:59 +0200)
commita223b325b409b325f4c2c2e11268596edd842631
treeb51ade58917cc06ed2c310de629372b875ab4ce9
parent80fbf05e75b75b7dd342ec844275efae90c479ec
systemctl: drop useless DBus calls from 'systemctl show foo.service'

systemctl called LoadUnit, GetUnit, GetAll in this order to get the properties.

It is useless to load units explicitly, because it won't ensure anything. The
unit may be freed immediately by the garbage collector.

It is unnecessary to call GetUnit, because systemctl can easily translate the
unit name to DBus path by itself.

GetAll will load the unit if necessary.
src/systemctl/systemctl.c