platform/upstream/dbus.git
18 years ago2005-08-01 Colin Walters <walters@verbum.org>
Colin Walters [Mon, 1 Aug 2005 16:12:53 +0000 (16:12 +0000)]
2005-08-01  Colin Walters  <walters@verbum.org>

Patch from Joe Markus Clarke:

* glib/dbus-gidl.c (property_info_unref, arg_info_unref): Fix
use-after-free.

18 years ago2005-08-01 Colin Walters <walters@verbum.org>
Colin Walters [Mon, 1 Aug 2005 16:10:34 +0000 (16:10 +0000)]
2005-08-01  Colin Walters  <walters@verbum.org>

Patch from Joe Markus Clarke:

* tools/dbus-send.c (main):

Don't use C99 style initializers (bug #3933).

18 years ago2005-08-01 Colin Walters <walters@verbum.org>
Colin Walters [Mon, 1 Aug 2005 16:07:19 +0000 (16:07 +0000)]
2005-08-01  Colin Walters  <walters@verbum.org>

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).

18 years ago2005-07-31 Havoc Pennington <hp@redhat.com>
Havoc Pennington [Sun, 31 Jul 2005 14:58:42 +0000 (14:58 +0000)]
2005-07-31  Havoc Pennington  <hp@redhat.com>

* tools/dbus-viewer.c (load_child_nodes): fix invocation of
dbus_g_proxy_call, fix from Piotr Zielinski bug #3920

18 years ago2005-07-30 Havoc Pennington <hp@redhat.com>
Havoc Pennington [Sun, 31 Jul 2005 02:09:15 +0000 (02:09 +0000)]
2005-07-30  Havoc Pennington  <hp@redhat.com>

* fix a bunch of Doxygen warnings and mistakes

18 years agoadd "publish introspect dtd" to TODO for 1.0
Havoc Pennington [Sun, 31 Jul 2005 01:38:55 +0000 (01:38 +0000)]
add "publish introspect dtd" to TODO for 1.0

18 years ago2005-07-30 Havoc Pennington <hp@redhat.com>
Havoc Pennington [Sat, 30 Jul 2005 15:17:29 +0000 (15:17 +0000)]
2005-07-30  Havoc Pennington  <hp@redhat.com>

* dbus/dbus-sysdeps.c (_dbus_string_parse_uint): remove #ifdef
DBUS_BUILD_TESTS since it's now used in production code

18 years ago2005-07-29 Havoc Pennington <hp@redhat.com>
Havoc Pennington [Sat, 30 Jul 2005 01:33:55 +0000 (01:33 +0000)]
2005-07-29  Havoc Pennington  <hp@redhat.com>

* test/glib/test-profile.c (write_junk): initialize the junk
buffer so valgrind doesn't have a breakdown

18 years agoremove that todo item
Havoc Pennington [Fri, 29 Jul 2005 17:46:58 +0000 (17:46 +0000)]
remove that todo item

18 years ago2005-07-29 Havoc Pennington <hp@redhat.com>
Havoc Pennington [Fri, 29 Jul 2005 17:43:30 +0000 (17:43 +0000)]
2005-07-29  Havoc Pennington  <hp@redhat.com>

* bus/signals.c (bus_signals_test): add match_rule_equal() tests
(match_rule_matches): remove unused arg
(test_matching): add tests for match_rule_matches()

* bus/signals.c (bus_match_rule_parse_arg_match): add ability to
do arg0='foo' arg5='bar' in the match rules
(match_rule_matches): don't match if the arg0='foo' doesn't match.

* dbus/dbus-protocol.h (DBUS_MAXIMUM_MATCH_RULE_ARG_NUMBER): add this

18 years agoRemove unused condvar
Ross Burton [Fri, 29 Jul 2005 14:43:59 +0000 (14:43 +0000)]
Remove unused condvar

18 years agoReduce size of message cache
Ross Burton [Wed, 27 Jul 2005 19:38:41 +0000 (19:38 +0000)]
Reduce size of message cache

18 years agoRemove matchers when all proxies are removed
Ross Burton [Mon, 25 Jul 2005 19:16:22 +0000 (19:16 +0000)]
Remove matchers when all proxies are removed

18 years ago2005-07-24 Colin Walters <walters@verbum.org>
Colin Walters [Sun, 24 Jul 2005 18:04:23 +0000 (18:04 +0000)]
2005-07-24  Colin Walters  <walters@verbum.org>

* 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.

18 years ago* python/_dbus.py, _util.py, decorators.py, extract.py, matchrules.py.
John (J5) Palmieri [Wed, 20 Jul 2005 14:15:08 +0000 (14:15 +0000)]
* python/_dbus.py, _util.py, decorators.py, extract.py, matchrules.py.
  proxies.py, service.py: Cleanup of code after running it through the
  pyflakes code checker mostly dealing with undefined names.
  (Bug #3828, Patch from Anthony Baxter <anthony@interlink.com.au>)

18 years agoadd missing entry
Colin Walters [Tue, 19 Jul 2005 22:18:54 +0000 (22:18 +0000)]
add missing entry

18 years ago* Merge DBUS_0_35_2 branch into HEAD
John (J5) Palmieri [Sun, 17 Jul 2005 21:02:56 +0000 (21:02 +0000)]
* Merge DBUS_0_35_2 branch into HEAD

2005-07-17  John (J5) Palmieri  <johnp@redhat.com>

        * NEWS: Update to 0.35.2

2005-07-17  John (J5) Palmieri  <johnp@redhat.com>

        * python/_dbus.py: Remove import of the dbus.services
        module as it no longer exists (patch from Dimitur Kirov)

        * python/service.py (Object::__init__): Fixed typo
        s/name/bus_name (patch from Dimitur Kirov)

        * python/examples/example-signal-emitter.py: import dbus.glib
        to get the main loop and use glib mainloop instead of gtk so
        X doesn't have to be running.

        * python/examples/example-signal-recipient.py: import dbus.glib
        to get the main loop and use glib mainloop instead of gtk so
        X doesn't have to be running. Import the decorators module
        directly.

        * test/glib/Makefile.am:  Added DIST_EXTRA files that distcheck
        didn't pick up on but are needed to build

        * configure.in: upped version to 0.35.2

        * bus/driver.c, bus/selinux.c, bus/selinux.h, dbus/dbus-protocol.h:
        added Colin Walters' SELinux API rename patch from head
        s/unix sercurity context/selinux security context/

2005-07-16  John (J5) Palmieri  <johnp@redhat.com>

        * python/Makefile.am: dbus_binding.pxd.in should be included
        in EXTRA_DIST not dbus_binding.pxd
        fix up $(srcdir) hopefully for the last time

        * NEWS: Update to 0.35.1

18 years ago2005-07-16 Colin Walters <walters@verbum.org>
Colin Walters [Sat, 16 Jul 2005 17:34:08 +0000 (17:34 +0000)]
2005-07-16  Colin Walters  <walters@verbum.org>

* bus/driver.c (bus_driver_handle_get_connection_selinux_security_context): Renamed
from bus_driver_handle_get_connection_unix_security_context.  Update for
error usage.
(message_handlers): Update for renames.

* bus/selinux.c (bus_selinux_allows_send): Handle OOM on
_dbus_string_init failure correctly.
(bus_selinux_append_context): Convert SID to context.  Append it
as a byte array.
(bus_selinux_shutdown): Handle the case where bus_selinux_full_init
hasn't been called.

* bus/selinux.h: Update prototype.

* dbus/dbus-protocol.h (DBUS_ERROR_SELINUX_SECURITY_CONTEXT_UNKNOWN): Renamed
from DBUS_ERROR_UNIX_SECURITY_CONTEXT_UNKNOWN.

18 years ago2005-07-15 Colin Walters <walters@verbum.org>
Colin Walters [Fri, 15 Jul 2005 22:02:25 +0000 (22:02 +0000)]
2005-07-15  Colin Walters  <walters@verbum.org>

* doc/TODO: Add note about convenience wrappers.

18 years ago* configure.in: upped version to 0.36
John (J5) Palmieri [Fri, 15 Jul 2005 20:35:25 +0000 (20:35 +0000)]
* configure.in: upped version to 0.36

18 years ago* Update to 0.35 dbus-0.35
John (J5) Palmieri [Fri, 15 Jul 2005 20:33:35 +0000 (20:33 +0000)]
* Update to 0.35

18 years ago* glib/Makefile.am: Add make-dbus-glib-error-switch.sh to EXTRA_DIST
John (J5) Palmieri [Fri, 15 Jul 2005 20:28:05 +0000 (20:28 +0000)]
* glib/Makefile.am: Add make-dbus-glib-error-switch.sh to EXTRA_DIST
  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

18 years ago* glib/example/Makefile.am: Fix a typo which cause make distcheck
John (J5) Palmieri [Fri, 15 Jul 2005 19:15:05 +0000 (19:15 +0000)]
* glib/example/Makefile.am: Fix a typo which cause make distcheck
  to fail

18 years ago* python/examples/example-service.py,
John (J5) Palmieri [Fri, 15 Jul 2005 18:09:59 +0000 (18:09 +0000)]
* python/examples/example-service.py,
  python/examples/example-signal-emitter.py: Fixed up examples
  for API changes

18 years ago* python/__init__.py: Upped to version (0,42,0) because of
John (J5) Palmieri [Fri, 15 Jul 2005 17:33:17 +0000 (17:33 +0000)]
* python/__init__.py: Upped to version (0,42,0) because of
  the API change

18 years ago* ChangeLog: fix date in last entry
John (J5) Palmieri [Fri, 15 Jul 2005 17:28:35 +0000 (17:28 +0000)]
* ChangeLog: fix date in last entry

* configure.in, bus/system.conf.in: add the ability to configure
  the system bus user at compiletime with the --with-dbus-user flag
  (patch from Kristof Vansant)

18 years ago* bus/dispatch.c, test/test-service.c: Add testcase
John (J5) Palmieri [Fri, 15 Jul 2005 15:21:43 +0000 (15:21 +0000)]
* bus/dispatch.c, test/test-service.c: Add testcase
  for sending messages to oneself (TODO item).

* python/service.py (class Object): Swap ordering of bus_name
  and object_path parameters to better support inheritance.

* doc/dbus-tutorial.xml: change Python docs to reflect change
  in parameter ordering and fix the inheritance section.

* doc/TODO: remove sending message to oneself TODO item

18 years agoDon't leak messages when calling methods
Ross Burton [Fri, 15 Jul 2005 13:25:48 +0000 (13:25 +0000)]
Don't leak messages when calling methods

18 years ago2005-07-15 Colin Walters <walters@verbum.org>
Colin Walters [Fri, 15 Jul 2005 04:04:43 +0000 (04:04 +0000)]
2005-07-15  Colin Walters  <walters@verbum.org>

* bus/selinux.c (bus_selinux_append_context): Wrap in
HAVE_SELINUX.

18 years ago* python/_dbus.py (Bus::remove_signal_receiver):
John (J5) Palmieri [Fri, 15 Jul 2005 02:15:08 +0000 (02:15 +0000)]
* python/_dbus.py (Bus::remove_signal_receiver):
  don't add a callback to the match if none has been passed in

* python/matchrules.py (SignalMatchTree::remove): if the rule
  being matched does not have a callback treat it as a wildcard
  fix matching logic

* doc/dbus-tutorial.xml: Add Python tutorial

18 years ago2005-07-14 Colin Walters <walters@verbum.org>
Colin Walters [Thu, 14 Jul 2005 21:45:42 +0000 (21:45 +0000)]
2005-07-14  Colin Walters  <walters@verbum.org>

* bus/driver.c
(bus_driver_handle_get_connection_unix_security_context): New function.
(message_handlers): Add.

* bus/selinux.c (bus_selinux_append_context): New function; appends
security context to message.

* bus/selinux.h: Prototype.

* dbus/dbus-protocol.h (DBUS_ERROR_UNIX_SECURITY_CONTEXT_UNKNOWN): New.

18 years agoChecking in Rodrigo's patch along with my fixes to the patch
John (J5) Palmieri [Thu, 14 Jul 2005 20:44:15 +0000 (20:44 +0000)]
Checking in Rodrigo's patch along with my fixes to the patch

2005-07-14  John (J5) Palmieri  <johnp@redhat.com>

* bus/activation.c: clean up all tabs to be 8 spaces
(bus_activation_activate_service): make sure we clean up
if activation fails

* bus/dispatch.c: clean up all tabs to be 8 spaces
(check_shell_fail_service_auto_start): New function
tests to make sure we get fail properly when trying to auto start a service
with a faulty command line
(check_shell_service_success_auto_start): New function tests to make sure
auto started services get the arguments on the command line

* test/test-shell-service.c: Added service for testing auto-starting with
command line arguments

* test/data/valid-service-files/debug-shell-echo-fail.service.in,
test/data/valid-service-files/debug-shell-echo-success.service.in:
Added service files for testing auto-starting with command line arguments

* */.cvsignore: added a bunch of generated files to various .cvsignore files

2005-07-14  Rodrigo Moya  <rodrigo@novell.com>

* dbus/dbus-shell.[ch]: copy/pasted code from GLib.

* dbus/Makefile.am: added new files to build.

* bus/activation.c (bus_activation_activate_service): support
activation commands with parameters.

* test/shell-test.c: added test program for the shell parsing
code.

18 years ago2005-07-13 David Zeuthen <davidz@redhat.com>
David Zeuthen [Wed, 13 Jul 2005 21:13:16 +0000 (21:13 +0000)]
2005-07-13  David Zeuthen  <davidz@redhat.com>

        * tools/dbus-send.c (append_arg, type_from_name): Also support 16 and
        64 bit signed and unsigned parameters

18 years ago* python/.cvsignore: remove dbus_bindings.pyx, add dbus_bindings.pxd
John (J5) Palmieri [Wed, 13 Jul 2005 18:22:35 +0000 (18:22 +0000)]
* python/.cvsignore: remove dbus_bindings.pyx, add dbus_bindings.pxd

* python/service.py (class Name): renamed BusName to make it clearer
  what the object is for (a name on the bus)

* python/examples/example-service.py,
  python/examples/example-signal-emitter.py: change the Name object to
  BusName

18 years ago2005-07-12 Colin Walters <walters@verbum.org>
Colin Walters [Tue, 12 Jul 2005 21:09:54 +0000 (21:09 +0000)]
2005-07-12  Colin Walters  <walters@verbum.org>

Patch from Jim Gettys <Jim.Gettys@hp.com>.

* tools/dbus-launch.c: Include sys/select.h.

18 years ago* python/dbus_bindings.pyx.in: removed
John (J5) Palmieri [Tue, 12 Jul 2005 18:16:07 +0000 (18:16 +0000)]
* python/dbus_bindings.pyx.in: removed

* python/dbus_bindings.pyx: Added.
- Fixed some memleaks (patch from
  Sean Meiners <sean.meiners@linspireinc.com>)
- Broke out the #include "dbus_h_wrapper.h" and put it in its
  own pxd file (Pyrex definition)
- Broke out glib dependancies into its own pyx module

* python/dbus_bindings.pdx: Added.
- Defines C class Connection for exporting to other modules

* python/dbus_glib_bindings.pyx: Added.
- New module to handle lowlevel dbus-glib mainloop integration

* python/glib.py: Added.
- Registers the glib mainloop when you import this module

* python/services.py: Removed (renamed to service.py)

* python/service.py: Added.
- (class Server): renamed Name

* python/__init__.py: Bump ro version (0,41,0)
- don't import the decorators or service module
      by default.  These now reside in the dbus.service namespace

* python/_dbus.py (Bus::__init__): Add code run the main loop
  setup function on creation

* python/examples/example-service.py,
  python/examples/example-signal-emitter.py: update examples

* python/examples/gconf-proxy-service.py,
  python/examples/gconf-proxy-service2.py: TODO fix these up

* doc/TODO: Addition
- Added a Python Bindings 1.0 section
- added "Add match on args or match on details to match rules"

18 years ago2005-07-12 Colin Walters <walters@verbum.org>
Colin Walters [Tue, 12 Jul 2005 17:57:04 +0000 (17:57 +0000)]
2005-07-12  Colin Walters  <walters@verbum.org>

* 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.

18 years ago2005-07-11 Colin Walters <walters@verbum.org>
Colin Walters [Mon, 11 Jul 2005 16:12:50 +0000 (16:12 +0000)]
2005-07-11  Colin Walters  <walters@verbum.org>

* glib/dbus-gvalue.c (struct _DBusGValue): Delete.
(dbus_g_value_types_init): Remove assertion.
(dbus_g_value_get_g_type, dbus_g_value_open)
(dbus_g_value_iterator_get_values, dbus_g_value_get_signature)
(dbus_g_value_copy, dbus_g_value_free): Delete unimplemented
functions related to DBusGValue.  Now we marshal/demarshal
structures as GValueArray.
(dbus_gtype_from_signature_iter): Return G_TYPE_VALUE_ARRAY for
structures.
(signature_iter_to_g_type_array): Don't call
signature_iter_to_g_type_struct.
(signature_iter_to_g_type_struct): Delete.
(dbus_gvalue_to_signature): Delete.
(dbus_gvalue_to_signature): New function with same name as other
one; we can convert structures to signatures.
(demarshal_valuearray): New function.
(get_type_demarshaller): Use it.
(demarshal_recurse): Delete.
(marshal_proxy): New function.
(marshal_map): Warn if we can't determine signature from type.
(marshal_collection_ptrarray): Ditto.
(marshal_collection_array): Ditto.
(get_type_marshaller): Use marshal_valuearray.
(marshal_recurse): Delete.
(_dbus_gvalue_test): Add some tests.

* dbus/dbus-glib.h (struct _DBusGValueIterator):
(dbus_g_value_get_g_type, DBUS_TYPE_G_VALUE)
(dbus_g_value_open, dbus_g_value_iterator_get_value)
(dbus_g_value_iterator_get_values, dbus_g_value_iterator_recurse)
(dbus_g_value_free): Remove prototypes.

* glib/dbus-binding-tool-glib.c (dbus_g_type_get_lookup_function): Handle
G_TYPE_VALUE_ARRAY.

* glib/examples/example-service.c:
* glib/examples/example-client.c: Implement GetTuple.

* test/glib/test-dbus-glib.c:
* test/glib/test-service-glib.c:
* test/glib/test-service-glib.xml: Add structure tests.

18 years ago2005-07-10 Colin Walters <walters@verbum.org>
Colin Walters [Sun, 10 Jul 2005 22:54:19 +0000 (22:54 +0000)]
2005-07-10  Colin Walters  <walters@verbum.org>

* doc/TODO: Knock off some GLib items with this patch.

* glib/dbus-gvalue-utils.c (_dbus_gtype_can_signal_error)
(_dbus_gvalue_signals_error): New functions.

* glib/dbus-gvalue-utils.h: Prototype them.

* glib/dbus-gobject.c (arg_iterate): Update to handle return vals
and change to not output const/retval flags for input args.  All
callers updated.
(invoke_object_method): Refactor to handle return values.  Add
some more comments in various places.  Remove debug g_print.

* glib/dbus-binding-tool-glib.h (DBUS_GLIB_ANNOTATION_RETURNVAL): New.

* glib/dbus-binding-tool-glib.c (dbus_g_type_get_marshal_name):
Handle G_TYPE_NONE.
(compute_gsignature): New function; refactored from code from
compute_marshaller and compute_marshaller_name.  Enhance to
handle return values and async ops more cleanly.  Update for
async ops returning NONE instead of BOOLEAN.
(compute_marshaller, compute_marshaller_name): Call compute_gsignature
and output appropriate string.
(generate_glue): Handle return value annotation.  Also don't dump
constness flag for input arguments.

* glib/Makefile.am (DBUS_GLIB_INTERNALS): New variable; contains
files shared between installed library and utilities.
(libdbus_glib_1_la_SOURCES): Move some stuf into DBUS_GLIB_INTERNALS.
(libdbus_gtool_la_SOURCES): Suck in DBUS_GLIB_INTERNALS so the
binding tool can access gtype utility functions.

* test/glib/test-service-glib.c:
* test/glib/test-service-glib.xml:
* test/glib/test-dbus-glib.c: Add some tests for return values.

18 years ago2005-07-09 Colin Walters <walters@verbum.org>
Colin Walters [Sat, 9 Jul 2005 18:54:45 +0000 (18:54 +0000)]
2005-07-09  Colin Walters  <walters@verbum.org>

* glib/dbus-gparser.c (parse_annotation): Add annotations to
argument if available, not method.

* glib/dbus-gobject.c (arg_iterate): More verbose warnings.
(invoke_object_method): First, remove some redundant
GValues (object_value, error_value) in favor of working on
array directly.  Second, rework constness to be less buggy.
Now we iterate directly over the argument metadata instead
of parallel iterating over output signature and metadata.

* glib/dbus-glib-tool.h: Add INVALID_ANNOTATION error.

* glib/dbus-binding-tool-glib.c (generate_glue): Barf on const
annotation on input args.

18 years ago2005-07-09 Colin Walters <walters@verbum.org>
Colin Walters [Sat, 9 Jul 2005 17:52:52 +0000 (17:52 +0000)]
2005-07-09  Colin Walters  <walters@verbum.org>

* glib/dbus-binding-tool-glib.h (DBUS_GLIB_ANNOTATION_CONST):
Define.

* glib/dbus-binding-tool-glib.c (generate_glue): Handle Const
annotation.

* glib/dbus-gobject.c (arg_iterate): Update to parse constval too.
(method_dir_signature_from_object_info): Handle arg_iterate change.
(write_interface): Ditto.
(lookup_object_info): Don't barf if format_version is > 0.
(invoke_object_method): Handle arg constness.

* glib/dbus-gidl.c (struct ArgInfo): Add annotations.
(arg_info_new): Create.
(arg_info_unref): Destroy.
(arg_info_get_annotations, arg_info_get_annotation)
(arg_info_add_annotation): New functions.

* glib/dbus-gidl.h: Prototype them.

* glib/dbus-gparser.c (parse_annotation): Allow annotations in
args, disallow them in properties.
(parse_annotation): Handle arg annotations.

* test/glib/test-service-glib.xml:
* test/glib/test-service-glib.c: Update to make some methods
const.

18 years ago2005-07-08 Colin Walters <walters@verbum.org>
Colin Walters [Sat, 9 Jul 2005 01:46:51 +0000 (01:46 +0000)]
2005-07-08  Colin Walters  <walters@verbum.org>

* test/glib/test-service-glib.xml:
* test/glib/test-service-glib.c:
* test/glib/test-dbus-glib.c: Test a{sv}.

* glib/examples/statemachine/statemachine.c:
* glib/examples/statemachine/statemachine-server.c:
* glib/examples/statemachine/statemachine-client.c: Fix some bugs,
add progress bar, etc.

* glib/dbus-gvalue.c (register_array, register_dict): Delete; not
needed anymore due to generic array/map marshalling.
(dbus_g_value_types_init): Don't register basic arrays or the
string/string hash.
(dbus_gtype_from_signature_iter): Don't try to recurse into
variants.
(dbus_gtype_to_signature): Check collection/map before type
metadata.
(demarshal_garray_basic): Renamed to demarshal_collection_array.
(demarshal_ghashtable): Renamed to demarshal_map; fix to use new
generic map creation/append functions instead of hash table
specifically.
(get_type_demarshaller): Handle maps.
(demarshal_collection): Dispatch on collection type to either
demarshal_collection_ptrarray or demarshal_collection_array.
(get_type_marshaller): Handle maps.
(marshal_collection): Dispatch collection type to either
marshal_collection_ptrarray or marshal_collection_array.
(_dbus_gvalue_test): New test.

* glib/dbus-gvalue-utils.c (unset_and_free_g_value): New function.
(hash_free_from_gtype): Use it to free GValues.
(hashtable_append): New function.
(ptrarray_append): Fix prototype.
(slist_append): Ditto.
(_dbus_gvalue_utils_test): Extend tests.

* glib/dbus-gtype-specialized.c
(dbus_g_type_specialized_init_append): Renamed from
dbus_g_type_specialized_collection_init_append.  Remove const from
value, since we steal it.
(dbus_g_type_specialized_map_append): New function.

* glib/dbus-gtype-specialized.h: Update prototypes.
Add DBusGTypeSpecializedMapAppendFunc.

* glib/dbus-gtest.c (dbus_glib_internal_do_not_use_run_tests): Run
_dbus_gvalue_test.

* glib/dbus-gtest.h: Prototype it.

18 years agoMake async bindings work again
Ross Burton [Fri, 8 Jul 2005 17:02:42 +0000 (17:02 +0000)]
Make async bindings work again

18 years ago2005-07-08 Colin Walters <walters@verbum.org>
Colin Walters [Fri, 8 Jul 2005 16:41:57 +0000 (16:41 +0000)]
2005-07-08  Colin Walters  <walters@verbum.org>

* doc/TODO: Update GLib todo bits, also add a post-1.0 TODO for a
connection concept.

18 years ago2005-07-08 Colin Walters <walters@verbum.org>
Colin Walters [Fri, 8 Jul 2005 16:25:39 +0000 (16:25 +0000)]
2005-07-08  Colin Walters  <walters@verbum.org>

* tools/Makefile.am: Kill of print-introspect in favor of using
dbus-send --print-reply=literal.
* tools/print-introspect.c: Deleted.

* test/glib/test-service-glib.xml:
* test/glib/test-service-glib.c (my_object_get_objs): New test
for "ao".

* test/glib/test-dbus-glib.c (echo_received_cb): Free echo data.
(main): Test GetObjs.

* glib/examples/statemachine/Makefile.am:
* glib/examples/statemachine/sm-marshal.list:
* glib/examples/statemachine/statemachine-client.c:
* glib/examples/statemachine/statemachine-server.c:
* glib/examples/statemachine/statemachine-server.xml:
* glib/examples/statemachine/statemachine.c:
* glib/examples/statemachine/statemachine.h:
* glib/examples/statemachine/statemachine.xml:

New example.

* glib/examples/example-service.c (main): Move invocation
of dbus_g_object_type_install_info earlier, to emphasize it
should only be done once.

* glib/examples/example-signal-emitter.c (main): Ditto.

* glib/examples/Makefile.am (SUBDIRS): Include statemachine.

* glib/dbus-gvalue.h (dbus_gtype_to_signature)
(dbus_gvalue_marshal): Update prototypes.

* glib/dbus-gvalue.c: Update all marshalling functions to take
const GValue instead of GValue.
(signature_iter_to_g_type_array): Return a GPtrArray for nonfixed
types.
(dbus_gvalue_to_signature): Update for dbus_gtype_to_signature
change.
(dbus_gtype_to_signature): Handle generic collecitons and maps.
Return a newly-allocated string.
(demarshal_proxy, demarshal_object_path, demarshal_object)
(demarshal_strv, demarshal_ghashtable): Set error, don't assert if
we get the wrong types from message.
(get_type_demarshaller): New function, extracted from
dbus_gvalue_demarshal.
(demarshal_collection): New function, demarshals generic
collection.
(dbus_gvalue_demarshal): Just invoke result of
get_type_demarshaller.  Throw error if we don't have one.
(marshal_garray_basic): Abort on OOM.
(get_type_marshaller): New function, extracted from
dbus_gvalue_marshal.
(collection_marshal_iterator, marshal_collection): New functions;
implements generic marshalling for an iteratable specialized
collection.
(dbus_gvalue_marshal): Just invoke result of get_type_marshaller.

* glib/dbus-gvalue-utils.c (gvalue_from_ptrarray_value): Handle
G_TYPE_STRING.
(ptrarray_value_from_gvalue): Ditto.
(ptrarray_append, ptrarray_free): New functions.
(slist_constructor, slist_iterator, slist_copy_elt, slist_copy)
(slist_append, slist_end_append, slist_free): New functions.
(dbus_g_type_specialized_builtins_init): Add append fuctions
for GPtrArray and GSList.  Register GSList.
(test_specialized_hash, _dbus_gvalue_utils_test): New functions.

* glib/dbus-gtype-specialized.h (DBusGTypeSpecializedAppendContext):
New.
(dbus_g_type_specialized_collection_init_append)
(dbus_g_type_specialized_collection_append)
(dbus_g_type_specialized_collection_end_append): Prototype.
(DBusGTypeSpecializedCollectionVtable): Add append_func and
end_append_func.

* glib/dbus-gtype-specialized.c (dbus_g_type_specialized_collection_init_append)
(dbus_g_type_specialized_collection_append)
(dbus_g_type_specialized_collection_end_append): New functions.
(dbus_g_type_map_value_iterate): Take const GValue.
(dbus_g_type_collection_value_iterate): Ditto.

* glib/dbus-gtest.c (dbus_glib_internal_do_not_use_run_tests): Run
_dbus_gvalue_utils_test.

* glib/dbus-gtest.h: Prototype it.

* glib/dbus-gproxy.c (dbus_g_proxy_manager_filter): Avoid
using uninitialized owner_list.
(dbus_g_proxy_begin_call_internal): Move return_if_fail to
public API.
(dbus_g_proxy_end_call_internal): Update to use error set
from dbus_gvalue_demarshal instead of setting it here.
(dbus_g_proxy_begin_call): Move return_if_fail here.

* glib/dbus-gobject.c (write_interface): Update for
dbus_gtype_to_signature returning new string.

* configure.in: Add glib/examples/statemachine.

18 years ago2005-07-08 Joe Shaw <joeshaw@novell.com>
Joe Shaw [Fri, 8 Jul 2005 14:36:22 +0000 (14:36 +0000)]
2005-07-08  Joe Shaw  <joeshaw@novell.com>

* configure.in: Add a configure option, --with-console-auth-dir

* dbus/dbus-sysdeps-util.c (_dbus_user_at_console): Use the
new setting.  Patch from Kay Sievers.

18 years ago2005-07-06 Colin Walters <walters@verbum.org>
Colin Walters [Wed, 6 Jul 2005 21:27:53 +0000 (21:27 +0000)]
2005-07-06  Colin Walters  <walters@verbum.org>

* dbus/dbus-glib.h (DBusGPendingCall, DBusGPendingCallNotify)
(DBUS_TYPE_G_PENDING_CALL, dbus_g_pending_call_get_g_type)
(dbus_g_pending_call_ref, dbus_g_pending_call_unref): Delete.
(dbus_g_pending_call_set_notify, dbus_g_pending_call_cancel):
Delete in favor of dbus_g_proxy_begin_call and
dbus_g_proxy_cancel_call.
(DBusGProxyCall, DBusGProxyCallNotify): New.
(dbus_g_proxy_begin_call): Change prototype to take callback, user
data, and destroy function.  This replaces
dbus_g_pending_call_set_notify.
(dbus_g_proxy_cancel_call): Prototype.
(DBusGAsyncData): Delete, shouldn't be needed anymore.

* glib/dbus-gproxy.c (struct _DBusGProxy): Add call_id_counter and
pending_calls map.
(struct _DBusGProxyManager): Add bus_proxy member, which is an
internal proxy for calls to the bus. Remove
pending_nameowner_calls, now the internal proxy keeps track.
(dbus_g_proxy_manager_unref): Unref bus proxy, remove reference to
pending_nameowner_calls.
(got_name_owner_cb): Update prototype, and use
dbus_g_proxy_end_call.
(got_name_owner_cb): Remove reference to pending_nameowner_calls.
(dbus_g_proxy_manager_register): Delete directly libdbus code in
favor of using internal proxy.
(dbus_g_proxy_manager_unregister): Update to use
dbus_g_proxy_cancel_call for any pending GetNameOwner call.
(dbus_g_proxy_init): Initialize pending calls map.
(dbus_g_proxy_constructor): New.
(dbus_g_proxy_class_init): Add get/set property functions,
constructor, and add NAME, PATH, and INTERFACE properties.
(cancel_pending_call): New function.
(dbus_g_proxy_dispose): Iterate over any outstanding calls and
cancel them.
(dbus_g_proxy_set_property, dbus_g_proxy_get_property): New.
(GPendingNotifyClosure): New structure.
(d_pending_call_notify, d_pending_call_free): Moved here from
dbus-glib.c.
(DBUS_G_VALUE_ARRAY_COLLECT_ALL): Moved around to satisfy function
ordering.
(manager_begin_bus_call): New internal function for talking to
internal bus proxy.
(dbus_g_proxy_new): Construct object using GObjet properties.
(dbus_g_proxy_begin_call_internal): Update to take user data, etc.
Create closure of same, and insert call into map of pending calls.
(dbus_g_proxy_end_call_internal): Take call id instead of pending
call.  Look up pending call in current set.  Remove it when we've
completed.
(dbus_g_pending_call_end, dbus_g_proxy_end_call_internal): Delete.
(dbus_g_proxy_begin_call): Change API to take callback, user data,
and destroy function directly.
(dbus_g_proxy_end_call): Update to take DBusGProxyCall.
(dbus_g_proxy_call): Invoke with NULL callback.
(dbus_g_proxy_cancel_call): New function, replaces
dbus_g_pending_call_cancel.

* glib/dbus-gparser.c (validate_signature): Fix call to
dbus_set_g_error.

* glib/dbus-gobject.c (dbus_g_object_type_dbus_metadata_quark):
New quark for attaching metadata to GType.
(info_hash): Delete.
(lookup_object_info): Look up using quark.
(dbus_g_object_type_install_info): Check that a type is classed,
not that it's an object.  Also just install type data using quark
instead of using global hash.

* glib/dbus-glib.c (dbus_g_pending_call_ref)
(dbus_g_pending_call_unref, dbus_pending_call_get_g_type)
(GPendingNotifyClosure): Delete.
(d_pending_call_notify, d_pending_call_free): Move to dbus-gproxy.c.
(dbus_g_pending_call_set_notify, dbus_g_pending_call_cancel): Delete.

* glib/dbus-binding-tool-glib.c (generate_client_glue): Disable async
client method generation until we can fix it...

* tools/dbus-viewer.c (load_child_nodes): Use dbus_g_proxy_call.
(load_from_service_thread_func): Ditto.

* tools/dbus-names-model.c (struct NamesModel): Hold
DBusGProxyCall.
(have_names_notify): Update prototype, use
dbus_g_proxy_cancel_call.
(names_model_reload): Update for new dbus_g_proxy_begin_call API.

* tools/dbus-monitor.c (filter_func): Update for print_message
API change.

* test/glib/test-dbus-glib.c: Add more tests for async
invocations.  Update many begin_call/end_call pairs to just use
dbus_g_proxy_call.

* tools/dbus-send.c (main): Add --print-reply=literal mode.  This
allows us to dump print-introspect.c.

* tools/dbus-print-message.h (print_message): Add literal argument
to print_message which is intended to allow printing arguments without
metadata like "string=".

* tools/dbus-print-message.c (print_iter): Add literal argument.
(print_message): Allow printing string messages literally.

18 years ago2005-07-05 Colin Walters <walters@verbum.org>
Colin Walters [Tue, 5 Jul 2005 16:39:56 +0000 (16:39 +0000)]
2005-07-05  Colin Walters  <walters@verbum.org>

* glib/dbus-gproxy.c (marshal_dbus_message_to_g_marshaller):
Remove value refcount leak, original patch from Jorn Baayen
<jorn@openedhand.com>.  Also remove useless extra value in favor
of prepending to value array directly.

18 years ago2005-07-02 Colin Walters <walters@verbum.org>
Colin Walters [Sat, 2 Jul 2005 06:05:23 +0000 (06:05 +0000)]
2005-07-02  Colin Walters  <walters@verbum.org>

* glib/dbus-gmain.c (_dbus_gmain_test): Fix test.

18 years ago2005-07-01 Colin Walters <walters@verbum.org>
Colin Walters [Fri, 1 Jul 2005 15:44:12 +0000 (15:44 +0000)]
2005-07-01  Colin Walters  <walters@verbum.org>

Patch from Jonathan Matthew <jonathan@kaolin.hn.org>

* glib/dbus-gvalue.c (basic_typecode_to_gtype): Fix return type.
(dbus_g_value_types_init): Marshal G_TYPE_CHAR as DBUS_TYPE_BYTE,
G_TYPE_LONG as DBUS_TYPE_INT32, G_TYPE_ULONG as DBUS_TYPE_UINT32,
and G_TYPE_FLOAT as DBUS_TYPE_DOUBLE.

18 years ago2005-06-30 Colin Walters <walters@verbum.org>
Colin Walters [Thu, 30 Jun 2005 18:22:10 +0000 (18:22 +0000)]
2005-06-30  Colin Walters  <walters@verbum.org>

* test/glib/test-dbus-glib.c:
* test/glib/test-service-glib.c:
* test/glib/test-service-glib.xml: Update tests for new error
setting bits, also add async tests (patch from Ross Burton).

* test/glib/Makefile.am (test_service_glib_LDADD): Add
DBUS_GLIB_THREADS_LIBS.

* glib/dbus-gproxy.c (get_name_owner)
(dbus_g_pending_call_end_valist): Ditto.

* glib/dbus-gobject.c (error_metadata): New mapping from GError
domain (GQuark) to DBusGErrorInfo.
(gerror_domaincode_to_dbus_error_name): Attempt to look up error
quark in error_metadata.  Take message interface as default
error message interface.
(gerror_to_dbus_error_message): Pass message interface.
(dbus_set_g_error): Resurrected.
(dbus_g_error_info_free): New function.
(dbus_g_object_type_install_info): Use g_type_class_ref instead
of _peek to actually create the object class if it hasn't been
created yet.
(dbus_g_error_domain_register): New function.

* glib/dbus-gmain.c (dbus_g_bus_get): Switch to dbus_set_g_error.

* glib/dbus-gparser.c (validate_signature): Ditto.

* dbus/dbus-glib.h (dbus_g_error_set): Delete.
(dbus_g_error_domain_register): Prototype.

* glib/dbus-glib.c (dbus_g_error_set): Delete.
Update tests.

18 years ago2005-06-29 Colin Walters <walters@verbum.org>
Colin Walters [Wed, 29 Jun 2005 23:52:35 +0000 (23:52 +0000)]
2005-06-29  Colin Walters  <walters@verbum.org>

* dbus/dbus-glib.h: Delete DBUS_TYPE_G_PROXY_ARRAY.  Add
DBUS_TYPE_G_OBJECT_PATH.

* glib/dbus-gvalue.c (dbus_g_value_types_init): Remove marshallers
for G_TYPE_OBJECT and DBUS_TYPE_G_PROXY_ARRAY (the latter should
be handled more generically).  Add DBUS_TYPE_G_OBJECT_PATH.
(dbus_g_object_path_get_g_type): New function.
(dbus_gtype_from_signature_iter): Map DBUS_TYPE_OBJECT_PATH
to DBUS_TYPE_G_OBJECT_PATH by default.
(demarshal_proxy): Remove unused name variable.
(demarshal_object_path, marshal_object_path): New functions.
(demarshal_proxy_array, marshal_proxy_array): Delete.

* glib/dbus-binding-tool-glib.c (dbus_g_type_get_c_name): Map
DBUS_TYPE_G_OBJECT_PATH to char *.
(dbus_g_type_get_lookup_function): Map builtin
DBUS_TYPE_G_OBJECT_PATH.

* test/glib/test-dbus-glib.c
* test/glib/test-service-glib.c (my_object_objpath):
Adapt tests to new object path marshalling.

18 years ago* configure.in: force check for Python >= 2.4
John (J5) Palmieri [Wed, 29 Jun 2005 19:12:17 +0000 (19:12 +0000)]
* configure.in: force check for Python >= 2.4

18 years ago2005-06-29 Colin Walters <walters@verbum.org>
Colin Walters [Wed, 29 Jun 2005 17:02:33 +0000 (17:02 +0000)]
2005-06-29  Colin Walters  <walters@verbum.org>

Patch from Ross Burton <ross@openedhand.com>

* glib/dbus-gobject.c (invoke_object_method): Unset object
value in all cases, not only in async case.

18 years ago2005-06-29 Colin Walters <walters@verbum.org>
Colin Walters [Wed, 29 Jun 2005 16:59:00 +0000 (16:59 +0000)]
2005-06-29  Colin Walters  <walters@verbum.org>

* glib/dbus-gproxy.c (struct _DBusGProxy): Add new member
name_call for keeping track of any outgoing GetNameOwner call.
Also add for_owner and associated.
(struct _DBusGProxyManager): Add owner_names, which is hash table
that maps a base name to a list of names it owns (that we're
interested in).  Add pending_nameowner_calls which is a list of
all outstanding GetNameOwner; avoids us having to iterate over
every proxy.  Add unassociated_proxies which keeps track of name
proxies with no associated name owner.
(dbus_g_proxy_manager_unref): Destroy owner_names.
(struct DBusGProxyNameOwnerInfo): New struct for keeping track of
name refcounts.
(find_name_in_info, name_owner_foreach)
(dbus_g_proxy_manager_lookup_name_owner, insert_nameinfo)
(dbus_g_proxy_manager_monitor_name_owner)
(dbus_g_proxy_manager_unmonitor_name_owner)
(unassociate_proxies, dbus_g_proxy_manager_replace_name_owner):
New functions; they manipulate the owner_names mapping.
(got_name_owner_cb): New function.
(get_name_owner): New function, extracted from
dbus_g_proxy_new_for_name_owner.
(dbus_g_proxy_manager_register): For now we need to keep track of
all NameOwnerChanged.  Also if the proxy is for a name, if we
don't already know the name owner, queue a new GetNameOwner
request and add it to our list of unassociated proxies.  Otherwise
inc the refcount.
(dbus_g_proxy_manager_unregister): If this proxy is for a name,
cancel any pending GetNameOwner call, etc.
(dbus_g_proxy_manager_filter): Handle NameOwnerChanged.  Also use
the owner_names mapping to look up the current names for the
signal source, and dispatch to any proxies for that name.
(dbus_g_proxy_new): Initialize new members.
(dbus_g_proxy_new_for_name): Delete unused proxy variable.
(dbus_g_proxy_new_for_name_owner): Use get_name_owner.
(dbus_g_pending_call_end_valist): New function, extracted from
dbus_g_proxy_end_call_internal.  Useful when we don't have a proxy
but want to use the GLib infrastructure.  Also note how many
arguments in reply were over.
(dbus_g_pending_call_end): New function, just call
dbus_g_pending_call_end_valist.
(dbus_g_proxy_end_call_internal): Just call
dbus_g_pending_call_end_valist.

* glib/dbus-gobject.c (_dbus_gobject_lookup_marshaller): Fix lookup
of builtin marshaller for STRING_STRING_STRING.

* test/glib/test-dbus-glib.c:
* test/glib/test-service-glib.c:
* test/glib/test-service-glib.xml:
Extend tests to cover name proxies, destruction of owner proxies,
etc.

* glib/examples/example-signal-recipient.c
(dbus_g_proxy_new_for_name_owner): Create a name proxy.

* tools/dbus-send.c (main): Print D-BUS error name in addition
to message.

18 years ago* python/dbus_bindings.pyx.in (cunregister_function_handler,
John (J5) Palmieri [Tue, 28 Jun 2005 19:36:51 +0000 (19:36 +0000)]
* python/dbus_bindings.pyx.in (cunregister_function_handler,
  cmessage_function_handler): Patch from
  Anthony Baxter <anthony@interlink.com.au> fixes threading problems
  by using the Py_GILState_Ensure/Release to synchronize with the
  python runtime.

18 years ago2005-06-28 Ray Strode <rstrode@redhat.com>
Ray Strode [Tue, 28 Jun 2005 15:14:21 +0000 (15:14 +0000)]
2005-06-28  Ray Strode  <rstrode@redhat.com>

*  dbus/dbus-spawn.c (_dbus_babysitter_unref): kill
babysitter helper process on last unref, bug #2813.

18 years ago2005-06-27 Colin Walters <walters@verbum.org>
Colin Walters [Mon, 27 Jun 2005 18:20:20 +0000 (18:20 +0000)]
2005-06-27  Colin Walters  <walters@verbum.org>

* test/glib/test-dbus-glib.c:
* test/glib/test-service-glib.c:
* test/glib/test-service-glib.xml:
Test hash table signal emitting.

* glib/dbus-gobject.c (_dbus_gobject_lookup_marshaller): Convert
types to their fundamental basis types, since this is what
marshallers operate on.  Also add an entry for VOID__BOXED.
(dbus_g_object_register_marshaller_array): Convert to fundamental.

18 years ago2005-06-26 Havoc Pennington <hp@redhat.com>
Havoc Pennington [Mon, 27 Jun 2005 01:37:03 +0000 (01:37 +0000)]
2005-06-26  Havoc Pennington  <hp@redhat.com>

* doc/dbus-tutorial.xml: fix names of interface/service/path, fix
from Don Park

18 years ago2005-06-26 Colin Walters <walters@verbum.org>
Colin Walters [Sun, 26 Jun 2005 17:02:09 +0000 (17:02 +0000)]
2005-06-26  Colin Walters  <walters@verbum.org>

* glib/dbus-glib.c (dbus_set_g_error): Delete.
(dbus_g_error_set): New public function from its ashes; used by
both service-side method implementation and GLib bindings
internals.
(dbus_g_error_has_name, dbus_g_error_get_name): New function.
(_dbus_glib_test): Add some tests.

* test/glib/test-dbus-glib.c (main): Test dbus_g_error_has_name.

* test/glib/test-service-glib.c (my_object_throw_error): Use
dbus_g_error_set.

* glib/dbus-gobject.c (gerror_to_dbus_error_message): Handle
errors thrown by dbus_g_error_set.

* glib/dbus-gmain.c (dbus_g_bus_get): Change to dbus_g_error_set.

* glib/dbus-gparser.c (validate_signature): Ditto.

* glib/dbus-gproxy.c (dbus_g_proxy_new_for_name_owner)
(dbus_g_proxy_end_call_internal): Ditto.

* glib/Makefile.am: Generate dbus-glib-error-switch.h, which
converts DBUS_ERROR_x to DBUS_GERROR_x.
(libdbus_glib_1_la_SOURCES, BUILT_SOURCES, CLEANFILES): Add it.

* doc/TODO: Remove error TODO.

* doc/dbus-tutorial.xml: Update with documentation about error
handling.

* dbus/make-dbus-glib-error-enum.sh: Tighten up regexp to make
sure we only change DBUS_ERROR to DBUS_GERROR, not all ERROR to
GERROR.  Also add DBUS_GERROR_REMOTE_EXCEPTION.

19 years ago2005-06-22 Colin Walters <walters@verbum.org>
Colin Walters [Wed, 22 Jun 2005 23:35:32 +0000 (23:35 +0000)]
2005-06-22  Colin Walters  <walters@verbum.org>

Patch from Ross Burton <ross@openedhand.com>

* glib/dbus-gobject.c (dbus_g_method_return): Free out_sig.

19 years ago2005-06-20 Colin Walters <walters@verbum.org>
Colin Walters [Tue, 21 Jun 2005 01:18:25 +0000 (01:18 +0000)]
2005-06-20  Colin Walters  <walters@verbum.org>

* configure.in: Add glib/examples.

* glib/Makefile.am: Add examples/

* glib/examples/.cvsignore
* glib/examples/Makefile.am
* glib/examples/example-client.c
* glib/examples/example-service.c
* glib/examples/example-service.xml
* glib/examples/example-signal-emitter.c
* glib/examples/example-signal-emitter.xml
* glib/examples/example-signal-recipient.c:
New files; GLib binding examples, ported from
python/examples.

19 years ago2005-06-20 Colin Walters <walters@verbum.org>
Colin Walters [Tue, 21 Jun 2005 00:30:20 +0000 (00:30 +0000)]
2005-06-20  Colin Walters  <walters@verbum.org>

* dbus/dbus-glib.h:
* glib/dbus-gproxy.c: Rename dbus_g_proxy_invoke to
dbus_g_proxy_call.

* glib/dbus-binding-tool-glib.c:
* doc/dbus-tutorial.xml:
* test/glib/test-dbus-glib.c: Update for rename.

19 years ago2005-06-20 Colin Walters <walters@verbum.org>
Colin Walters [Mon, 20 Jun 2005 19:54:22 +0000 (19:54 +0000)]
2005-06-20  Colin Walters  <walters@verbum.org>

Patch suggested by Ross Burton <ross@openedhand.com>

* glib/dbus-gobject.c (export_signals): Free signal name.
(g_value_init): Use G_VALUE_NOCOPY_CONTENTS to plug
memory leak.  Add a bit of documentation.
(dbus_g_method_return_error): Free context, and note we do
so.

19 years ago2005-06-18 Murray Cumming <murrayc@murrayc.com>
Murray Cumming [Sun, 19 Jun 2005 15:31:25 +0000 (15:31 +0000)]
2005-06-18  Murray Cumming  <murrayc@murrayc.com>

        * dbus/dbus-glib.h:
        * glib/dbus-gobject.c:
        * glib/dbus-gproxy.c:
        * glib/dbus-gvalue.c: Predeclare structs as
        typedef struct _Something Something instead of
        typedef struct Something Something, so we can
        redeclare the prototypes. Other GNOME libraries
        do this already.

19 years ago2005-06-17 Colin Walters <walters@verbum.org>
Colin Walters [Fri, 17 Jun 2005 17:10:41 +0000 (17:10 +0000)]
2005-06-17  Colin Walters  <walters@verbum.org>

* tools/dbus-names-model.c (have_names_notify): Fix call
to dbus_g_proxy_end_call.

19 years ago2005-06-17 Colin Walters <walters@verbum.org>
Colin Walters [Fri, 17 Jun 2005 14:29:48 +0000 (14:29 +0000)]
2005-06-17  Colin Walters  <walters@verbum.org>

* glib/dbus-gproxy.c (dbus_g_proxy_emit_remote_signal): Don't
spew warnings if we get malformed remote signals.

* glib/dbus-gobject.c (propsig_iterate): New function.
(lookup_object_info): New function, extracted from
lookup_object_and_method.
(introspect_properties, introspect_signals): Delete; these
are merged into write_interface.
(write_interface): Write out signals and properties here;
dump the org.gtk.object stuff and use the interface given
in the introspection data blob.  Also fix up property XML.
(lookup_values): New function.
(introspect_interfaces): Gather a mapping from interface to a
list of its methods, signals, and properties, then write out
each interface.
(lookup_object_and_method): Use lookup_object_info.
(struct DBusGSignalClosure): Add interface.
(dbus_g_signal_closure_new): Add interface. Don't dup signame;
we can just use the constant data.
(dbus_g_signal_closure_finalize): Don't free signal name.
(signal_emitter_marshaller): Use interface from signal closure.
(export_signals): Only export signals mentioned in introspection
blob.
(dbus_g_connection_register_g_object): Warn if we have no
introspection data for an object.
(funcsig_equal): Remove unused variable.
(dbus_g_object_register_marshaller): Take varargs instead of
list.
(dbus_g_object_register_marshaller_array): New function,
extracted from old dbus_g_object_register_marshaller.

* glib/dbus-binding-tool-glib.c (struct DBusBindingToolCData): Add
signals and property data.
(write_quoted_string): New function, extracted from generate_glue.
(generate_glue): Write signals and properties to introspection
blob.

* dbus/dbus-glib.h (struct DBusGObjectInfo): Include
exported_signals and exported_properties.
(dbus_g_object_register_marshaller): Update prototype.
(dbus_g_object_register_marshaller_array): Prototype.

* test/glib/test-dbus-glib.c: Extend testing to cover new signals.

* test/glib/test-service-glib.c: Add new test signals and method
to emit them.

* test/glib/test-service-glib.xml: Add some test signals.

* test/glib/Makefile.am (BUILT_SOURCES): Add my-object-marshal.c
and my-object-marshal.h
(test_service_glib_SOURCES, test_dbus_glib_SOURCES): Add
my-object-marshal.c.
(my-object-marshal.c, my-object-marshal.h): Implement.

* test/glib/.cvsignore: Update.

* doc/TODO: Remove two GLib TODO items fixed by this
patch.

19 years ago2005-06-16 Colin Walters <walters@verbum.org>
Colin Walters [Thu, 16 Jun 2005 19:57:31 +0000 (19:57 +0000)]
2005-06-16  Colin Walters  <walters@verbum.org>

* doc/TODO: Update for GLib bindings.

19 years ago2005-06-16 Colin Walters <walters@verbum.org>
Colin Walters [Thu, 16 Jun 2005 19:50:25 +0000 (19:50 +0000)]
2005-06-16  Colin Walters  <walters@verbum.org>

* glib/dbus-binding-tool-glib.c:
* glib/dbus-gobject.c:
* glib/dbus-gproxy.c:  Add Nokia copyright; Patch
from Ross Burton, for his GLib bindings work.

19 years ago2005-06-16 Colin Walters <walters@verbum.org>
Colin Walters [Thu, 16 Jun 2005 19:45:49 +0000 (19:45 +0000)]
2005-06-16  Colin Walters  <walters@verbum.org>

* glib/dbus-gobject.c (funcsig_hash, funcsig_equal): Use n_params
to iterate instead of walking to G_TYPE_INVALID.

Patch based on a patch from Ryan Gammon.

19 years ago2005-06-16 Colin Walters <walters@verbum.org>
Colin Walters [Thu, 16 Jun 2005 06:05:09 +0000 (06:05 +0000)]
2005-06-16  Colin Walters  <walters@verbum.org>

* bus/bus.c (bus_context_new): Set parser to NULL
after we unref it (Patch from Chris Boscolo, #2174).

19 years ago2005-06-16 Colin Walters <walters@verbum.org>
Colin Walters [Thu, 16 Jun 2005 05:51:46 +0000 (05:51 +0000)]
2005-06-16  Colin Walters  <walters@verbum.org>

* python/dbus_bindings.pyx.in: Import size_t,
__int64_t, __uint64_t, and __signed.

* dbus/dbus-sysdeps.c <HAVE_CMSGCRED> (write_credentials_byte):
Define cmsg struct, output it.
(_dbus_read_credentials_unix_socket):
Use cmsg struct.

Patch from Joe Markus Clarke for FreeBSD support.

19 years ago2005-06-16 Colin Walters <walters@verbum.org>
Colin Walters [Thu, 16 Jun 2005 04:48:10 +0000 (04:48 +0000)]
2005-06-16  Colin Walters  <walters@verbum.org>

* tools/dbus-send.c (append_array): Use strtok.
(append_dict): New function.
(type_from_name): New function, extracted from main.
(main): Handle sending dicts.

* tools/dbus-print-message.c (print_iter): Print dict
entries.

19 years ago2005-06-16 Colin Walters <walters@verbum.org>
Colin Walters [Thu, 16 Jun 2005 04:38:11 +0000 (04:38 +0000)]
2005-06-16  Colin Walters  <walters@verbum.org>

* glib/dbus-gvalue.c (marshal_basic): Marshal NULL string
values as the empty string (#2948).

19 years ago2005-06-16 Colin Walters <walters@verbum.org>
Colin Walters [Thu, 16 Jun 2005 04:32:50 +0000 (04:32 +0000)]
2005-06-16  Colin Walters  <walters@verbum.org>

* dbus/Makefile.am:
* mono/doc/Makefile.am:
* test/glib/Makefile.am:

Fix srcdir != builddir issues (Patch from Chris Wilson, #3477)

19 years ago2005-06-16 Colin Walters <walters@verbum.org>
Colin Walters [Thu, 16 Jun 2005 04:27:45 +0000 (04:27 +0000)]
2005-06-16  Colin Walters  <walters@verbum.org>

* dbus/dbus-marshal-header.c (_dbus_header_load): Set
header byte order from expected byte order (Patch from Chris Wilson, #3475).

* dbus/dbus-marshal-byteswap.c (byteswap_body_helper):
Increment pointer after swapping fixed array.  Add assertion
for array length.

19 years ago2005-06-15 Colin Walters <walters@verbum.org>
Colin Walters [Wed, 15 Jun 2005 19:33:04 +0000 (19:33 +0000)]
2005-06-15  Colin Walters  <walters@verbum.org>

* dbus/dbus-sysdeps.c <HAVE_CMSGCRED> (_dbus_read_credentials_unix_socket):
Fix call to dbus_set_error.  (Patch from Michael Banck, #3461)

19 years ago* Bumped version for CVS HEAD
John (J5) Palmieri [Wed, 15 Jun 2005 18:35:18 +0000 (18:35 +0000)]
* Bumped version for CVS HEAD

19 years ago* NEWS: Update to 0.34 dbus-0.34.0
John (J5) Palmieri [Wed, 15 Jun 2005 18:32:32 +0000 (18:32 +0000)]
* NEWS: Update to 0.34

19 years ago * dbus/dbus-connection.c (_dbus_connection_peer_filter): New method
John (J5) Palmieri [Wed, 15 Jun 2005 16:20:28 +0000 (16:20 +0000)]
    * dbus/dbus-connection.c (_dbus_connection_peer_filter): New method
        (_dbus_connection_run_builtin_filters): New method
        (dbus_connection_dispatch): Run the builtin filters which in turn
        runs the peer filter which handles Ping messages.

        * doc/TODO:
         - Ping isn't handled: This patch fixes it

         - Add a test case for the Ping message: added TODO item

19 years ago * dbus/dbus-message.c:
John (J5) Palmieri [Wed, 15 Jun 2005 15:59:57 +0000 (15:59 +0000)]
    * dbus/dbus-message.c:
        (dbus_message_has_path): New method
        (dbus_message_has_interface): New method
        (dbus_message_has_member): New method

        * dbus/dbus/dbus-sysdeps.c (_dbus_check_dir_is_private_to_user):
        New method

        * dbus/dbus-keyring.c (_dbus_keyring_reload): Check to see that
        the keyring directory is private to the user

        * doc/TODO:
         - The convenience functions in dbus-bus.h should perhaps have
         the signatures that they would have if they were autogenerated
         stubs. e.g. the acquire service function. We should also evaluate
         which of these functions to include, in light of the fact that
         GLib/Qt native stubs will probably also exist.: Punted

         - add dbus_message_has_path(), maybe has_member/interface:
         fixed in this patch

         - in dbus-keyring.c, enforce that the keyring dir is not
         world readable/writable: Fixed in this patch

19 years ago * dbus/dbus-marshal-validate.h: Added a new validation
John (J5) Palmieri [Wed, 15 Jun 2005 15:15:32 +0000 (15:15 +0000)]
* dbus/dbus-marshal-validate.h: Added a new validation
        error code DBUS_VALIDITY_UNKNOWN_OOM_ERROR = -4 for
        out of memory errors when validating signitures

        * dbus/dbus-marshal-header.c: use DBUS_VALIDITY_UNKNOWN_OOM_ERROR
        in places where we previously used DBUS_VALID and a FALSE return
        value to indicate OOM

        * dbus/dbus-marshal-validate.c (_dbus_validate_signature_with_reason):
        Use a stack to track the number of elements inside containers.  The
        stack values are then used to validate that dict entries have only two
        elements within them.
        (validate_body_helper): check the reason for failure when validating
        varients

        * dbus/dbus-message.c (load_message): use
        DBUS_VALIDITY_UNKNOWN_OOM_ERROR in places where we previously used
        DBUS_VALID and a FALSE return value to indicate OOM

        * doc/TODO: remove "- validate dict entry number of fields" as this
        patch fixes it

19 years ago2005-06-14 David Zeuthen <davidz@redhat.com>
David Zeuthen [Wed, 15 Jun 2005 02:31:38 +0000 (02:31 +0000)]
2005-06-14  David Zeuthen  <davidz@redhat.com>

        * bus/bus.c (process_config_every_time): Drop existing conf-dir
        watches (if applicable) and add new watches

        * bus/main.c (signal_handler): Handle SIGIO if using D_NOTIFY
        (main): Setup SIGIO signal handler if using D_NOTIFY

        * bus/config-parser.h: Add prototype bus_config_parser_get_conf_dirs

        * bus/config-parser.c (struct BusConfigParser): Add conf_dirs list
        (merge_included): Also merge conf_dirs list
        (bus_config_parser_unref): Clear conf_dirs list
        (include_dir): Add directory to conf_dirs list
        (bus_config_parser_get_conf_dirs): New function

        * bus/dir-watch.[ch]: New files

        * bus/Makefile.am (BUS_SOURCES): Add dir-watch.[ch]

        * configure.in: Add checks for D_NOTIFY on Linux

19 years ago2005-06-14 Colin Walters <walters@verbum.org>
Colin Walters [Tue, 14 Jun 2005 15:55:10 +0000 (15:55 +0000)]
2005-06-14  Colin Walters  <walters@verbum.org>

* glib/dbus-binding-tool-glib.c:
* glib/dbus-gobject.c:
* glib/dbus-gvalue.c: Fix indentation and brace style.

19 years ago2005-06-14 Ross Burton <ross@burtonini.com>.
Colin Walters [Tue, 14 Jun 2005 15:52:41 +0000 (15:52 +0000)]
2005-06-14  Ross Burton <ross@burtonini.com>.

* glib/dbus-glib.h: Make DBusGMethodInvocation
a private structure.  Rearrange prototypes a bit.

* glib/dbus-gproxy.c (dbus_g_proxy_invoke): Add
documentation for first_arg_type.

* glib/dbus-gobject.c: Move DBusGMethodInvocation
here, add documentation.  Move dbus_g_method_return
and dbus_g_method_return_error into public API
section.

19 years ago2005-06-14 Colin Walters <walters@verbum.org>
Colin Walters [Tue, 14 Jun 2005 14:23:56 +0000 (14:23 +0000)]
2005-06-14  Colin Walters  <walters@verbum.org>

* glib/dbus-gobject.c (_dbus_gobject_lookup_marshaller):
Add missing return statements, noticed by Ross Burton.

19 years ago2005-06-13 Ross Burton <ross@burtonini.com>.
Colin Walters [Mon, 13 Jun 2005 15:36:31 +0000 (15:36 +0000)]
2005-06-13  Ross Burton <ross@burtonini.com>.

* glib/dbus-gobject.c: Handle errors on message
demarshalling by sending error message back.
* glib/dbus-gvalue.c: Initialize return variables.

19 years ago2005-06-13 Colin Walters <walters@verbum.org>
Colin Walters [Mon, 13 Jun 2005 15:34:14 +0000 (15:34 +0000)]
2005-06-13  Colin Walters  <walters@verbum.org>

* glib/Makefile.am: Fix thinko in last patch.

19 years ago2005-06-13 Colin Walters <walters@verbum.org>
Colin Walters [Mon, 13 Jun 2005 14:56:51 +0000 (14:56 +0000)]
2005-06-13  Colin Walters  <walters@verbum.org>

* glib/Makefile.am: Move dbus-gtype-specialized.c
and dbus-gtype-specialized.h into a _HEADERS variable,
install them.

19 years ago2005-06-12 Colin Walters <walters@verbum.org>
Colin Walters [Mon, 13 Jun 2005 03:01:30 +0000 (03:01 +0000)]
2005-06-12  Colin Walters  <walters@verbum.org>

Async signals and various bugfixes and testing by
Ross Burton <ross@burtonini.com>.

* glib/dbus-gvalue.h: (struct DBusBasicGValue): Delete.
(dbus_gvalue_genmarshal_name_from_type)
(dbus_gvalue_ctype_from_type): Moved to dbus-binding-tool-glib.c.
(dbus_gtype_to_dbus_type): Renamed to dbus_gtype_from_signature.
(dbus_g_value_types_init, dbus_gtype_from_signature)
(dbus_gtype_from_signature_iter, dbus_gtype_to_signature)
(dbus_gtypes_from_arg_signature): New function prototypes.
(dbus_gvalue_demarshal): Take context and error arguments.
(dbus_gvalue_demarshal_variant): New function.
(dbus_gvalue_demarshal_message): New function.
(dbus_gvalue_store): Delete.

* glib/dbus-gvalue.c:

File has been almost entirely rewritten; now we special-case
more types such as DBUS_TYPE_SIGNATURE, handle arrays and
hash tables correctly, etc.  Full support for recursive values
is not yet complete.

* glib/dbus-gproxy.c (dbus_g_proxy_class_init): Change last
argument of signal to G_TYPE_POINTER since we now pass a
structure.
(lookup_g_marshaller): Delete in favor of
_dbus_gobject_lookup_marshaller.
(marshal_dbus_message_to_g_marshaller): Use
_dbus_gobject_lookup_marshaller and dbus_gvalue_demarshal_message
to handle remote signal callbacks.
(dbus_g_proxy_new_from_proxy): New function; creates a new
DBusGProxy by copying an existing one.
(dbus_g_proxy_get_interface, dbus_g_proxy_set_interface)
(dbus_g_proxy_get_path): New functions.
(dbus_g_proxy_marshal_args_to_message): New function;
factored out of existing code.
(DBUS_G_VALUE_ARRAY_COLLECT_ALL): Collect all arguments
from a varargs array.
(dbus_g_proxy_begin_call_internal): New function.
(dbus_g_proxy_end_call_internal): New function.
(dbus_g_proxy_begin_call): Take GTypes instead of DBus types
as arguments; simply invoke dbus_g_proxy_begin_call_internal
after collecting args into value array.
(dbus_g_proxy_end_call): Take GTypes instead of DBus types;
invoke dbus_g_proxy_end_call_internal.
(dbus_g_proxy_invoke): Simply invoke begin_call_interanl and
end_call_internal.
(dbus_g_proxy_call_no_reply): Take GTypes instead of DBus
types.
(array_free_all): New function.
(dbus_g_proxy_add_signal): Take GTypes.

* glib/dbus-gobject.h:
(_dbus_glib_marshal_dbus_message_to_gvalue_array): Delete.
(_dbus_gobject_get_path, _dbus_gobject_lookup_marshaller):
Prototype.

* glib/dbus-gobject.c: Add a global marshal_table hash which
stores mappings from type signatures to marshallers.  Change lots
of invocations of dbus_gtype_to_dbus_type to
dbus_gtype_to_signature.
(_dbus_glib_marshal_dbus_message_to_gvalue_array): Delete.
(introspect_signals): Fix test for query.return_type.
(set_object_property): Update invocation of dbus_gvalue_demarshal.
(invoke_object_method): Many changes.  Handle asynchronous
invocations.  Convert arguments with
dbus_gvalue_demarshal_message.  Handle errors.  Use
DBusSignatureIter instead of strlen on args. Handle all arguments
generically.  Special-case variants.
(dbus_g_method_return, dbus_g_method_return_error): New function.
(DBusGSignalClosure): New structure, closes over signal
information.
(dbus_g_signal_closure_new): New function.
(dbus_g_signal_closure_finalize): New function.
(signal_emitter_marshaller): New function; is special marshaller
which emits signals on bus.
(export_signals): New function; introspects object signals and
connects to them.
(dbus_g_object_type_install_info): Take GType instead of
GObjectClass.
(dbus_g_connection_register_g_object): Invoke export_signals.
(dbus_g_connection_lookup_g_object): New function.
(DBusGFuncSignature) New structure; used for mapping type
signatures to marshallers.
(funcsig_hash): New function; hashes DBusGFuncSignature.
(funcsig_equal): New function; compares DBusGFuncSignature.
(_dbus_gobject_lookup_marshaller): New function.
(dbus_g_object_register_marshaller): New function; used to
register a marshaller at runtime for a particular signature.

* glib/dbus-gmain.c (_dbus_gmain_test): Add various tests.

* glib/dbus-binding-tool-glib.h: Add DBUS_GLIB_ANNOTATION_ASYNC
which notes a server method implementation should be
asynchronous.

* glib/dbus-binding-tool-glib.c
(dbus_binding_tool_output_glib_server): Call
dbus_g_value_types_init.
(write_formal_parameters): Use dbus_gtype_from_signature.  Handle
variants specially.
(dbus_g_type_get_lookup_function): Turn GType into an invocation
of a lookup function.
(write_args_for_direction): Use dbus_g_type_get_lookup_function.
(write_untyped_out_args): New method; write output arguments.
(write_formal_declarations_for_direction): Function for
writing prototypes.
(write_formal_parameters_for_direction): Function for
writing implementations.
(write_typed_args_for_direction): Function for writing
arguments prefixed with GTypes.
(write_async_method_client): Write out async version
of method.

* glib/dbus-binding-tool-glib.c: Include dbus-gvalue-utils.h.
(dbus_g_type_get_marshal_name): Move mapping from GType
to marshal name into here.
(dbus_g_type_get_c_name): Move into here.
(compute_marshaller): Convert signature to type with
dbus_gtype_from_signature, use dbus_g_type_get_marshal_name.
(compute_marshaller_name): Ditto.
(compute_marshaller): Handle async signal annotations.
(gather_marshallers): Return if we don't have a known
prefix.
(generate_glue): Collect introspection blob here, and
write all of the blob at the end.  This allows an object
with multiple interfaces to work.
Mark async methods in introspection blob.

* glib/Makefile.am (libdbus_glib_1_la_SOURCES): Add
dbus-gtype-specialized.c, dbus-gtype-specialized.h,
dbus-gvalue-utils.h, dbus-gvalue-utils.c.

* dbus/dbus-glib.h: Don't include dbus-protocol.h; this
avoids people accidentally using DBUS_TYPE_* which should
not be necessary anymore.
Do include dbus-gtype-specialized.h, which are utilities
for GLib container types.
Add various #defines for types such as
DBUS_TYPE_G_BOOLEAN_ARRAY.
(DBusGValueIterator, DBusGValue): Define, not fully used
yet.
(dbus_g_value_get_g_type): Type for recursive value.
(dbus_g_value_open, dbus_g_value_iterator_get_value)
(dbus_g_value_iterator_get_values, dbus_g_value_iterator_recurse)
(dbus_g_value_free): Prototypes.
(dbus_g_object_register_marshaller, dbus_g_proxy_new_from_proxy): Prototype.
(dbus_g_proxy_set_interface): Prototype.
(dbus_g_proxy_begin_call, dbus_g_proxy_end_call)
(dbus_g_proxy_call_no_reply): Take GLib types instead of DBus
types.
(dbus_g_proxy_get_path, dbus_g_proxy_get_interface):
Accessors.
(DBusGAsyncData, DBusGMethodInvocation): Structures for
doing async invocations.
(dbus_g_method_return, dbus_g_method_return_error):
Prototypes.
* doc/dbus-tutorial.xml: Update GLib section.

* tools/dbus-viewer.c (load_child_nodes): Update
for new invocation type of dbus_g_proxy_end_call.
(load_from_service_thread_func): Ditto.

* tools/print-introspect.c (main): Ditto.

* tools/dbus-names-model.c (have_names_notify)
(names_model_reload, names_model_set_connection)
Use GTypes.

* python/Makefile.am (INCLUDES): Define DBUS_COMPILATION,
needed since Python bindings use GLib bindings.

* test/glib/Makefile.am (INCLUDES): Define DBUS_COMPILATION.
Add --prefix argument.

* tools/Makefile.am: Define DBUS_COMPILATION.  Remove
unneeded --ignore-unsupported arg.

* test/glib/test-service-glib.c:
* test/glib/test-service-glib.xml:
* test/glib/test-dbus-glib.c: Add many more tests.

19 years ago2005-06-06 David Zeuthen <davidz@redhat.com>
David Zeuthen [Mon, 6 Jun 2005 18:55:22 +0000 (18:55 +0000)]
2005-06-06  David Zeuthen  <davidz@redhat.com>

        * doc/TODO: Add item about need to remove deprecated functions.

        * dbus/dbus-connection.h: Add prototype for dbus_connection_disconnect

        * dbus/dbus-connection.c (dbus_connection_disconnect): New function
        to repair the ABI which was broken with the last commit.

19 years ago * doc/TODO: remove connection_open/connection_disconnect lacks symmetry item that...
John (J5) Palmieri [Thu, 2 Jun 2005 21:32:31 +0000 (21:32 +0000)]
* doc/TODO: remove connection_open/connection_disconnect lacks symmetry  item that was just fixed

19 years ago * tools/dbus-send.c (main):
John (J5) Palmieri [Thu, 2 Jun 2005 18:22:04 +0000 (18:22 +0000)]
* tools/dbus-send.c (main):
s/dbus_connection_disconnect/dbus_connection_close

* test/glib/test-profile.c (no_bus_thread_func, with_bus_thread_func):
s/dbus_connection_disconnect/dbus_connection_close

* test/test-service.c (path_message_func, filter_func):
s/dbus_connection_disconnect/dbus_connection_close

19 years ago * dbus/dbus-connection.c, dbus/dbus-connection.h
John (J5) Palmieri [Thu, 2 Jun 2005 17:41:04 +0000 (17:41 +0000)]
*  dbus/dbus-connection.c, dbus/dbus-connection.h
(dbus_connection_disconnect): renamed to dbus_connection_close
for API symmetry with dbus_connection_open
(_dbus_connection_open_internal):
s/dbus_connection_disconnect/dbus_connection_close

* dbus/dbus-bus.c (dbus_bus_get):
s/dbus_connection_disconnect/dbus_connection_close

* bus/connection.c (bus_connections_unref,
bus_connections_setup_connection, bus_connections_expire_incomplete):
s/dbus_connection_disconnect/dbus_connection_close

* bus/dispatch.c (bus_dispatch, kill_client_connection,
kill_client_connection_unchecked, check_hello_connection):
s/dbus_connection_disconnect/dbus_connection_close

* bus/bus.c (new_connection_callback):
s/dbus_connection_disconnect/dbus_connection_close

19 years ago2005-05-25 Colin Walters <walters@verbum.org>
Colin Walters [Wed, 25 May 2005 16:03:53 +0000 (16:03 +0000)]
2005-05-25  Colin Walters  <walters@verbum.org>

* dbus/dbus-protocol.h: Move various bus service #defines such
  as DBUS_SERVICE_DBUS and DBUS_NAME_FLAG_PROHIBIT_REPLACEMENT to
  dbus/dbus-shared.h.
* dbus/dbus-shared.h: Various defines moved here.
* dbus/dbus-marshal-header.c: Include dbus-shared.h.

19 years ago* python/__init__.py: Python bindings deserve a minor version
John (J5) Palmieri [Tue, 24 May 2005 16:34:38 +0000 (16:34 +0000)]
* python/__init__.py: Python bindings deserve a minor version
  update.  Upped to (0, 40, 2)

19 years ago* python/decorators.py: add explicitly_pass_message decorator
John (J5) Palmieri [Tue, 24 May 2005 16:30:51 +0000 (16:30 +0000)]
* python/decorators.py: add explicitly_pass_message decorator
  for passing in the dbus message as keyword for edge case signal
  handling

* python/matchrules.py (SignalMatchRule.__repr__): fix output
  to conform with what dbus expects for match rules
  (SignalMatchRule.execute): add the dbus message as a keyword
  if the signal handler has requested it

* python/examples/example/signal-recipient.py: added some more
  examples on how to hook up to signals

* python/proxies.py: minor formatting changes

19 years ago* python/decorators.py: import dbus_bindings
John (J5) Palmieri [Tue, 24 May 2005 00:21:07 +0000 (00:21 +0000)]
* python/decorators.py: import dbus_bindings

* python/matchrules.py (SignalMatchRule, SignalMatchTree,
  SignalMatchNode): new classes that implement wildcard signal
  callback matching using a tree lookup. Heavily modified from a
  patch sent by Celso Pinto (fd.o bug #3241)

* _dbus.py (add_signal_receiver, remove_signal_receiver, _signal_func):
  use new match classes to handle signals.

19 years ago- s/TYPE_PATH/TYPE_OBJECT_PATH
John (J5) Palmieri [Thu, 19 May 2005 20:27:19 +0000 (20:27 +0000)]
- s/TYPE_PATH/TYPE_OBJECT_PATH

19 years ago2005-05-18 Havoc Pennington <hp@redhat.com>
Havoc Pennington [Wed, 18 May 2005 15:44:50 +0000 (15:44 +0000)]
2005-05-18  Havoc Pennington  <hp@redhat.com>

* configure.in: use GLIB_GNU_GETTEXT to get INTLLIBS and require
gettext. Not really worth requiring yet perhaps, but any
production quality 1.0 would require it so we should go ahead and
get things set up. We do have a couple token calls to
bindtextdomain in the code already.