systemd / pystemd

A thin Cython-based wrapper on top of libsystemd, focused on exposing the dbus API via sd-bus in an automated and easy to consume way.
GNU Lesser General Public License v2.1
414 stars 36 forks source link

fix DBusRemote using the wrong attribute #88

Open lilydjwg opened 11 months ago

lilydjwg commented 11 months ago

fixes this:

>>> bus = pystemd.dbuslib.DBusRemote(b'myhost')
>>> bus.open()
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "pystemd/dbuslib.pyx", line 303, in pystemd.dbuslib.DBus.open
    rets = self.open_dbus_bus()
  File "pystemd/dbuslib.pyx", line 577, in pystemd.dbuslib.DBusRemote.open_dbus_bus
    return dbusc.sd_bus_open_system_remote(&(self.bus), self.remote)
AttributeError: 'pystemd.dbuslib.DBusRemote' object has no attribute 'remote'
lilydjwg commented 11 months ago

Also fix use-after-free which shows up at the python interactive shell.

The CI failures are some fedora distributions failing to find and install cython.