| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
| |
* glib/dbus-gobject.c:
Free a leaking GArray (surely not!) in dbus_g_method_return.
|
|
|
|
|
| |
* glib/dbus-gproxy.c:
Don't leak a GArray when firing signals (thank Rob Taylor for review).
|
|
|
|
|
| |
* glib/dbus-gtype-specialized.c: Fix obvious leak of GArray in every
call to dbus_g_type_get_struct.
|
|
|
|
|
|
|
|
|
|
|
| |
* glib/dbus-gvalue-utils.c: Fix the failing test where static string
pointers were put into a GPtrArray-based specialised collection, and
then freed along with the array. GValues which you add into
collections or maps which have the NOCOPY flag set are assumed to not
belong to the caller, so rather than the existing pointer-stealing
semantics, they are copied instead. Given that the main consumers of
this abstraction are the bindings themselves, I don't think this is
too bad, but others should watch their choice of take vs set_static.
|
|
|
|
|
|
|
|
| |
* glib/dbus-gvalue-utils.c: Spotted a warning about the return value
of g_slist_prepend not being used. Fixed copying of slist-based
specialised collections, then wrote a test case and found that it was
all broken. Went on to fix iterating and appending too. Good thing
nobody uses this code yet.
|
|
|
|
|
|
|
|
|
|
| |
* glib/dbus-gvalue-utils.c: Remove duplicated code by having all of
the iterators use gvalue_take_ptrarray_value (the GValues themselves
are discarded without unsetting, so it makes no difference whether
we take or set_static). Remove cases for G_TYPE_POINTER because
there really is nothing useful we can do with them in our
specialised types - we *need* boxed copy/free functions at the very
least.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* glib/dbus-gproxy.c: Put in a pile of assertions that the proxy name
is not NULL when it shouldn't be. Also a couple of possible fixes
for #4637 though I don't understand why the bug happens, to be
honest... also the object constructor has an assert name != NULL
and the name is only currently NULL for peer-to-peer proxies that
I don't think anyone uses? So it should be asserting.
Anyway, for now at least see if we get an earlier assertion failure.
* glib/dbus-gvalue-utils.c: Put in a couple of assertions for
apparently broken code to be sure the tests fail and someone
will fix them...
|
|
|
|
|
|
| |
* glib/dbus-gproxy.c: Fix properties so that they can be given in
any order, making it easier for people who inherit from this
object.
|
|
|
|
|
| |
* glib/dbus-gvalue-utils.c: Patch from Jakub Stachowski to fix leaking
of memory from within pointer arrays and lists. Fixes bug #6300.
|
|
|
|
|
| |
* glib/dbus-gvalue.c: Patch from Jakub Stachowski to fix a leak in
generating struct signatures. Fixes bug #6083.
|
|
|
|
|
| |
* glib/dbus-glib-tool.c (usage): fix up the usage message, someone
should make this thing use the new glib options parser
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* dbus/dbus-message.c (dbus_message_iter_get_fixed_array):
Patch from Rob Taylor <rob.taylor@collabora.co.uk> to correct a bogus
assertion that the next element to read from the iter is fixed in
size. This is not the case when you are at the end of the iter,
because the next element type is INVALID.
* dbus/dbus-string.c (_dbus_string_init_const_len): Correct a
a bogus assert which means that you may not initialise a 0-length
string unless you provide a non-NULL pointer. This prevented
you from marshalling messages containing zero-length arrays in
some cases.
* glib/dbus-gvalue.c (demarshal_collection_array): Another patch
from Rob to correct bogus asserts when trying to demarshal an
array and get_fixed_array got you 0 elements. Append nothing to
the GArray in this case.
* test/glib/test-dbus-glib.c: Add a test case for round-tripping
an empty array via the glib bindings. Without all of the above
patches, this new test fails.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* glib/dbus-gmain.c: Make the previous commit compile.
* python/_dbus.py, python/matchrules.py: Patch from Ole Andre
Ravnaas <ole.andre.ravnaas@collabora.co.uk> to allow you to
specify sender_keyword="foo", path_keyword="bar" when adding
a signal listener, so that you can bind to signals generically
but still do something useful in your callback.
* python/dbus_bindings.pyx: Demarshal the byte type as unsigned
chars so that they're not cast to chars and made negative. Thanks
to Jakub Stachowski for reporting this and testing the fix.
|
|
|
|
|
|
|
|
|
| |
* dbus/dbus-glib.h:
* glib/dbus-gmain.h:
(dbus_g_connection_open): new method for openning
a connection to an arbitrary address in the glib bindings
* ChangeLog: checkin last entry which doesn't seem to be commited
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* glib/dbus-binding-tool-glib.c, glib/dbus-gmain.c,
glib/dbus-gsignature.c, glib/dbus-gtype-specialized.c,
glib/dbus-gtype-specialized.h, glib/dbus-gvalue-utils.c,
glib/dbus-gvalue-utils.h, glib/dbus-gvalue.c:
Patch from Rob Taylor <rob.taylor@collabora.co.uk> to add a big
missing piece of the glib bindings jigsaw puzzle. This modifies
the existing specialised types to have N type parameters (rather
than the current 1 or 2 for arrays and dictionaries respectively).
You can then use this to get a glib type to represent any arbitrary
D-Bus struct type using dbus_g_type_get_struct. The only
implementation of these types is with GValueArrays as before,
but it's now possible to store these in arrays, emit them in
signals, etc.
|
|
|
|
|
|
|
| |
* glib/dbus-binding-tool-glib.[ch]: Patch based on Ricardo Kekki's
patch to use an annotation org.freedesktop.DBus.GLib.ClientCSymbol
when generating the client-side methods, instead of overloading
CSymbol which broke everything horribly. My apologies.
|
|
|
|
|
|
|
|
|
|
|
|
| |
* glib/dbus-gtype-specialized.[ch], glib/dbus-gvalue-utils.c: Patch
by me and Rob Taylor to add a simple_free function to D-Bus map
and collection types, which allows those types which can be freed
with a GDestroyNotify (such as GHashTables and GArrays, but not
GPtrArrays) to be stored as the values in hashtables.
* test/glib/test-dbus-glib.c, test/glib/test-service-glib.{c,xml}:
Patch by Rob Taylor to add nested dicts to the glib tests to check
the above code works, and appears not to leak when called repeatedly.
|
|
|
|
|
|
| |
* glib/dbus-gvalue.c (demarshal_valuearray): Patch from Rob Taylor
to free a D-Bus allocated string with dbus_free () instead of
g_free ().
|
|
|
|
|
| |
* glib/dbus-gproxy.c (dbus_g_proxy_dispose): Protect the dispose
method from being called multiple times.
|
|
|
|
|
|
|
| |
* glib/dbus-binding-tool-glib.c: Patch from Rob Taylor
<rob.taylor@collabora.co.uk> to add support for generating bindings
to arrays that are represented as GPtrArrays rather than GArrays (ie
size-variable things, such as strings, objects, structs, etc).
|
|
|
|
|
|
|
|
| |
* dbus/dbus-glib.h, glib/dbus-gproxy.c: Patch from Ricardo Kekki
<ricardo.kekki@movial.fi> to make it possible to inherit from
DBusGProxy, by splitting the DBusGProxy struct into a public part and
a private part, and moving the setting of the DBusGProxyManager into a
connection property, allowing proper GObject construction.
|
|
|
|
|
|
| |
* glib/dbus-binding-tool-glib.c: Patch from Ricardo Kekki
<ricardo.kekki@movial.fi> to make dbus-binding-tool heed C symbol name
annotations when generating glib client bindings.
|
|
|
|
|
|
|
|
|
|
| |
dbus/dbus-server-debug-pipe.c, glib/dbus-binding-tool-glib.c
glib/dbus-glib-tool.c, glib/dbus-gparser.c, glib/dbus-gproxy.c
test/test-segfault.c, test/test-utils.c,
test/glib/test-dbus-glib.c, tools/dbus-cleanup-sockets.c
tools/dbus-launch.c, tools/dbus-tree-view.c, tools/dbus-viewer.c:
Various cleanup of dead code and compiler warnings (patch from
Kjartan Maraas <kmaraas at gnome.org>)
|
|
|
|
| |
(patch from Carlos Garnacho Parro <carlosg at gnome.org>
|
|
|
|
|
| |
* glib/dbus-gobject.c: Append a GValue instead of a basic type in
method return message for property getters
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Makefile list
* dbus/dbus-shared.h (#define DBUS_NAME_FLAG_ALLOW_REPLACEMENT):
New flag which replaces DBUS_NAME_FLAG_PROHIBIT_REPLACEMENT
(#define DBUS_NAME_FLAG_DO_NOT_QUEUE): New flag for specifying
not to queue an ower if it can't be the primary owner
* bus/bus.h: Add new internal BusOwner struct
* bus/driver.c (bus_driver_handle_hello): Send flags (0 for default)
to bus_registry_ensure and don't set the prohibit_replacement flag
since they are now set per BusOwner and not per name.
(bus_driver_handle_list_queued_owners): bus method (ListQueuedOwners)
that returns the list of connections in a name's connection queue
* bus/services.c (struct BusService): remove prohibit_replacement field
(struct BusOwner): new struct for keeping track of queued connections
and their associated flags for the queue
(struct BusRegistry): add a BusOwner memory pool
(bus_registry_new): initialize the BusOwner memory pool
(bus_registry_unref): free the BusOwner memory pool
(_bus_service_find_owner_link): new internal method for
searching the queue for a specific connection
(bus_owner_set_flags): new method for adding setting the flags on a
bus owner
(bus_owner_new): new method that creates a BusOwner object from the
pool and sets its flags
(bus_owner_ref, bus_owner_unref): ref counting for BusOwner objects
(bus_registry_ensure): Add the flags parameter
(bus_registry_acquire_service): Switch from using raw connections to
using the BusOwner struct
Add new state machine for dealing with the new set of flags
(bus_registry_set_service_context_table, struct OwnershipCancelData,
cancel_ownership, free_ownership_cancel_data,
add_cancel_ownership_to_transaction, struct OwnershipRestoreData,
restore_ownership, free_ownership_restore_data,
add_restore_ownership_to_transaction): Switch to using BusOwner
instead of raw connections
(bus_service_add_owner): Add flags parameter
Switch to using BusOwner instead of raw connections
Add state machine for dealing with the new set of flags
(bus_service_swap_owner): Swaps the first and second owners in the
queue. Used to make sure proper signals are sent when a service looses
or gains primary ownership. We never insert an owner at the top of the
queue. Instead we insert it in the second position and then swap.
(bus_service_remove_owner): Remove the owner from the queue sending
out the NameLost and NameOwnerChanged signals if the we were the
primary owner
(bus_service_get_primary_owners_connection): New method that extracts
the connection from the primary owner
(bus_service_get_primary_owner): Returns the BusOwner instead of the
connection
(bus_service_get_allow_replacement): Changed from the old
bus_service_get_prohibit_replacement method. Checks the flags of the
primary owner and returns if it can be replaced or not
(bus_service_set_prohibit_replacement): removed
(bus_service_has_owner): returns TRUE if and owner with
the specified connection exists in the queue
* dbus/dbus-bus.c (dbus_bus_connection_get_unique_name): New helper
method that only compiles if tests are enabled. Allows us to get the
unique name of a connection so we can check it against the queue when
doing regression tests
* bus/activation.c (bus_activation_send_pending_auto_activate),
bus/dispatch.c (bus_dispatch),
bus/driver.c (bus_driver_handle_get_service_owner,
bus_driver_handle_get_connection_unix_user,
bus_driver_handle_get_connection_unix_process_id,
bus_driver_handle_get_connection_selinux_security_context),
bus/signals.c (connection_is_primary_owner):
use bus_service_get_primary_owners_connection instead of
bus_service_get_primary_owner
* dbus/dbus-sysdeps.c (_dbus_connect_unix_socket,
_dbus_listen_unix_socket): Calculate the length of the socket
path and use that instead of using a fixed length which was
causing socket names to contain many trailing Nul bytes.
* dbus/dbus-glib-lowlevel.h, glib/dbus-gobject.c
(dbus_g_method_get_sender): New method for extracting the sender
from a DBusGMethodInvocation
(dbus_g_method_return_get_reply): changed name to
dbus_g_method_get_reply
(dbus_g_method_return_send_reply): changed name to
dbus_g_method_send reply
* doc/dbus-specification.xml: New docs that describe how the new
queueing system works and talks about the changes to the how
we specify socket names
* glib/examples/example-service.c,
glib/examples/example-signal-emitter.c,
glib/examples/statemachine/statemachine-server.c:
Changed the RequestName flags to the new system
* test/name-test/ (test-names.c, run-test.sh, Makefile.am): New
regression test suite for testing various states of the new
queueing system
|
|
|
|
|
|
|
|
|
|
|
|
| |
* dbus/dbus-glib-lowlevel.h, glib/dbus-gobject.c: Patch from Rob
Taylor to add two methods, dbus_g_method_return_get_reply and
dbus_g_method_return_send_reply, to allow you to get the reply
message from a DBusGMethodInvocation, append arbitrary stuff to it,
and send it. The GLib bindings can't marshal a return value of
something like a(s) if the array is empty - ultimately they should be
made to heed the signature of the out arguments as the Python bindings
now can, but this is a workable interim solution which might have
other applications.
|
|
|
|
|
|
|
|
|
|
|
|
| |
* glib/Makefile.am, glib/examples/Makefile.am,
glib/examples/statemachine/Makefile.am: Merge patch from Ubuntu by
Daniel Stone to replace explicit calls to libtool with $(LIBTOOL).
* test/python/.cvsignore: Add run-with-tmp-session-bus.conf.
* tools/dbus-monitor.1, tools/dbus-monitor.c: Merge dbus-monitor patch
from Ubuntu by Daniel Silverstone to allow specifying match rules on
the command line.
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
and G_TYPE_VALUE_ARRAY (DBUS_TYPE_STRUCT)
(gvalue_from_hash_value, hash_value_from_gvalue): handle gdouble
* glib/dbus-gvalue.c (dbus_gvalue_to_signature): add missing
DBUS_STRUCT_BEGIN_CHAR and DBUS_STRUCT_END_CHAR charaters
when constructing struct signatures
* python/_dbus.py (Bus): handle private connections using the
private keyword in the constructor. defaults to private=False
(Bus::close): new method to close a connection to the bus
* python/dbus_bindings.pyx (Connection::close): renamed method
was previously called disconnect
(bus_get): now supports getting a private connection
* python/proxies.py (ProxyMethod::__call__): check if ignore_reply
keyword is set to True. if it is, execute the method without waiting
for a reply
(ProxyObject::_introspect_execute_queue): new method for executing
all the pending methods that were waiting for the introspect to
finish. this is called when introspect either succeeds or fails
(ProxyObject::_introspect_error_handler): call queued methods
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
instead of marshal basic so we can handle recursive types in a variant
* test/glib/test-dbus-glib.c: Add test for marshaling recurive types
in variants
* test/glib/test-service-glib.c, test-service-glib.xml
(my_object_echo_variant [EchoVariant],
my_object_process_variant_of_array_of_ints123
[ProcessVariantOfArrayOfInts123]):
Add two test methods
* python/introspect_parser.py: New module for parsing introspect
data.
* python/dbus_bindings.pyx:
(various places): when throwing errors fix to use errormsg instead
of message local variable because Pyrex can get confused with other
message variables (initial patch by Robert McQueen
<robert.mcqueen at collabora.co.uk>)
(MessageIter::parse_signature_block): new method for getting the next
block in a signiture.
(MessageIter::append_strict): new method for appending values strictly
using the passed in signature instead of guessing at the type
(MessageItter:: append_dict, append_struct, append_array): use
signatures to marshal children if the signature is available
* python/exceptions.py (IntrospectionParserException): new exception
* python/proxies.py (ProxyMethod::__call__): Marshal args with
introspected signatures if available, else we fall back to the
old way of doing things.
(ProxyObject::_introspect_reply_handler ): parse introspection data
* python/service.py (ObjectType::_reflect_on_method): Properly
terminate <method> if there are no args in the reflection data
* test/python/test-client.py: add tests for talking with the GLib
test server. This gives us better coverage for introspection since
python to python will always generate arguments as variants. It also
allows us to test the robustness of the GLib bindings and interlanguage
communications.
|
|
|
|
|
| |
DBusBindingOutputMode enum which was causing a warning.
#include <time.h> so using time_t is explicitly defined
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Patch from Steve Grubb:
- bus/activation.c (bus_activation_service_reload_test): clean up
some indentation
- dbus/dbus-keyring.c (_dbus_keyring_reload): fix conditional
- dbus/dbus-message-factory.c (generate_special): fix a couple of
buffer overflows in the test suite. This is non critical because
it can not be exploited and this code is only run when doing a
make check.
* Patch from Yaakov Selkowitz: Build fixes for Cygwin
- configure.in: Don't check and link against kdecore, only qt headers
- dbus/Makefile.am: Add -no-undefined to libdbus_1_la_LDFLAGS
- gcj/org/freedesktop/dbus/Makefile.am:
add libdbus_gcj_1_la_LDFLAGS = -no-undefined
- glib/Makefile.am: Add -no-undefined to libdbus_glib_1_la_LDFLAGS
and $(DBUS_GLIB_LIBS) to dbus_binding_tool_LDADD
- qt/Makefile.am: Add -no-undefined to libdbus_qt_1_la_LDFLAGS
- tools/Makefile.am: Add platform extentions to binaries
(i.e. .exe on windows)
* configure.in:
- Make it so if no suitable version of python is found we only
disable building python instead of exiting the configure script
- Require version 2.4 of glib for glib bindings
- Up version to 0.50
* python/__init__.py: Sync version with libdbus to (0,50,0)
|
|
|
|
|
| |
* glib/dbus-gproxy.c (dbus_g_proxy_call): Doc update, thanks
to Ryan Lortie for the suggestion.
|
| |
|
|
|
|
|
| |
* glib/dbus-gobject.c (dbus_set_g_error): Don't lose if the
DBusError message is NULL.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* glib/dbus-gvalue-utils.h (_dbus_g_type_specialized_builtins_init)
(dbus_g_type_is_fixed, dbus_g_type_fixed_get_size)
(dbus_gvalue_set_from_pointer, dbus_g_hash_table_value_foreach)
(dbus_g_hash_table_insert_values, dbus_g_hash_table_insert_steal_values)
(dbus_gtype_is_valid_hash_key, dbus_gtype_is_valid_hash_value)
(dbus_g_hash_func_from_gtype, dbus_g_hash_free_from_gtype)
(dbus_g_hash_equal_from_gtype, dbus_gvalue_stor, dbus_gvalue_take):
* glib/dbus-gvalue.h (dbus_g_value_types_init)
(dbus_gvalue_demarshal, dbus_gvalue_demarshal_variant)
(dbus_gvalue_demarshal_message, dbus_gvalue_marshal):
Prefix name with _ to ensure they're not exported. All callers
updated.
* glib/dbus-gvalue.c (typecode_to_gtype)
(dbus_typecode_maps_to_basic, basic_typecode_to_gtype)
(signature_iter_to_g_type_dict)
(signature_iter_to_g_type_array)
(dbus_gtype_from_signature_iter, dbus_gtype_from_signature)
(dbus_gtypes_from_arg_signature):
Move to dbus-gsignature.c.
* glib/dbus-binding-tool-glib.c (dbus_binding_tool_output_glib_server): Call
dbus_g_type_specialized_builtins_init instead of dbus_g_value_types_init.
(dbus_binding_tool_output_glib_client): Ditto.
* glib/Makefile.am (DBUS_GLIB_INTERNALS): Add dbus-gsignature.c
and dbus-gsignature.h
* test/glib/test-service-glib.c (my_object_rec_arrays): Delete
unused variable.
|
|
|
|
|
| |
* glib/dbus-gobject.c: Add tests on hardcoded object info; this should
catch any incompatible changes accidentally made.
|
|
|
|
|
|
|
| |
Patch from Joe Markus Clarke:
* glib/dbus-gidl.c (property_info_unref, arg_info_unref): Fix
use-after-free.
|
|
|
|
|
|
|
|
|
|
| |
Patch from Joe Markus Clarke:
* glib/dbus-gvalue.c (dbus_g_value_types_init):
* glib/dbus-gvalue-utils.c (dbus_g_type_specialized_builtins_init)
* glib/dbus-gobject.c (write_interface):
Don't use C99 style initializers (bug #3933).
|
|
|
|
| |
* fix a bunch of Doxygen warnings and mistakes
|
| |
|
|
|
|
|
|
|
|
|
| |
* glib/dbus-gvalue.c (signature_iter_to_g_type_array): Don't require
typedata; recursive arrays won't have it.
* test/glib/test-dbus-glib.c:
* test/glib/test-service-glib.c:
* test/glib/test-service-glib.xml: Add recursive arrays tests.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
so distcheck doesn't fail
* glib/examples/Makefile.am: Add example-service.xml and
example-signal-emitter.xml to EXTRA_DIST so distcheck doesn't fail
* glib/examples/statemachine/Makefile.am: Add statemachine.xml and
statemachine-server.xml to EXTRA_DIST so distcheck doesn't fail
* python/Makefile.am: Preprend $(srcdir)/ to source files so the
compiler looks in the right places during distcheck
|
|
|
|
| |
to fail
|
| |
|
|
|
|
|
|
|
|
|
|
| |
* glib/examples/statemachine/Makefile.am (statemachine-server-glue.h)
(statemachine-glue.h):
* glib/examples/Makefile.am (example-service-glue.h)
(example-signal-emitter-glue.h):
* glib/Makefile.am (dbus-glib-error-switch.h):
Add libtool --mode=execute so we use the built library instead
of any installed one.
|