| Commit message (Collapse) | Author | Age |
|
|
|
|
|
|
| |
Python warns that it is not importing these directories because they
contain no __init__.py.
Signed-off-by: Simon McVittie <smcv@collabora.com>
|
|
|
|
|
|
| |
Detected by gcc 7.
Signed-off-by: Simon McVittie <smcv@collabora.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
This file includes <Python.h>, with some #defines that affect the
interpretation of the Python headers (PY_SSIZE_T_CLEAN, PY_SIZE_T_CLEAN).
In particular, <Python.h> transitively includes pyconfig.h, which
defines _GNU_SOURCE, altering the version of struct stat used;
this is potentially a problem if a struct stat is shared between
files, although in practice we don't do that.
Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=749133
|
|
|
|
|
|
|
| |
This is Autoconf best-practice: on some platforms it might contain
things like "#define inline __inline" which should affect all C code.
Signed-off-by: Simon McVittie <smcv@debian.org>
|
|
|
|
|
|
|
| |
This means we can consistently #include <dbus/dbus-python.h>,
either in-tree or out-of-tree.
Signed-off-by: Simon McVittie <smcv@debian.org>
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
| |
Every use here turns out to be unnecessary, some compilers *still*
don't have it after more than a decade in ISO C, and if we need
fixed-length integer types we can use the ones from D-Bus.
|
| |
|
|
|
|
|
|
| |
Based on patches from Christoph Höger.
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=51725
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
Under Python 2, ObjectPath and Signature are subtypes of str (= bytes),
and the existing type-guessing worked.
The type-guessing code assumed that all unicode objects were just
strings, but that assumption became false in the Python 3 port:
ObjectPath and Signature are still subtypes of str, but str now means
unicode, not bytes.
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=50740
|
|
|
|
|
| |
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=47108
Signed-off-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
|
|
|
|
|
| |
If we don't find it, continue to reinvent it, but move the reinvention
to an internal header so it's at least the same in both files that want it.
|
| |
|
|
|
|
|
| |
This reverts the Python 2 API to be in terms of PyInt, leaving the
Python 3 API in terms of PyLong (which is called 'int' in Python code).
|
|
|
|
|
| |
Unicode strings aren't bytestrings, so there's no obvious meaning for
the byte value of a Unicode string of length 1.
|
|
|
|
|
|
|
|
| |
Strictly speaking, DBUS_FOO is libdbus' namespace, not ours. Use
DBUS_PY_FOO.
DBUS_BYTES_BASE was misleading: it's the base class for a single byte,
so call it DBUS_PY_BYTE_BASE.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Porting to Python 3 left these methods returning unicode, which is
arguably an API break in Python 2:
* Message.get_member
* Message.get_path_decomposed (array of unicode)
* Message.get_sender
* Message.get_destination
* Message.get_interface
* Message.get_error_name
* Server.get_address
* Server.get_id
Instead, make them return whatever the natural str type is (bytes in
Python 2, unicode in Python 3).
|
|
|
|
| |
reinventing it
|
|
|
|
|
|
| |
more conventionally
Yes, signals can have a destination. The default is to broadcast.
|
| |
|
|
|
|
|
|
|
| |
- Disallow appending unicode objects with 'y' (bytes) signatures. This now
requires either a bytes object or an integer. Update the tests to reflect
- this change.
- Fix broken __all__ in Python 3.
|
| |
|
|
|
|
|
|
|
| |
2, since there are still some unconditional PyInt calls, which are not valid
in Python 3. However, it lays the framework for conditionalizing on Python 3
and using only PyLong in that case. Where it doesn't matter, PyLong is used
unconditionally.
|
| |
|
|
|
|
|
| |
PyString API. This makes the code compilable in Python 2.x (x >= 6) and
Python 3.
|
|
|
|
|
| |
legal in Python 2 also. Use fancy REPR macro and the %V format code for
cross-Python compatibility.
|
| |
|
|
|
|
| |
initialize the weaklist slots.
|
| |
|
|
|
|
| |
- De-tabbify a few instances that "make check" complains about.
|
|
|
|
| |
for Python 3 support.
|
|
|
|
|
|
| |
Part of a patch for Python 3 compatibility.
Signed-off-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
|
|
|
|
|
|
| |
Part of a patch for Python 3 compatibility.
Signed-off-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
|
|
|
|
|
|
| |
Based on part of a patch from Barry Warsaw.
Signed-off-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
|
|
|
|
|
|
| |
Based on part of a patch from Barry Warsaw.
Signed-off-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
|
|
|
|
| |
Signed-off-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
|
|
|
|
|
|
| |
These turn out not to be used for anything. Spotted by Barry Warsaw.
Signed-off-by: Simon McVittie <simon.mcvittie@collabora.co.uk>
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
Elvis agreed that this shouldn't differ from our handling of objects with
a fileno().
This means that _message_iter_get_pyobject does need to close the fd
itself, so do that.
|