summaryrefslogtreecommitdiff
path: root/dbus_bindings/exceptions.c
diff options
context:
space:
mode:
authorSimon McVittie <smcv@collabora.com>2021-09-15 18:36:44 +0000
committerSimon McVittie <smcv@collabora.com>2021-09-15 18:36:44 +0000
commit828355321633cd91976542cb1f3f24cf64b5b077 (patch)
tree0f66949bf4abb38c350a78dab8f7d966f5f41a73 /dbus_bindings/exceptions.c
parent7bf42eed2d241a0cf3879f6080e31a2e2867a2f5 (diff)
parent57da65589f97da6974f212d4ba5169537a41ac1e (diff)
downloaddbus-python-828355321633cd91976542cb1f3f24cf64b5b077.tar.gz
Merge branch '310-ci' into 'master'
Drop Python 2 support, fix forward-compatibility See merge request dbus/dbus-python!15
Diffstat (limited to 'dbus_bindings/exceptions.c')
-rw-r--r--dbus_bindings/exceptions.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/dbus_bindings/exceptions.c b/dbus_bindings/exceptions.c
index 508537a..2940c2b 100644
--- a/dbus_bindings/exceptions.c
+++ b/dbus_bindings/exceptions.c
@@ -39,7 +39,7 @@ import_exception(void)
return TRUE;
}
- name = NATIVESTR_FROMSTR("dbus.exceptions");
+ name = PyUnicode_FromString("dbus.exceptions");
if (name == NULL) {
return FALSE;
}
@@ -83,7 +83,7 @@ DBusPyException_ConsumeError(DBusError *error)
}
if (error->name) {
- PyObject *name = NATIVESTR_FROMSTR(error->name);
+ PyObject *name = PyUnicode_FromString(error->name);
int ret;
if (!name)