mirror of
https://github.com/topjohnwu/selinux.git
synced 2025-02-25 22:15:49 +00:00

subprocess.Popen called without universal_newlines=True opens stdin, stout and stderr as binary stream which cause problems with Python 3. Fixes: Traceback (most recent call last): File "/usr/lib64/python3.4/site-packages/sepolicy/gui.py", line 2773, in unconfined_toggle self.dbus.semanage("module -e unconfined") File "<string>", line 2, in semanage File "/usr/lib/python3.4/site-packages/slip/dbus/polkit.py", line 121, in _enable_proxy return func(*p, **k) File "/usr/lib64/python3.4/site-packages/sepolicy/sedbus.py", line 14, in semanage ret = self.dbus_object.semanage(buf, dbus_interface = "org.selinux") File "/usr/lib64/python3.4/site-packages/dbus/proxies.py", line 145, in __call__ **keywords) File "/usr/lib64/python3.4/site-packages/dbus/connection.py", line 651, in call_blocking message, timeout) dbus.exceptions.DBusException: org.freedesktop.DBus.Python.TypeError: TypeError: 'dbus.String' does not support the buffer interface Signed-off-by: Petr Lautrbach <plautrba@redhat.com>