1 2004-05-20 Kristian Høgsberg <krh@redhat.com>
3 Patch from Jon Trowbridge <trow@ximian.com>:
5 * bus/main.c (setup_reload_pipe): Added. Creates a pipe and sets
6 up a watch that triggers a config reload when one end of the pipe
8 (signal_handler): Instead of doing the config reload in our SIGHUP
9 handler, just write to the reload pipe and let the associated
10 watch handle the reload when control returns to the main loop.
12 * bus/driver.c (bus_driver_handle_reload_config): Added.
13 Implements a ReloadConfig method for requesting a configuration
14 file reload via the bus driver.
16 2004-05-19 Owen Fraser-Green <owen@discobabe.net>
18 * HACKING: Updated release instructions concerning the wiki page.
20 2004-05-18 Kristian Høgsberg <krh@redhat.com>
22 * dbus/dbus-auth.c (client_try_next_mechanism): Remove logic to
23 filter against auth->allowed_mechs; we only add allowed mechs in
26 * dbus/dbus-auth-script.c (_dbus_auth_script_run): Add an
27 ALLOWED_MECHS to auth-script format so we can set the list of
30 * data/auth/client-out-of-mechanisms.auth-script: New test to
31 check client disconnects when it is out of mechanisms to try.
33 * dbus/dbus-auth.c (process_command): Remove check for lines
34 longer that 1 MB; we only buffer up maximum 16 kB.
36 * dbus/dbus-transport.c, dbus/dbus-transport-unix.c,
37 dbus/dbus-auth-script.c, dbus/dbus-auth.c, dbus/dbus-auth.h:
38 Remove auth state AUTHENTICATED_WITH_UNUSED_BYTES, instead always
39 assume there might be unused bytes.
41 * dbus/dbus-auth.c (_dbus_auth_do_work): Remove check for
42 client-out-of-mechs, it is handled in process_reject(). Move check
43 for max failures to send_rejected(), as it's a server-only thing.
45 * dbus/dbus-auth.c: Factor out protocol reply code into functions
46 send_auth(), send_data(), send_rejected(), send_error(),
47 send_ok(), send_begin() and send_cancel().
49 2004-05-17 Kristian Høgsberg <krh@redhat.com>
51 Remove base64 encoding, replace with hex encoding. Original patch
52 from trow@ximian.com, added error handling.
54 * dbus/dbus-string.c (_dbus_string_base64_encode)
55 (_dbus_string_base64_decode): Remove.
56 (_dbus_string_hex_decode): Add end_return argument so we can
57 distinguish between OOM and invalid hex encoding.
58 (_dbus_string_test): Remove base64 tests and add test case for
61 * dbus/dbus-keyring.c, dbus/dbus-auth-script.c, dbus/dbus-auth.c:
62 Replace base64 with hex.
64 * test/data/auth/invalid-hex-encoding.auth-script: New test case
65 for invalid hex encoded data in auth protocol.
67 2004-05-17 Olivier Andrieu <oliv__a@users.sourceforge.net>
69 * dbus/dbus-connection.c (check_for_reply_unlocked): plug a memory
72 2004-05-15 Owen Fraser-Green <owen@discobabe.net>
74 * mono/dbus-sharp.dll.config.in: Added for GAC
75 * mono/dbus-sharp.snk: Added for GAC
76 * mono/Assembly.cs.in: Added for GAC
77 * mono/Makefile.am: Changes for GAC installation
78 * configure.in: Added refs for dbus-sharp.dll.config.in and
79 Assembly.cs.in. More fixes for mono testing
80 * mono/example/Makefile.am: Changed var to CSC
81 * Makefile.am: Changed flag name to DBUS_USE_CSC
83 2004-05-15 Owen Fraser-Green <owen@discobabe.net>
85 * mono/Makefile.am: Added SUBDIRS for docs. Changed SUBDIRS order
86 * mono/doc/*: Added documentation framework
87 * configure.in: Added monodoc check
88 * README: Added description of mono configure flags
90 2004-05-11 John (J5) Palmieri <johnp@redhat.com>:
92 * doc/dbus-specification.xml: Added a "Required" column to the
93 header fields table and changed the "zero or more" verbage in
94 the above paragraph to read "The header must contain the required
95 named header fields and zero or more of the optional named header
97 * test/data/invalid-messages/*.message: Added the required PATH
98 named header field to the tests so that they don't fail on
101 2004-05-07 John (J5) Palmieri <johnp@redhat.com>
103 * python/dbus-bindings.pyx.in: Stopped the bindings from trashing
104 the stack by implicitly defining variable and parameter types and
105 removing the hack of defining C pointers as python objects and later
108 2004-05-02 Owen Fraser-Green <owen@discobabe.net>
110 * mono/Makefile.am: Removed test-dbus-sharp.exe from all target
112 2004-05-01 Owen Fraser-Green <owen@discobabe.net>
114 * mono/DBusType/Dict.cs: Handle empty dicts
115 * mono/DBusType/Array.cs: Handle empty arrays
116 * mono/Arguments.cs: Handle empty arguments
118 2004-04-30 Owen Fraser-Green <owen@discobabe.net>
120 * dbus-sharp.pc.in: Modified to include include Libs and Requires
123 2004-04-25 Kristian Høgsberg <krh@redhat.com>
125 * test/data/valid-messages/standard-*.message: Update message
126 test scripts to new header field names.
128 2004-04-22 John (J5) Palmieri <johnp@redhat.com>
130 * test/break-loader.c (randomly_do_n_things): tracked down buffer
131 overflow to times_we_did_each_thing array which would chop off the
132 first character of the failure_dir string. Increased the size of
133 the array to 7 to reflect the number of random mutation functions
136 2004-04-21 Kristian Høgsberg <krh@redhat.com>
138 * dbus/dbus-server-unix.c (unix_finalize): Don't unref
139 unix_server->watch here, it is unreffed in disconnect.
140 (_dbus_server_new_for_tcp_socket): convert NULL host to
141 "localhost" here so we don't append NULL to address.
143 * dbus/dbus-server.c (_dbus_server_test): Add test case for
144 various addresses, including tcp with no explicit host.
146 2004-04-21 Olivier Andrieu <oliv__a@users.sourceforge.net>
148 * dbus/dbus-message.c (decode_header_data, decode_string_field):
149 fix incorrect setting of .name_offset in the HeaderField (it was
150 off by two bytes, positioned right after the name and typecode)
152 * bus/bus.c (bus_context_new, bus_context_unref): test before
153 calling dbus_server_free_data_slot and _dbus_user_database_unref
156 * tools/Makefile.am: add $(DBUS_GLIB_TOOL_LIBS), xml libs needed
159 2004-04-19 Kristian Høgsberg <krh@redhat.com>
161 * dbus/dbus-transport-unix.c (unix_do_iteration): Rewrite to use
162 _dbus_poll() instead of select().
164 2004-04-15 Jon Trowbridge <trow@ximian.com>
166 * bus/main.c (signal_handler): Reload the configuration files
168 (main): Set up our SIGHUP handler.
170 * bus/bus.c (struct BusContext): Store the config file, user and
171 fork flag in the BusContext.
172 (process_config_first_time_only): Added. Contains the code
173 (previously in bus_context_new) for setting up the BusContext from
174 the BusConfigParser that should only be run the first time the
175 config files are read.
176 (process_config_every_time): Added. Contains the code (previously
177 in bus_context_new) for setting up the BusContext from the
178 BusConfigParser that should be run every time the config files are
180 (load_config): Added. Builds a BusConfigParser from the config
181 files and passes the resulting structure off to
182 process_config_first_time_only (assuming this is the first time)
183 and process_config_every_time.
184 (bus_context_new): All of the config-related code has been moved
185 to process_config_first_time_only and process_config_every_time.
186 Now this function just does the non-config-related initializations
187 and calls load_config.
188 (bus_context_reload_config): Added.
190 2004-04-15 Olivier Andrieu <oliv__a@users.sourceforge.net>
192 * bus/driver.c (bus_driver_handle_get_service_owner):
193 implement a GetServiceOwner method.
194 * doc/dbus-specification.xml: document it.
195 * dbus/dbus-errors.h: add a 'ServiceHasNoOwner' error.
197 * glib/dbus-gproxy.c (dbus_gproxy_new_for_service_owner):
198 implement, using the bus GetServiceOwner method.
200 * test/glib/test-dbus-glib.c:
201 use dbus_gproxy_new_for_service_owner so that we can receive the
204 2004-04-15 John (J5) Palmieri <johnp@redhat.com>
206 * dbus/dbus-internals.c, dbus/dbus-message-builder.c,
207 dbus/dbus-message.c, dbus/dbus-protocol.h
208 (DBUS_HEADER_FIELD_SERVICE): renamed DBUS_HEADER_FIELD_DESTINATION
210 * dbus/dbus-internals.c, dbus/dbus-message-builder.c,
211 dbus/dbus-message.c, dbus/dbus-protocol.h
212 (DBUS_HEADER_FIELD_SENDER_SERVICE): renamed DBUS_HEADER_FIELD_SENDER
214 * dbus/dbus-internals.c (_dbus_header_field_to_string):
215 DBUS_HEADER_FIELD_DESTINATION resolves to "destination"
216 DBUS_HEADER_FIELD_SENDER resolves to "sender"
218 * doc/dbus-specification.xml (Header Fields Table):
219 s/SERVICE/DESTINATION
220 s/SENDER_SERVICE/SENDER
223 2004-04-14 Olivier Andrieu <oliv__a@users.sourceforge.net>
225 * test/glib/test-dbus-glib.c (timed_exit): fail the test after
228 2004-04-13 Michael Meeks <michael@ximian.com>
230 * glib/dbus-gobject.c (handle_introspect): split out
231 (introspect_properties): this.
232 (handle_introspect): implement this.
234 * test/glib/Makefile.am: use the absolute path so the bus
235 daemon's chdir ("/") doesn't kill us dead.
237 * configure.in: subst ABSOLUTE_TOP_BUILDDIR
239 2004-04-12 Jon Trowbridge <trow@ximian.com>
241 * bus/config-parser.c (struct BusConfigParser): Added
242 included_files field.
243 (seen_include): Added. Checks whether or not a file has already
244 been included by any parent BusConfigParser.
245 (bus_config_parser_new): Copy the parent's included_files.
246 (include_file): Track which files have been included, and fail on
248 (process_test_valid_subdir): Changed printf to report if we are
249 testing valid or invalid conf files.
250 (all_are_equiv): Changed printf to be a bit clearer about
251 what we are actually doing.
252 (bus_config_parser_test): Test invalid configuration files.
254 2004-04-09 Jon Trowbridge <trow@ximian.com>
256 * bus/config-parser.c (bus_config_parser_new): Added a 'parent'
257 argument. If non-null, the newly-constructed BusConfigParser will
258 be initialized with the parent's BusLimits instead of the default
260 (include_file): When including a config file, pass in
261 the current parser as the parent and then copy the BusLimits
262 from the included BusConfigParser pack to the current parser.
263 (process_test_valid_subdir): Renamed from process_test_subdir.
264 (process_test_equiv_subdir): Added. Walks through a directory,
265 descending into each subdirectory and loading the config files
266 it finds there. If any subdirectory contains two config files
267 that don't produce identical BusConfigParser structs, fail.
268 For now, the BusConfigParser's BusPolicies are not compared.
269 (bus_config_parser_test): Call both process_test_valid_subdir and
270 process_test_equiv_subdir.
272 * bus/config-loader-libxml.c (bus_config_load): Take a parent
273 argument and pass it along to the call to bus_config_parser_new.
274 Also made a few small changes to allow this code to compile.
276 * bus/config-loader-expat.c (bus_config_load): Take a parent
277 argument and pass it along to the call to bus_config_parser_new.
279 * bus/bus.c (bus_context_new): Load the config file
280 with a NULL parent argument.
282 2004-03-29 Michael Meeks <michael@ximian.com>
284 * glib/dbus-gobject.c (introspect_properties): split
285 out, fix mangled 'while' flow control.
286 (introspect_signals): implement.
287 (handle_introspect): update.
289 2004-03-29 Michael Meeks <michael@ximian.com>
291 * glib/dbus-gobject.c (set_object_property): split out /
292 re-work, use the property type, and not the message type(!)
293 (get_object_property): ditto.
295 * glib/dbus-gvalue.c (dbus_gvalue_demarshal),
296 (dbus_gvalue_marshal): make this code re-usable, needed
297 for signals too, also on both proxy and server side.
298 Re-write for more efficiency / readability.
300 2004-03-29 Michael Meeks <michael@ximian.com>
302 * dbus/dbus-message.c
303 (dbus_message_new_error_printf): impl.
305 * dbus/dbus-connection.c
306 (dbus_connection_unregister_object_path): fix warning.
308 * configure.in: fix no-mono-installed situation.
310 2004-03-27 Havoc Pennington <hp@redhat.com>
312 Patch from Timo Teräs:
314 * tools/dbus-send.c (main): if --print-reply, assume type is
315 method call; support boolean type args
317 * dbus/dbus-connection.c (dbus_connection_send_with_reply): fix a
318 bunch of memleak and logic bugs
320 2004-03-23 Owen Fraser-Green <owen@discobabe.net>
323 * mono/Introspector.cs:
325 * mono/InterfaceProxy.cs:
327 * mono/ProxyBuilder.cs:
329 Added InterfaceProxy class to avoid building proxies for every
333 * dbus-message.c (dbus_message_append_args_valist)
334 (dbus_message_iter_get_object_path)
335 (dbus_message_iter_get_object_path_array)
336 (dbus_message_iter_append_object_path)
337 (dbus_message_iter_append_object_path_array):
338 Added object_path iter functions to handle OBJECT_PATH arguments
340 2004-03-23 Owen Fraser-Green <owen@discobabe.net>
342 First checkin of mono bindings.
345 Build stuff for the bindings
346 * dbus-sharp.pc.in: Added for pkgconfig
348 2004-03-21 Havoc Pennington <hp@redhat.com>
350 * test/test-service.c (main): remove debug spew
352 2004-03-21 Olivier Andrieu <oliv__a@users.sourceforge.net>
354 * dbus/dbus-marshal.c (_dbus_marshal_validate_arg): accept empty
357 * dbus/dbus-message.h, bus/dbus-message.c (dbus_message_iter_init)
358 (dbus_message_iter_init_array_iterator)
359 (dbus_message_iter_init_dict_iterator): return a dbus_bool_t to
360 indicate whether the iterator is empty
362 * dbus/dbus-pending-call.c, dbus/dbus-server.c: silence compiler
365 2004-03-19 Havoc Pennington <hp@redhat.com>
371 * doc/Makefile.am: add all XMLTO usage to DBUS_XML_DOCS_ENABLED
373 * python/Makefile.am: change to avoid dist of dbus_bindings.c so
374 you don't need pyrex to make dist
376 * qt/Makefile.am (libdbus_qt_1_la_SOURCES): add integrator.h to
379 2004-03-18 Richard Hult <richard@imendio.com>
381 * dbus/dbus-message.c (dbus_message_get_auto_activation)
382 (dbus_message_set_auto_activation): Add doxygen docs.
384 2004-03-16 Richard Hult <richard@imendio.com>
386 * bus/activation.c: (bus_activation_service_created),
387 (bus_activation_send_pending_auto_activation_messages),
388 (bus_activation_activate_service):
390 * bus/dispatch.c: (bus_dispatch),
391 (check_nonexistent_service_auto_activation),
392 (check_service_auto_activated),
393 (check_segfault_service_auto_activation),
394 (check_existent_service_auto_activation), (bus_dispatch_test):
395 * bus/driver.c: (bus_driver_handle_activate_service):
396 * bus/services.c: (bus_registry_acquire_service):
397 * dbus/dbus-message.c: (dbus_message_set_auto_activation),
398 (dbus_message_get_auto_activation):
399 * dbus/dbus-message.h:
400 * dbus/dbus-protocol.h: Implement auto-activation.
402 * doc/dbus-specification.xml: Add auto-activation to the spec.
404 2004-03-12 Olivier Andrieu <oliv__a@users.sourceforge.net>
406 * dbus/dbus-marshal.c (_dbus_marshal_get_arg_end_pos):
407 fix a bug with CUSTOM types.
409 * dbus/dbus-message.c (message_iter_test, _dbus_message_test): add
410 a unit test for this bug (used to fail).
412 2004-03-12 Mikael Hallendal <micke@imendio.com>
415 (babysitter_watch_callback): notify all pending activations waiting for
416 the same exec that the activation failed.
417 (bus_activation_activate_service): shortcut the activation if we
418 already waiting for the same executable to start up.
420 2004-03-12 Mikael Hallendal <micke@imendio.com>
423 - Added service file reloading.
424 Each service files directory is kept in an hash table in
425 BusActivation and each BusActivationEntry knows what .service-file it
426 was read from. So when you try to activate a service the bus will
427 check if it's been updated, removed or if new .service-files has
429 - Test code at the bottom for the service file reloading.
430 * bus/test-main.c: (main):
432 - added service reloading test.
433 * dbus/dbus-sysdeps.c:
434 * dbus/dbus-sysdeps.h: (_dbus_delete_directory): Added.
436 2004-03-08 Michael Meeks <michael@ximian.com>
438 * dbus/dbus-connection.c (_dbus_connection_block_for_reply):
439 bail immediately if disconnected, to avoid busy loop.
441 * dbus/dbus-message.c (dbus_message_iter_get_args_valist):
442 cleanup cut/paste/inefficiency.
444 2004-03-01 David Zeuthen <david@fubar.dk>
446 * dbus/dbus-string.c (_dbus_string_append_printf_valist): Fix a
447 bug where args were used twice. This bug resulted in a segfault
448 on a Debian/PPC system when starting the messagebus daemon. Include
449 dbus-sysdeps.h for DBUS_VA_COPY
451 * dbus/dbus-sysdeps.h: Define DBUS_VA_COPY if neccessary. From GLib
453 * configure.in: Check for va_copy; define DBUS_VA_COPY to the
454 appropriate va_copy implementation. From GLib
456 2004-02-24 Joe Shaw <joe@ximian.com>
458 * bus/services.c (bus_registry_acquire_service): We need to pass
459 in the service name to dbus_set_error() to prevent a crash.
461 2003-12-26 Anders Carlsson <andersca@gnome.org>
463 * AUTHORS: Reveal my True identity.
465 2003-12-17 Mikael Hallendal <micke@imendio.com>
467 * dbus/dbus-message.c: (dbus_message_append_args_valist):
468 - Added case for DBUS_TYPE_BYTE, patch from Johan Hedberg.
470 2003-12-13 Mikael Hallendal <micke@imendio.com>
472 * doc/TODO: Added not about better error check of configuration files.
474 2003-12-02 Richard Hult <richard@imendio.com>
476 * Update AFL version to 2.0 throughout the source files to reflect
477 the update that was done a while ago.
479 2003-12-02 Richard Hult <richard@imendio.com>
481 * dbus/dbus-message.c (dbus_message_iter_append_dict): Set
482 wrote_dict_key to FALSE on the iter that the dict is appended to,
483 just like when appending other types. Fixes a bug where a dict
484 couldn't be put inside a dict.
485 (dbus_message_iter_append_dict_key): Fix typo in warning message.
486 (message_iter_test, _dbus_message_test): Add test case for dict
489 2003-12-01 David Zeuthen <david@fubar.dk>
491 * python/dbus.py: Add the actual message when calling the reciever
492 of a signal such that parameters can be inspected. Add the method
493 remove_signal_receiver
495 2003-11-26 Mikael Hallendal <micke@imendio.com>
499 * glib/*.[ch]: Made ref functions return the pointer
501 2003-11-25 Zack Rusin <zack@kde.org>
503 * qt/integrator.h, qt/integrator.cpp: Adding handling of DBusServer,
505 * qt/server.h, qt/server.cpp, qt/Makefile.am: Adding DBusServer
508 * qt/connection.h, qt/connection.cpp: Adjusting to changes in
509 the Integrator and to better fit with the server,
511 2003-11-24 Zack Rusin <zack@kde.org>
513 * qt/connection.h, qt/connection.cpp: removing initDbus method since
514 the integrator handles it now
516 * qt/integrator.h, qt/integrator.cpp: reworking handling of timeouts,
517 since QTimer wasn't really meant to be used the way DBusTimeout is
519 2003-11-24 Zack Rusin <zack@kde.org>
521 * qt/integrator.h, qt/integrator.cpp, Makefile.am: Adding
522 Integrator class which integrates D-BUS with the Qt event loop,
524 * qt/connection.h, qt/connection.cpp: Move all the code which
525 was dealing with D-BUS integration to the Integrator class,
526 and start using Integrator,
528 2003-11-23 Zack Rusin <zack@kde.org>
530 * qt/connection.h, qt/connection.cpp: Adding the DBusConnection
533 * qt/message.h, qt/message.cpp: updating to the current D-BUS api,
534 switching namespaces to DBusQt, reworking the class,
536 * Makefile.cvs: switching dependencies so that it matches KDE
539 * qt/Makefile.am: adding connection.{h,cpp} and message.{h,cpp} to
542 2003-11-19 Havoc Pennington <hp@redhat.com>
546 * configure.in: bump version to 0.20
548 * configure.in (have_qt): add yet another place to look for qt
549 (someone hand trolltech a .pc file...)
551 2003-11-01 Havoc Pennington <hp@redhat.com>
553 * doc/dbus-specification.xml: add state machine docs on the auth
554 protocol; just a first draft, I'm sure it's wrong.
556 2003-10-28 David Zeuthen <david@fubar.dk>
558 * python/dbus_bindings.pyx.in: add get_dict to handle dictionaries
559 return types. Fixup TYPE_* to reflect changes in dbus/dbus-protocol.h
561 2003-10-28 Havoc Pennington <hp@redhat.com>
563 * dbus/dbus-message.c (get_next_field): delete unused function
565 2003-10-28 Havoc Pennington <hp@redhat.com>
567 * bus/expirelist.c (do_expiration_with_current_time): detect
568 failure of the expire_func due to OOM
570 * bus/connection.c (bus_pending_reply_expired): return FALSE on OOM
572 * bus/dispatch.c (check_send_exit_to_service): fix to handle the
573 NoReply error that's now created by the bus when the service exits
575 2003-10-28 Havoc Pennington <hp@redhat.com>
577 * dbus/dbus-message.c (_dbus_message_test): enable and fix the
578 tests for set_path, set_interface, set_member, etc.
580 * dbus/dbus-string.c (_dbus_string_insert_bytes): allow 0 bytes
582 * dbus/dbus-message.c (set_string_field): always just delete and
583 re-append the field; accept NULL for deletion
584 (re_align_fields_recurse): reimplement
586 2003-10-26 Havoc Pennington <hp@redhat.com>
588 * dbus/dbus-connection.c: fix docs to properly describe the
590 (_dbus_connection_notify_disconnected): remove this function;
591 we can't synchronously add the disconnected message, we have to
592 do it after we've queued any remaining real messages
593 (_dbus_connection_get_dispatch_status_unlocked): queue the
594 disconnect message only if the transport has finished queueing all
595 its real messages and is disconnected.
596 (dbus_connection_disconnect): update the dispatch status here
598 2003-10-22 Havoc Pennington <hp@redhat.com>
600 * bus/bus.c (bus_context_check_security_policy): fix up assertion
602 * bus/connection.c (bus_transaction_send_from_driver): set the
603 destination to the connection's base service
605 2003-10-20 Havoc Pennington <hp@redhat.com>
607 hmm, make check is currently not passing.
609 * doc/dbus-specification.xml: add requirement that custom type
610 names follow the same rules as interface names.
612 * dbus/dbus-protocol.h: change some of the byte codes, to avoid
613 duplication and allow 'c' to be 'custom'; dict is now 'm' for
616 * doc/dbus-specification.xml: update type codes to match
617 dbus-protocol.h, using the ASCII byte values. Rename type NAMED to
618 CUSTOM. Add type OBJECT_PATH to the spec.
620 2003-10-17 Havoc Pennington <hp@redhat.com>
622 * bus/driver.c (create_unique_client_name): use "." as separator
623 in base service names instead of '-'
625 * dbus/dbus-string.c (_dbus_string_get_byte): allow getting nul
626 byte at the end of the string
628 * dbus/dbus-internals.h (_DBUS_LIKELY, _DBUS_UNLIKELY): add
629 optimization macros since string validation seems to be a slow
632 * doc/dbus-specification.xml: restrict valid
633 service/interface/member/error names. Add test suite code for the
636 * dbus/dbus-string.c: limit service/interface/member/error names
639 * dbus/dbus-connection.c (dbus_connection_dispatch): add missing
640 format arg to verbose spew
642 * glib/dbus-gproxy.c (dbus_gproxy_call_no_reply): if not out of
643 memory, return instead of g_error
645 * test/test-service.c (path_message_func): support emitting a
648 * dbus/dbus-bus.c (init_connections_unlocked): only fill in
649 activation bus type if DBUS_BUS_ACTIVATION was set; default to
650 assuming the activation bus was the session bus so that services
651 started manually will still register.
652 (init_connections_unlocked): fix so that in OOM situation we get
653 the same semantics when retrying the function
655 * test/test-service.c (main): change to use path registration, to
656 test those codepaths; register with DBUS_BUS_ACTIVATION rather
657 than DBUS_BUS_SESSION
659 2003-10-16 Havoc Pennington <hp@redhat.com>
661 * glib/dbus-gtest-main.c: bracket with #ifdef DBUS_BUILD_TESTS
663 * Makefile.am (GCOV_DIRS): remove "test", we don't care about test
664 coverage of the tests
665 (coverage-report.txt): don't move the .da and .bbg files around
667 2003-10-16 Havoc Pennington <hp@redhat.com>
669 * bus/bus.c (struct BusContext): remove struct field I didn't mean
672 2003-10-16 Havoc Pennington <hp@redhat.com>
674 * bus/connection.c (bus_pending_reply_expired): either cancel or
676 (bus_connections_check_reply): use unlink, not remove_link, as we
677 don't want to free the link; fixes double free mess
679 * dbus/dbus-pending-call.c (dbus_pending_call_block): fix in case
680 where no reply was received
682 * dbus/dbus-connection.c (_dbus_pending_call_complete_and_unlock):
685 * bus/signals.c (match_rule_matches): add special cases for the
686 bus driver, so you can match on sender/destination for it.
688 * dbus/dbus-sysdeps.c (_dbus_abort): print backtrace if
689 DBUS_PRINT_BACKTRACE is set
691 * dbus/dbus-internals.c: add pid to assertion failure messages
693 * dbus/dbus-connection.c: add message type code to the debug spew
695 * glib/dbus-gproxy.c (gproxy_get_match_rule): match rules want
696 sender=foo not service=foo
698 * dbus/dbus-bus.c (dbus_bus_get): if the activation bus is the
699 session bus but DBUS_SESSION_BUS_ADDRESS isn't set, use
700 DBUS_ACTIVATION_ADDRESS instead
702 * bus/activation.c: set DBUS_SESSION_BUS_ADDRESS,
703 DBUS_SYSTEM_BUS_ADDRESS if appropriate
705 * bus/bus.c (bus_context_new): handle OOM copying bus type into
708 * dbus/dbus-message.c (dbus_message_iter_get_object_path): new function
709 (dbus_message_iter_get_object_path_array): new function (half
710 finished, disabled for the moment)
712 * glib/dbus-gproxy.c (dbus_gproxy_end_call): properly handle
713 DBUS_MESSAGE_TYPE_ERROR
715 * tools/dbus-launch.c (babysit): support DBUS_DEBUG_OUTPUT to
716 avoid redirecting stderr to /dev/null
717 (babysit): close stdin if not doing the "exit_with_session" thing
719 * dbus/dbus-sysdeps.c (_dbus_become_daemon): delete some leftover
720 debug code; change DBUS_DEBUG_OUTPUT to only enable stderr, not
721 stdout/stdin, so things don't get confused
723 * bus/system.conf.in: fix to allow replies, I modified .conf
724 instead of .conf.in again.
726 2003-10-14 David Zeuthen <david@fubar.dk>
728 * python/dbus_bindings.pyx.in (MessageIter.get): fixed typo in
729 argtype to arg_type when raising unknown arg type exception.
730 Changed type list to reflect the changes in dbus-protocol.h so
731 the bindings actually work.
733 2003-10-14 Havoc Pennington <hp@redhat.com>
735 * test/decode-gcov.c: support gcc 3.3 also, though gcc 3.3 seems
736 to have a bug keeping it from outputting the .da files sometimes
737 (string_get_string): don't append garbage nul bytes to the string.
739 2003-10-15 Seth Nickell <seth@gnome.org>
741 * python/Makefile.am:
743 Include dbus_h_wrapper.h in the dist tarball.
745 2003-10-14 Havoc Pennington <hp@redhat.com>
747 * bus/bus.c (bus_context_check_security_policy): revamp this to
748 work more sanely with new policy-based requested reply setup
750 * bus/connection.c (bus_transaction_send_from_driver): set bus
751 driver messages as no reply
753 * bus/policy.c (bus_client_policy_check_can_receive): handle a
754 requested_reply attribute on allow/deny rules
756 * bus/system.conf: add <allow requested_reply="true"/>
758 * bus/driver.c (bus_driver_handle_message): fix check for replies
759 sent to the bus driver, which was backward. How did this ever work
760 at all though? I think I'm missing something.
762 * dbus/dbus-message.c (decode_header_data): require error and
763 method return messages to have a reply serial field to be valid
764 (_dbus_message_loader_queue_messages): break up this function;
765 validate that reply serial and plain serial are nonzero;
766 clean up the OOM/error handling.
767 (get_uint_field): don't return -1 from this
768 (dbus_message_create_header): fix signed/unsigned bug
770 * bus/connection.c (bus_connections_expect_reply): save serial of
771 the incoming message, not reply serial
773 2003-10-14 Havoc Pennington <hp@redhat.com>
775 * bus/connection.c: implement pending reply tracking using
778 * bus/bus.c (bus_context_check_security_policy): verify that a
779 reply is pending in order to allow a reply to be sent. Deny
780 messages of unknown type.
782 * bus/dbus-daemon-1.1.in: update to mention new resource limits
784 * bus/bus.c (bus_context_get_max_replies_per_connection): new
785 (bus_context_get_reply_timeout): new
787 2003-10-13 Seth Nickell <seth@gnome.org>
789 * python/Makefile.am:
791 Pass "make distcheck": remove a couple files from DIST_FILES
792 that weren't included in the final version.
794 2003-10-12 Havoc Pennington <hp@pobox.com>
796 Added test code that 1) starts an actual bus daemon and 2) uses
797 DBusGProxy; fixed bugs that were revealed by the test. Lots
798 more testing possible, but this is the basic framework.
800 * glib/dbus-gproxy.c (dbus_gproxy_manager_unregister): remove
801 empty proxy lists from the proxy list hash
803 * dbus/dbus-message.c (dbus_message_iter_get_args_valist): add a
804 couple of return_if_fail checks
806 * dbus/dbus-pending-call.c (_dbus_pending_call_new): use dbus_new0
807 to allocate, so everything is cleared to NULL as it should be.
809 * glib/dbus-gmain.c (dbus_connection_setup_with_g_main): pass
810 source as data to dbus_connection_set_timeout_functions() as the
811 timeout functions expected
813 * test/glib/run-test.sh: add a little script to start up a message
814 bus and run tests using it
816 * tools/dbus-launch.1: updates
818 * tools/dbus-launch.c (main): add --config-file option
820 * tools/dbus-launch.c (main): remove confusing else if (runprog)
821 that could never be reached.
823 * dbus/dbus-message.c (dbus_message_new_method_return)
824 (dbus_message_new_error, dbus_message_new_signal): set the
825 no-reply-expected flag on all these. Redundant, but may
826 as well be consistent.
828 2003-10-11 Havoc Pennington <hp@pobox.com>
830 * test/decode-gcov.c (function_solve_graph): make broken block
831 graph a nonfatal error since it seems to be broken. Need to debug
834 * dbus/dbus-marshal.c (_dbus_type_is_valid): new function since we
835 can't just check type > INVALID < LAST anymore
837 * dbus/dbus-message.c (dbus_message_get_signature): new function
838 (dbus_message_has_signature): new function
839 (struct DBusMessage): add signature field (right now it isn't sent
840 over the wire, just generated on the fly)
841 (dbus_message_copy): copy the signature, and init strings to
842 proper length to avoid some reallocs
843 (dbus_message_iter_init_array_iterator): return void, since it
845 (dbus_message_iter_init_dict_iterator): return void since it can't fail
846 (_dbus_message_loader_queue_messages): add silly temporary hack to
847 fill in message->signature on load
849 * dbus/dbus-protocol.h: change DBUS_TYPE_* values to be ASCII
850 characters, so they are relatively human-readable.
852 2003-10-11 Havoc Pennington <hp@pobox.com>
854 * dbus/dbus-message.c (_dbus_message_test): add more test
855 coverage, but #if 0 for now since they uncover a bug
856 not fixed yet; I think in re_align_field_recurse()
857 (re_align_field_recurse): add FIXME about broken assertion
859 * dbus/dbus-sysdeps.c (_dbus_sysdeps_test): add more test coverage
861 * bus/connection.c: share a couple code bits with expirelist.c
863 * bus/expirelist.h, bus/expirelist.c: implement a generic
864 expire-items-after-N-seconds facility, was going to share between
865 expiring connections and replies, decided not to use for expiring
868 * COPYING: include AFL 2.0 (still need to change all the file headers)
870 2003-10-09 Havoc Pennington <hp@redhat.com>
872 * configure.in: define DBUS_HAVE_GCC33_GCOV if we have
873 gcc 3.3. Not that we do anything about it yet.
875 * bus/signals.c (bus_match_rule_parse): impose max length on the
878 * dbus/dbus-protocol.h: add DBUS_MAXIMUM_MATCH_RULE_LENGTH
880 2003-10-09 Havoc Pennington <hp@redhat.com>
882 Make matching rules theoretically work (add parser).
884 * bus/bus.c (bus_context_check_security_policy): fix up to handle
885 the case where destination is explicitly specified as bus driver
886 and someone else is eavesdropping.
888 * bus/policy.c (bus_client_policy_check_can_receive): fix up
889 definition of eavesdropping and assertion
891 * tools/dbus-send.c (main): use dbus_message_type_from_string
893 * bus/signals.c (bus_match_rule_parse): implement
895 * dbus/dbus-message.c (dbus_message_type_from_string): new
897 * dbus/dbus-errors.h (DBUS_ERROR_MATCH_RULE_INVALID): add
899 2003-10-02 Havoc Pennington <hp@pobox.com>
901 * glib/dbus-gproxy.c (dbus_gproxy_call_no_reply): rename from
902 dbus_gproxy_oneway_call
904 * glib/dbus-gmain.c (dbus_connection_setup_with_g_main)
905 (dbus_server_setup_with_g_main): fix to allow calling them more
906 than once on the same args
907 (dbus_bus_get_with_g_main): new function
909 2003-10-02 Havoc Pennington <hp@redhat.com>
911 * doc/dbus-tutorial.xml: write some stuff
913 2003-09-29 Havoc Pennington <hp@pobox.com>
915 * configure.in: split checks for Doxygen from XML docs, check for
918 * doc/Makefile.am: XML-ify all the docs, and add a blank
921 2003-09-29 Havoc Pennington <hp@pobox.com>
923 * Merge dbus-object-names branch. To see the entire patch
924 do cvs diff -r DBUS_OBJECT_NAMES_BRANCHPOINT -r dbus-object-names,
926 To revert, I tagged DBUS_BEFORE_OBJECT_NAMES_MERGE.
928 2003-09-28 Havoc Pennington <hp@pobox.com>
930 * HACKING: update to reflect new server
932 2003-09-26 Seth Nickell <seth@gnome.org>
935 * python/examples/example-signals.py:
937 Start implementing some notions of signals. The API
938 is really terrible, but they sort of work (with the
939 exception of being able to filter by service, and to
940 transmit signals *as* a particular service). Need to
941 figure out how to make messages come from the service
944 * python/dbus_bindings.pyx.in:
946 Removed duplicate message_handler callbacks.
948 2003-09-25 Havoc Pennington <hp@redhat.com>
950 * bus/session.conf.in: fix my mess
952 2003-09-25 Havoc Pennington <hp@pobox.com>
954 * bus/session.conf.in: fix security policy, reported by Seth Nickell
956 2003-09-25 Seth Nickell <seth@gnome.org>
958 * python/examples/example-service.py:
960 Johan notices complete wrong code in example-service, but
961 completely wrong in a way that works exactly the same (!).
962 Johan is confused, how could this possibly work? Example
963 code fails to serve purpose of making things clear.
966 2003-09-25 Mark McLoughlin <mark@skynet.ie>
968 * doc/dbus-specification.sgml: don't require header fields
969 to be 4-byte aligned and specify that fields should be
970 distinguished from padding by the fact that zero is not
973 * doc/TODO: remove re-alignment item and add item to doc
974 the OBJECT_PATH type.
976 * dbus/dbus-message.c:
977 (HeaderField): rename the original member to value_offset
978 and introduce a name_offset member to keep track of where
979 the field actually begins.
980 (adjust_field_offsets): remove.
981 (append_int_field), (append_uint_field),
982 (append_string_field): don't align the start of the header
983 field to a 4-byte boundary.
984 (get_next_field): impl finding the next marhsalled field
986 (re_align_field_recurse): impl re-aligning a number of
987 already marshalled fields.
988 (delete_field): impl deleting a field of any type and
989 re-aligning any following fields.
990 (delete_int_or_uint_field), (delete_string_field): remove.
991 (set_int_field), (set_uint_field): no need to re-check
992 that we have the correct type for the field.
993 (set_string_field): ditto and impl re-aligning any
995 (decode_header_data): update to take into account that
996 the fields aren't 4-byte aligned any more and the new
997 way to distinguish padding from header fields. Also,
998 don't exit when there is too much header padding.
999 (process_test_subdir): print the directory.
1000 (_dbus_message_test): add test to make sure a following
1001 field is re-aligned correctly after field deletion.
1003 * dbus/dbus-string.[ch]:
1004 (_dbus_string_insert_bytes): rename from insert_byte and
1005 allow the insert of multiple bytes.
1006 (_dbus_string_test): test inserting multiple bytes.
1008 * dbus/dbus-marshal.c: (_dbus_marshal_set_string): add
1009 warning note to docs about having to re-align any
1010 marshalled values following the string.
1012 * dbus/dbus-message-builder.c:
1013 (append_string_field), (_dbus_message_data_load):
1014 don't align the header field.
1016 * dbus/dbus-auth.c: (process_test_subdir): print the
1019 * test/break-loader.c: (randomly_add_one_byte): upd. for
1022 * test/data/invalid-messages/bad-header-field-alignment.message:
1025 * test/data/valid-messages/unknown-header-field.message: shove
1026 a dict in the unknown field.
1028 2003-09-25 Seth Nickell <seth@gnome.org>
1031 * python/dbus_bindings.pyx.in:
1033 Handle return values.
1035 * python/examples/example-client.py:
1036 * python/examples/example-service.py:
1038 Pass back return values from the service to the client.
1040 2003-09-24 Seth Nickell <seth@gnome.org>
1044 Connect Object methods (when you are sharing an object) up... pass
1045 in a list of methods to be shared. Sharing all the methods just
1046 worked out too weird. You can now create nice Services over the
1049 * python/dbus_bindings.pyx.in:
1051 Keep references to user_data tuples passed into C functions so
1052 Python doesn't garbage collect on us.
1054 Implement MethodReturn and Error subclasses of Message for creating
1055 DBusMessage's of those types.
1057 * python/examples/example-client.py:
1058 * python/examples/example-service.py:
1060 Simple example code showing both how create DBus services and objects,
1061 and how to use them.
1063 2003-09-23 Havoc Pennington <hp@pobox.com>
1065 * glib/dbus-gproxy.c (dbus_gproxy_manager_filter): implement
1067 2003-09-23 Havoc Pennington <hp@redhat.com>
1069 * glib/dbus-gproxy.c (dbus_gproxy_connect_signal): implement
1070 (dbus_gproxy_disconnect_signal): implement
1071 (dbus_gproxy_manager_remove_signal_match): implement
1072 (dbus_gproxy_manager_add_signal_match): implement
1073 (dbus_gproxy_oneway_call): implement
1075 2003-09-23 Havoc Pennington <hp@pobox.com>
1077 * glib/dbus-gproxy.c (struct DBusGProxy): convert to a GObject
1078 subclass. This means dropping the transparent thread safety of the
1079 proxy; you now need a separate proxy per-thread, or your own
1080 locking on the proxy. Probably right anyway.
1081 (dbus_gproxy_ref, dbus_gproxy_unref): nuke, just use g_object_ref
1083 2003-09-22 Havoc Pennington <hp@redhat.com>
1085 * glib/dbus-gproxy.c (dbus_gproxy_manager_get): implement
1087 2003-09-21 Seth Nickell <seth@gnome.org>
1089 First checkin of the Python bindings.
1091 * python/.cvsignore:
1092 * python/Makefile.am:
1093 * python/dbus_bindings.pyx.in:
1094 * python/dbus_h_wrapper.h:
1096 Pieces for Pyrex to operate on, building a dbus_bindings.so
1097 python module for low-level access to the DBus APIs.
1101 High-level Python module for accessing DBus objects.
1106 Build stuff for the python bindings.
1110 Extra macro needed for finding the Python C header files.
1112 2003-09-21 Havoc Pennington <hp@pobox.com>
1114 * glib/dbus-gproxy.c (dbus_gproxy_manager_new): start
1115 implementing the proxy manager, didn't get very far.
1117 * dbus/dbus-bus.c (dbus_bus_add_match): new
1118 (dbus_bus_remove_match): new
1120 * glib/dbus-gproxy.c (dbus_gproxy_new_for_service): add a
1121 path_name argument; adjust the other not-yet-implemented
1122 gproxy constructors to be what I think they should be.
1124 2003-09-21 Havoc Pennington <hp@pobox.com>
1126 * dbus/dbus-bus.c (dbus_bus_get): set exit_on_disconnect to TRUE
1127 by default for message bus connections.
1129 * dbus/dbus-connection.c (dbus_connection_dispatch): exit if
1130 exit_on_disconnect flag is set and we process the disconnected
1132 (dbus_connection_set_exit_on_disconnect): new function
1134 2003-09-21 Havoc Pennington <hp@pobox.com>
1136 Get matching rules mostly working in the bus; only actually
1137 parsing the rule text remains. However, the client side of
1138 "signal connections" hasn't been started, this patch is only the
1141 * dbus/dispatch.c: fix for the matching rules changes
1143 * bus/driver.c (bus_driver_handle_remove_match)
1144 (bus_driver_handle_add_match): send an ack reply from these
1147 * glib/dbus-gproxy.c (dbus_gproxy_begin_call): fix order of
1148 arguments, reported by Seth Nickell
1150 * bus/config-parser.c (append_rule_from_element): support
1151 eavesdrop=true|false attribute on policies so match rules
1152 can be prevented from snooping on the system bus.
1154 * bus/dbus-daemon-1.1.in: consistently use terminology "sender"
1155 and "destination" in attribute names; fix some docs bugs;
1156 add eavesdrop=true|false attribute
1158 * bus/driver.c (bus_driver_handle_add_match)
1159 (bus_driver_handle_remove_match): handle AddMatch, RemoveMatch
1162 * dbus/dbus-protocol.h (DBUS_SERVICE_ORG_FREEDESKTOP_BROADCAST): get
1163 rid of broadcast service concept, signals are just always broadcast
1165 * bus/signals.c, bus/dispatch.c, bus/connection.c, bus/bus.c:
1166 mostly implement matching rules stuff (currently only exposed as signal
1169 2003-09-21 Mark McLoughlin <mark@skynet.ie>
1171 * doc/dbus-specification.sgml: Change the header field name
1172 to be an enum and update the rest of the spec to reference
1173 the fields using the conventinal name.
1175 * dbus/dbus-protocol.h: update to reflect the spec.
1177 * doc/TODO: add item to remove the 4 byte alignment requirement.
1179 * dbus/dbus-message.c: Remove the code to generalise the
1180 header/body length and serial number header fields as named
1181 header fields so we can reference field names using the
1183 (append_int_field), (append_uint_field), (append_string_field):
1184 Append the field name as a byte rather than four chars.
1185 (delete_int_or_uint_field), (delete_string_field): reflect the
1186 fact that the field name and typecode now occupy 4 bytes instead
1188 (decode_string_field), (decode_header_data): update to reflect
1189 protocol changes and move the field specific encoding from
1190 decode_string_field() back into decode_header_data().
1192 * dbus/dbus-internals.[ch]: (_dbus_header_field_to_string):
1193 Add utility to aid debugging.
1195 * dbus/dbus-message-builder.c:
1196 (append_string_field), (_dbus_message_data_load): Update to
1197 reflect protocol changes; Change the FIELD_NAME directive
1198 to HEADER_FIELD and allow it to take the field's conventional
1199 name rather than the actual value.
1201 * test/data/*/*.message: Update to use HEADER_FIELD instead
1202 of FIELD_NAME; Always align the header on an 8 byte boundary
1203 *before* updating the header length.
1205 2003-09-15 Havoc Pennington <hp@pobox.com>
1207 * dbus/dbus-pending-call.c: add the get/set object data
1208 boilerplate as for DBusConnection, etc. Use generic object data
1209 for the notify callback.
1211 * glib/dbus-gparser.c (parse_node): parse child nodes
1213 * tools/dbus-viewer.c: more hacking on the dbus-viewer
1215 * glib/dbus-gutils.c (_dbus_gutils_split_path): add a file to
1216 contain functions shared between the convenience lib and the
1219 * glib/Makefile.am (libdbus_glib_1_la_LDFLAGS): add
1220 -export-symbols-regex to the GLib library
1222 * dbus/dbus-object-tree.c (_dbus_object_tree_dispatch_and_unlock):
1223 fix the locking in here, and add a default handler for
1224 Introspect() that just returns sub-nodes.
1226 2003-09-14 Havoc Pennington <hp@pobox.com>
1228 * glib/dbus-gthread.c (dbus_g_thread_init): rename to make g_foo
1229 rather than gfoo consistent
1231 * glib/dbus-gproxy.h: delete for now, move contents to
1232 dbus-glib.h, because the include files don't work right since we
1233 aren't in the dbus/ subdir.
1235 * glib/dbus-gproxy.c (dbus_gproxy_send): finish implementing
1236 (dbus_gproxy_end_call): finish
1237 (dbus_gproxy_begin_call): finish
1239 * glib/dbus-gmain.c (dbus_set_g_error): new
1241 * glib/dbus-gobject.c (handle_introspect): include information
1242 about child nodes in the introspection
1244 * dbus/dbus-connection.c (dbus_connection_list_registered): new
1245 function to help in implementation of introspection
1247 * dbus/dbus-object-tree.c
1248 (_dbus_object_tree_list_registered_and_unlock): new function
1250 2003-09-12 Havoc Pennington <hp@pobox.com>
1252 * glib/dbus-gidl.h: add common base class for all the foo_info
1255 * tools/dbus-viewer.c: add GTK-based introspection UI thingy
1258 * test/Makefile.am: try test srcdir -ef . in addition to test
1259 srcdir = ., one of them should work (yeah lame)
1261 * glib/Makefile.am: build the "idl" parser stuff as a convenience
1264 * glib/dbus-gparser.h: make description_load routines return
1265 NodeInfo* not Parser*
1267 * Makefile.am (SUBDIRS): build test dir after all library dirs
1269 * configure.in: add GTK+ detection
1271 2003-09-07 Havoc Pennington <hp@pobox.com>
1273 * Make Doxygen contented.
1275 2003-09-07 Havoc Pennington <hp@pobox.com>
1277 * doc/dbus-specification.sgml: more updates
1279 2003-09-06 Havoc Pennington <hp@pobox.com>
1281 * doc/dbus-specification.sgml: partial updates
1283 * bus/dbus-daemon-1.1.in: fix the config file docs for the
1284 zillionth time; hopefully I edited the right file this time.
1286 * bus/config-parser.c (append_rule_from_element): support
1287 send_type, send_path, receive_type, receive_path
1289 * bus/policy.c: add message type and path to the list of things
1290 that can be "firewalled"
1292 2003-09-06 Havoc Pennington <hp@pobox.com>
1294 * dbus/dbus-connection.c (dbus_connection_register_fallback): add this
1295 (dbus_connection_register_object_path): make this not handle
1296 messages to paths below the given path
1298 2003-09-03 Havoc Pennington <hp@pobox.com>
1300 * test/glib/Makefile.am: add this with random glib-linked test
1303 * glib/Makefile.am: remove the random test programs from here,
1304 leave only the unit tests
1306 * glib/dbus-gobject.c (_dbus_gobject_test): add test for
1307 uscore/javacaps conversion, and fix
1308 (get_object_property, set_object_property): change to .NET
1309 convention for mapping props to methods, set_FooBar/get_FooBar,
1310 since one language has such a convention we may as well copy it.
1311 Plus real methods in either getFooBar or get_foo_bar style won't
1312 collide with this convention.
1314 2003-09-01 Havoc Pennington <hp@pobox.com>
1316 * glib/dbus-gparser.c: implement
1318 * glib/dbus-gobject.c: start implementing skeletons support
1320 * configure.in: when disabling checks/assert, also define
1321 G_DISABLE_ASSERT and G_DISABLE_CHECKS
1323 2003-09-01 Havoc Pennington <hp@pobox.com>
1325 * glib/Makefile.am: rearrange a bunch of files and get "make
1326 check" framework set up
1328 2003-08-31 Havoc Pennington <hp@pobox.com>
1330 * fix build with --disable-tests
1332 2003-08-30 Havoc Pennington <hp@pobox.com>
1334 * dbus/dbus-connection.c: purge DBusMessageHandler
1336 * dbus/dbus-message-handler.c: remove DBusMessageHandler, just
1337 use callbacks everywhere
1339 2003-08-30 Havoc Pennington <hp@pobox.com>
1341 * test/data/valid-config-files/system.d/test.conf: change to
1342 root for the user so warnings don't get printed
1344 * dbus/dbus-message.c: add dbus_message_get_path,
1345 dbus_message_set_path
1347 * dbus/dbus-object-tree.c (do_test_dispatch): add test of
1348 dispatching to a path
1350 * dbus/dbus-string.c (_dbus_string_validate_path): add
1352 * dbus/dbus-marshal.c (_dbus_demarshal_object_path): implement
1353 (_dbus_marshal_object_path): implement
1355 * dbus/dbus-protocol.h (DBUS_HEADER_FIELD_PATH): new header field
1356 to contain the path to the target object
1357 (DBUS_HEADER_FIELD_SENDER_SERVICE): rename
1358 DBUS_HEADER_FIELD_SENDER to explicitly say it's the sender service
1360 2003-08-30 Havoc Pennington <hp@pobox.com>
1362 * dbus/dbus-object-tree.c: write tests and fix the discovered bugs
1364 2003-08-29 Havoc Pennington <hp@pobox.com>
1366 * dbus/dbus-object-tree.c: modify to allow overlapping paths to be
1368 (struct DBusObjectSubtree): shrink this
1369 a lot, since we may have a lot of them
1370 (_dbus_object_tree_free_all_unlocked): implement
1371 (_dbus_object_tree_dispatch_and_unlock): implement
1373 2003-08-29 Havoc Pennington <hp@pobox.com>
1375 * dbus/dbus-internals.h: fix _DBUS_N_GLOBAL_LOCKS
1377 2003-08-28 Havoc Pennington <hp@pobox.com>
1381 * dbus/dbus-connection.c: port to no ObjectID, create a
1382 DBusObjectTree, rename ObjectTree to ObjectPath in public API
1384 * dbus/dbus-connection.h (struct DBusObjectTreeVTable): delete
1385 everything except UnregisterFunction and MessageFunction
1387 * dbus/dbus-marshal.c: port away from DBusObjectID,
1388 add DBUS_TYPE_OBJECT_PATH
1390 * dbus/dbus-object-registry.[hc], dbus/dbus-object.[hc],
1391 dbus/dbus-objectid.[hc]: remove these, we are moving to
1392 path-based object IDs
1394 2003-08-25 Havoc Pennington <hp@pobox.com>
1396 Just noticed that dbus_message_test is hosed, I wonder when I
1397 broke that. I thought make check was passing earlier...
1399 * dbus/dbus-object-tree.c: add new "object tree" to match DCOP
1400 container tree, will replace most of dbus-object-registry
1402 * dbus/dbus-string.c (_dbus_string_append_printf_valist): fix C99
1405 2003-08-19 Havoc Pennington <hp@pobox.com>
1407 * dbus/dbus-message.c (decode_string_field): support FIELD_SENDER
1408 (dbus_message_is_error): fix this function
1410 * bus/dbus-daemon-1.1: clarify logic on when <deny>/<allow> rules
1413 * bus/policy.c (bus_client_policy_check_can_receive): fix code to
1414 reflect clarified man page
1415 (bus_client_policy_check_can_send): ditto
1417 * bus/session.conf.in: fixup
1419 * bus/system.conf.in: fixup
1421 2003-08-18 Havoc Pennington <hp@redhat.com>
1423 * dbus/dbus-hash.c (_dbus_hash_table_insert_two_strings): fix
1425 * dbus/dbus-message.c (_dbus_message_loader_queue_messages): fix
1426 dumb bug created earlier (wrong order of args to
1427 decode_header_data())
1429 * tools/dbus-send.c: port
1431 * tools/dbus-print-message.c (print_message): port
1433 * test/data/*messages: port all messages over
1435 * dbus/dbus-message-builder.c: support including
1438 * bus/driver.c: port over
1440 * bus/dispatch.c: port over to new stuff
1442 * dbus/dbus-connection.c (_dbus_connection_new_for_transport):
1443 rename disconnect signal to "Disconnected"
1445 2003-08-17 Havoc Pennington <hp@pobox.com>
1447 This doesn't compile yet, but syncing up so I can hack on it from
1448 work. What are branches for if not broken code? ;-)
1450 * dbus/dbus-protocol.h: remove DBUS_HEADER_FIELD_NAME, add
1451 DBUS_HEADER_FIELD_INTERFACE, DBUS_HEADER_FIELD_MEMBER,
1452 DBUS_HEADER_FIELD_ERROR_NAME
1454 * dbus/dbus-hash.c: Introduce DBUS_HASH_TWO_STRINGS as hack to use
1455 for the interface+member pairs
1456 (string_hash): change to use g_str_hash algorithm
1457 (find_direct_function, find_string_function): refactor these to
1460 * dbus/dbus-message.c: port all of this over to support
1461 interface/member fields instead of name field
1463 * dbus/dbus-object-registry.c: port over
1465 * dbus/dbus-string.c (_dbus_string_validate_interface): rename
1466 from _dbus_string_validate_name
1468 * bus/dbus-daemon-1.1: change file format for the
1469 <deny>/<allow> stuff to match new message naming scheme
1471 * bus/policy.c: port over
1473 * bus/config-parser.c: parse new format
1475 2003-08-16 Havoc Pennington <hp@pobox.com>
1477 * dbus/dbus-object-registry.c (add_and_remove_objects): remove
1480 * glib/dbus-gproxy.c: some hacking
1482 2003-08-15 Havoc Pennington <hp@redhat.com>
1484 * dbus/dbus-pending-call.c (dbus_pending_call_block): implement
1486 * dbus/dbus-connection.c
1487 (dbus_connection_send_with_reply_and_block): factor out internals;
1488 change to convert any error replies to DBusError instead of
1489 returning them as a message
1491 2003-08-15 Havoc Pennington <hp@pobox.com>
1493 * dbus/dbus-connection.c,
1494 dbus/dbus-pending-call.c: Finish the pending call stuff
1496 2003-08-14 Havoc Pennington <hp@redhat.com>
1498 * dbus/dbus-pending-call.c: start on new object that will replace
1499 DBusMessageHandler and ReplyHandlerData for tracking outstanding
1502 * dbus/dbus-gproxy.c: start on proxy object used to communicate
1503 with remote interfaces
1505 * dbus/dbus-gidl.c: do the boring boilerplate in here
1507 2003-08-12 Havoc Pennington <hp@pobox.com>
1509 * bus/dispatch.c (bus_dispatch): make this return proper
1510 DBusHandlerResult to avoid DBUS_ERROR_UNKNOWN_METHOD
1512 * dbus/dbus-errors.c (dbus_set_error): use
1513 _dbus_string_append_printf_valist
1515 * dbus/dbus-string.c (_dbus_string_append_printf_valist)
1516 (_dbus_string_append_printf): new
1518 * dbus/dbus-errors.h (DBUS_ERROR_UNKNOWN_MESSAGE): change to
1521 * dbus/dbus-connection.c (dbus_connection_dispatch): handle
1522 DBUS_HANDLER_RESULT_NEED_MEMORY; send default error reply if a
1523 message is unhandled.
1525 2003-08-11 Havoc Pennington <hp@pobox.com>
1527 * bus/test.c (client_disconnect_handler): change to return
1528 HANDLED (would have been REMOVE_MESSAGE)
1530 * dbus/dbus-object.h (enum DBusHandlerResult): rename to
1531 HANDLED/NOT_YET_HANDLED instead of
1532 REMOVE_MESSAGE/ALLOW_MORE_HANDLERS to make it clearer how it
1535 2003-08-10 Havoc Pennington <hp@pobox.com>
1537 * tools/dbus-send.c (main): add --type argument, for now
1538 supporting only method_call and signal types.
1540 * tools/dbus-print-message.c: print message type
1542 * dbus/dbus-connection.c (_dbus_connection_new_for_transport):
1543 init connection->objects
1545 * doc/dbus-specification.sgml: fix sgml
1547 * bus/*.c: port over to object-instance API changes
1549 * test/test-service.c: ditto
1551 * dbus/dbus-message.c (dbus_message_create_header): allow #NULL
1552 name, we will have to fix up the rest of the code to also handle
1554 (dbus_message_new): generic message-creation call
1555 (set_string_field): allow appending name field
1557 2003-08-06 Havoc Pennington <hp@pobox.com>
1559 * dbus/dbus-object-registry.c: implement signal connection
1562 * dbus/dbus-connection.c (_dbus_connection_unref_unlocked): new
1564 * dbus/dbus-internals.c (_dbus_memdup): new function
1566 2003-08-02 Havoc Pennington <hp@pobox.com>
1568 * dbus/dbus-message.c (dbus_message_get_no_reply)
1569 (dbus_message_set_no_reply): add these and remove
1570 set_is_error/get_is_error
1572 * dbus/dbus-protocol.h, doc/dbus-specification.sgml:
1573 remove the ERROR flag, since there's now an ERROR type
1575 2003-08-01 Havoc Pennington <hp@pobox.com>
1577 * dbus/dbus-object-registry.c (_dbus_object_registry_handle_and_unlock):
1580 * dbus/dbus-message.c (dbus_message_get_type): new function
1582 * doc/dbus-specification.sgml: add "type" byte to messages
1584 2003-08-01 Havoc Pennington <hp@pobox.com>
1586 * dbus/dbus-protocol.h (DBUS_MESSAGE_TYPE_*): introduce
1587 a message type enum to distinguish kinds of message
1588 (DBUS_HEADER_FLAG_NO_REPLY_EXPECTED): flag for a message
1589 that need not be replied to
1591 2003-08-01 Havoc Pennington <hp@pobox.com>
1593 * dbus/dbus-marshal.c: adapt to DBusObjectID changes
1594 (unpack_8_octets): fix no-64-bit-int bug
1596 * dbus/dbus-object-registry.c (validate_id): validate the
1597 connection ID bits, not just the instance ID.
1599 * dbus/dbus-connection.c (_dbus_connection_init_id): initialize
1600 the connection-global 33 bits of the object ID
1602 * dbus/dbus-object-registry.c (info_from_entry): fill in
1603 object ID in the new way
1605 * dbus/dbus-objectid.h: rather than high/low bits, specifically
1606 define server/client/instance bits.
1608 2003-07-30 Havoc Pennington <hp@pobox.com>
1610 * dbus/dbus-connection.c (dbus_connection_register_object): fix
1613 2003-07-13 Havoc Pennington <hp@pobox.com>
1615 * dbus/dbus-object.h (struct DBusObjectVTable): add padding
1616 fields to DBusObjectVTable and DBusObjectInfo
1618 2003-07-12 Havoc Pennington <hp@pobox.com>
1620 * dbus/dbus-object-registry.c: implement unit test,
1621 fix bugs discovered in process
1623 * dbus/dbus-connection.c: remove handler_table and
1624 register_handler(), add DBusObjectRegistry usage
1626 * dbus/dbus-objectid.c (dbus_object_id_is_null)
1627 (dbus_object_id_set_null): new functions
1629 2003-07-08 Havoc Pennington <hp@pobox.com>
1631 * dbus/dbus-object.c: implement some of this
1633 * dbus/dbus-object-registry.c
1634 (_dbus_object_registry_add_and_unlock): fill in the object_id out
1636 (_dbus_object_registry_new): handle OOM
1638 2003-07-08 Havoc Pennington <hp@pobox.com>
1640 * dbus/dbus-object.h: sketch out an API for registering objects
1641 with a connection, that allows us to use as little as 24 bytes
1642 per object and lets application code represent an object in
1643 any conceivable way.
1645 * dbus/dbus-object-registry.c: implement the hard bits of the
1646 DBusConnection aspect of object API. Not yet wired up.
1648 2003-07-06 Havoc Pennington <hp@pobox.com>
1650 * dbus/dbus-marshal.c (_dbus_marshal_set_object_id): new function
1651 (_dbus_marshal_object_id): new
1652 (_dbus_demarshal_object_id): new
1653 (_dbus_marshal_get_arg_end_pos): support object ID type, and
1654 consolidate identical switch cases. Don't conditionalize handling
1655 of DBUS_TYPE_UINT64, need to handle the type always.
1656 (_dbus_marshal_validate_arg): consolidate identical cases, and
1657 handle DBUS_TYPE_OBJECT_ID
1659 * dbus/dbus-objectid.c: new file with DBusObjectID data type.
1661 * dbus/dbus-protocol.h: add DBUS_TYPE_OBJECT_ID
1663 2003-09-28 Havoc Pennington <hp@pobox.com>
1667 2003-09-28 Havoc Pennington <hp@pobox.com>
1669 * doc/Makefile.am (dbus-specification.html): testing a funky hack
1670 to work with Debian db2html
1672 2003-09-28 Havoc Pennington <hp@pobox.com>
1674 * configure.in: 0.13
1676 * doc/Makefile.am (dbus-test-plan.html): accept nonexistence of
1677 stylesheet-images for benefit of Debian
1679 Change back to using filesystem-linked sockets for the system
1680 bus, so only root can create the default system bus address.
1682 * bus/system.conf.in: change to use
1683 DBUS_SYSTEM_BUS_DEFAULT_ADDRESS
1685 * dbus/Makefile.am (INCLUDES): remove DBUS_SYSTEM_BUS_PATH define
1688 * configure.in: define DBUS_SYSTEM_BUS_DEFAULT_ADDRESS
1689 here, and AC_DEFINE DBUS_SYSTEM_PATH
1691 2003-08-09 Anders Carlsson <andersca@codefactory.se>
1694 * doc/busconfig.dtd:
1697 2003-08-09 Anders Carlsson <andersca@codefactory.se>
1699 * doc/dbus-specification.sgml:
1700 Add activation reply values.
1702 2003-08-05 Havoc Pennington <hp@redhat.com>
1704 * configure.in: 0.12
1706 2003-08-05 Anders Carlsson <andersca@codefactory.se>
1708 * glib/dbus-gmain.c: (watch_fd_new), (watch_fd_ref),
1709 (watch_fd_unref), (dbus_gsource_check), (dbus_gsource_dispatch),
1710 (add_watch), (remove_watch), (create_source):
1711 Refcount fds, fixes some reentrancy issues.
1713 2003-07-30 Havoc Pennington <hp@redhat.com>
1715 * dbus/dbus-bus.c (init_connections_unlocked): fix default system
1716 bus address to be abstract if we have abstract sockets
1720 2003-07-28 Havoc Pennington <hp@redhat.com>
1722 * bus/messagebus.in: fix to avoid processname/servicename
1723 confusion, from Michael Kearey
1724 https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=100965
1726 2003-07-23 Havoc Pennington <hp@pobox.com>
1728 * dbus/dbus-message.c (dbus_message_iter_get_named):
1729 fix from Andy Hanton to remove broken "+1"
1731 2003-07-16 Havoc Pennington <hp@pobox.com>
1733 * tools/dbus-launch.c (babysit): close stdout/stderr in the
1734 babysitter process, as suggested by Thomas Leonard, so
1735 an "eval `dbus-launch --exit-with-session`" will actually
1738 2003-07-16 Havoc Pennington <hp@pobox.com>
1740 * configure.in: print out EXPANDED_* variables in the summary at
1741 the end; clean up the code that computes EXPANDED_ variables and
1742 get the ones using exec_prefix right. Should make things work
1743 when you build without --prefix
1745 2003-06-29 Havoc Pennington <hp@pobox.com>
1747 * mono/Test.cs (class Test): fire up a main loop and run it
1749 * mono/DBus.cs (DBus): don't g_thread_init since it can only be
1750 done once, the app has to do it
1752 2003-06-26 Havoc Pennington <hp@pobox.com>
1754 * mono/Connection.cs: set up connection with the glib main loop
1756 2003-07-01 Havoc Pennington <hp@redhat.com>
1758 * doc/dbus-specification.sgml: clarify the format of a type code,
1759 change suggested by Jim Blandy
1761 2003-06-29 Miloslav Trmac <mitr@volny.cz>
1764 * tools/Makefile.am: Don't assume srcdir == builddir.
1766 * dbus/dbus-memory.c (dbus_realloc): Don't check guards after shrinking
1767 the allocated block.
1768 (_dbus_memory_test): New function.
1769 * dbus/dbus-test.h: Add _dbus_memory_test ().
1770 * dbus/dbus-test.c (dbus_internal_do_not_use_run_tests): Call it.
1772 * dbus/dbus-message.c (decode_header_data): Use %.4s instead
1774 (dbus_message_new): Remove obsolete @todo.
1776 * dbus/dbus-marshal.c (_dbus_marshal_set_int64)
1777 (_dbus_marshal_set_uint64): Fix comment.
1779 * dbus/dbus-message.c (append_int_field, append_uint_field): Don't
1780 hardcode FIELD_REPLY_SERIAL.
1782 * dbus/dbus-mainloop.c (_dbus_loop_remove_watch)
1783 (_dbus_loop_remove_timeout): Cast function pointers to (void *) for %p
1785 * configure.in: Add -D_POSIX_C_SOURCE=199309L -DBSD_SOURCE to CFLAGS
1786 and disable DBUS_USE_ATOMIC_INT_486 when --enable-ansi is used
1788 2003-06-24 Havoc Pennington <hp@pobox.com>
1790 * mono/*.cs: Use IntPtr.Zero instead of ((IntPtr) 0)
1792 2003-06-23 Anders Carlsson <andersca@codefactory.se>
1798 * gcj/TestMessage.java: (TestMessage), (TestMessage.main):
1799 * gcj/org/.cvsignore:
1800 * gcj/org/Makefile.am:
1801 * gcj/org/freedesktop/.cvsignore:
1802 * gcj/org/freedesktop/Makefile.am:
1803 * gcj/org/freedesktop/dbus/.cvsignore:
1804 * gcj/org/freedesktop/dbus/Makefile.am:
1805 * gcj/org/freedesktop/dbus/Message.java: (Message),
1807 * gcj/org/freedesktop/dbus/natMessage.cc:
1808 Fix the build system.
1810 2003-06-22 Havoc Pennington <hp@pobox.com>
1812 * mono/Connection.cs: add more bindings
1814 * dbus/dbus-threads.c (dbus_threads_init): allow calling this
1817 2003-06-22 Havoc Pennington <hp@pobox.com>
1819 * mono/Connection.cs, mono/DBus.cs, mono/Error.cs:
1820 Start wrapping more stuff.
1822 2003-06-22 Havoc Pennington <hp@pobox.com>
1824 * mono/Message.cs: implement Message.Wrap() that ensures we only
1825 have a single C# wrapper per DBusMessage, assuming it works which
1826 it probably doesn't.
1828 * dbus/dbus-message.c (dbus_message_allocate_data_slot): new
1829 (dbus_message_free_data_slot): new
1830 (dbus_message_set_data): new
1831 (dbus_message_get_data): new
1833 2003-06-22 Havoc Pennington <hp@pobox.com>
1835 * dbus/dbus-dataslot.c (_dbus_data_slot_allocator_unref)
1836 (_dbus_data_slot_allocator_alloc): rework these to keep a
1837 reference count on each slot and automatically manage a global
1838 slot ID variable passed in by address
1840 * bus/bus.c: convert to new dataslot API
1842 * dbus/dbus-bus.c: convert to new dataslot API
1844 * dbus/dbus-connection.c: convert to new dataslot API
1846 * dbus/dbus-server.c: convert to new dataslot API
1848 * glib/dbus-gmain.c: ditto
1852 * bus/connection.c: ditto
1854 2003-06-22 Anders Carlsson <andersca@codefactory.se>
1856 * configure.in: Add AM_PROG_GCJ and move AM_PROG_LIBTOOL
1857 after the gcj checks so that the correct configuration tags
1858 will be added to libtool.
1860 * dbus-glib-1.pc.in: No need to specify any includes since
1861 dbus-1.pc.in has those.
1863 2003-06-22 Havoc Pennington <hp@pobox.com>
1865 * mono/*, gcj/*, configure.in, Makefile.am:
1866 Check in makefiles and subdirs for mono and gcj bindings.
1867 Neither binding actually exists, just trying to get through
1868 all the build and other boring bits.
1870 2003-06-21 Philip Blundell <philb@gnu.org>
1872 * tools/dbus-monitor.1: Updated.
1874 * tools/dbus-send.1: Likewise.
1876 2003-06-20 Anders Carlsson <andersca@codefactory.se>
1878 * dbus/dbus-transport-unix.c (unix_handle_watch): Check
1879 for hangup and error after checking read so we won't discard
1880 pending data if both hangup and read are set.
1882 2003-06-19 Philip Blundell <philb@gnu.org>
1884 * tools/dbus-print-message.c (print_message): Handle BOOLEAN.
1886 * tools/dbus-send.c: Accept both --system and --session.
1888 * tools/dbus-monitor.c: Same here.
1890 2003-06-19 Anders Carlsson <andersca@codefactory.se>
1892 * glib/dbus-glib.h: Fix so that dbus-glib.h can be used
1893 from C++ (Patch by Miloslav Trmac).
1895 2003-06-15 Joe Shaw <joe@assbarn.com>
1897 * configure.in: Check for socklen_t.
1899 * dbus/dbus-sysdeps.c: Define socklen_t if it's not defined.
1901 * test/test-segfault.c: Add #include <sys/time.h>
1903 * tools/Makefile.am: Add DBUS_X_CFLAGS to the INCLUDES since
1904 dbus-launch needs it.
1906 2003-06-09 Havoc Pennington <hp@redhat.com>
1908 * dbus/dbus-sysdeps.c (_dbus_listen_unix_socket): don't use
1909 SUN_LEN, it breaks abstract socket usage
1911 * dbus/dbus-internals.c (_dbus_verbose_real): only print PID at
1914 2003-06-04 Havoc Pennington <hp@pobox.com>
1916 * dbus/dbus-server.c (dbus_server_listen): allow abstract sockets
1917 using unix:abstract=/foo, and when listening in a tmpdir
1918 i.e. unix:tmpdir=/tmp, always use abstract sockets if we can.
1920 * dbus/dbus-transport.c (_dbus_transport_open): support
1923 * dbus/dbus-server-unix.c (_dbus_server_new_for_domain_socket):
1924 support abstract sockets
1926 * dbus/dbus-transport-unix.c
1927 (_dbus_transport_new_for_domain_socket): support abstract sockets
1929 * dbus/dbus-sysdeps.c (_dbus_connect_unix_socket): add "abstract"
1930 toggle as an argument, implement abstract namespace support
1931 (_dbus_listen_unix_socket): ditto
1933 * configure.in: add --enable-abstract-sockets and implement
1934 a configure check for autodetection of the right value.
1936 2003-06-01 Havoc Pennington <hp@pobox.com>
1938 * tools/dbus-cleanup-sockets.c: add utility to clean up sockets
1939 in /tmp (though on Linux this will end up being useless,
1940 when we add abstract namespace support)
1942 * configure.in: define DBUS_SESSION_SOCKET_DIR in addition to
1945 2003-05-28 Colin Walters <walters@verbum.org>
1947 * tools/dbus-monitor.c (main): Fix silly typo (s/--session/--system/).
1949 2003-05-18 Anders Carlsson <andersca@codefactory.se>
1951 * dbus/dbus-message.c (dbus_message_new): Remove @todo.
1953 2003-05-17 Colin Walters <walters@gnu.org>
1955 * tools/dbus-send.c: Don't exit with an error code if --help was
1956 passed. Default to using the session bus instead of the system
1959 * tools/dbus-launch.c: Ditto.
1961 * tools/dbus-monitor.c: Ditto.
1963 * tools/dbus-send.1: Update with new arguments.
1965 * tools/dbus-launch.c: Emit code to export variables. New
1966 arguments -s and -c to specify shell syntax, and a bit of code to
1967 autodetect syntax. Also, allow specifying a program to run.
1969 * tools/dbus-launch.1: Update with new arguments.
1971 * tools/dbus-send.1: Ditto.
1973 * tools/dbus-monitor.1: Ditto.
1975 2003-05-17 Havoc Pennington <hp@pobox.com>
1977 * bus/config-parser.c (merge_included): merge in policies from
1978 child configuration file.
1980 * bus/policy.c (bus_policy_merge): function to merge two policies
1983 2003-05-16 Havoc Pennington <hp@redhat.com>
1985 * dbus/dbus-connection.c: disable verbose lock spew
1987 * tools/dbus-send.c: add --print-reply command line option
1989 * tools/dbus-print-message.h (print_message): new util function
1990 shared by dbus-send and dbus-monitor
1992 * tools/dbus-monitor.c (handler_func): exit on disconnect
1994 * dbus/dbus-transport-unix.c (do_reading): if the transport is
1995 disconnected, don't try to use the read_watch
1997 * dbus/dbus-watch.c (dbus_watch_get_enabled): assert watch != NULL
1998 so we can find this bug more easily
2000 2003-05-16 Havoc Pennington <hp@redhat.com>
2002 * bus/policy.c (free_rule_list_func): avoid a crash when passed
2003 NULL as DBusHashTable is annoyingly likely to do.
2005 2003-05-16 Colin Walters <walters@verbum.org>
2007 * tools/dbus-monitor.c: Add --session argument and usage()
2010 * tools/dbus-monitor.1: Update with new --session arg.
2012 * bus/Makefile.am (install-data-hook): Create
2013 $(libdir)/dbus-1.0/services so that the session bus is happy.
2015 2003-05-15 Havoc Pennington <hp@redhat.com>
2017 * dbus/dbus-sysdeps.c (_dbus_atomic_dec, _dbus_atomic_inc): work
2018 on non-x86. ifdef's are evil.
2020 2003-05-15 Havoc Pennington <hp@redhat.com>
2022 * configure.in: 0.11
2026 * bus/Makefile.am (initddir): apparently we are supposed to put
2027 init scripts in /etc/rc.d/init.d not /etc/init.d
2029 * bus/Makefile.am: remove the "you must --enable-tests to make
2030 check" as it broke distcheck
2032 * bus/Makefile.am (install-data-hook): create /etc/dbus-1/system.d
2034 2003-05-13 James Willcox <jwillcox@gnome.org>
2037 * bus/activation.c: (bus_activation_service_created),
2038 (bus_activation_activate_service):
2039 * bus/driver.c: (bus_driver_send_service_deleted),
2040 (bus_driver_send_service_created), (bus_driver_send_service_lost),
2041 (bus_driver_send_service_acquired),
2042 (bus_driver_send_welcome_message),
2043 (bus_driver_handle_list_services):
2044 * bus/session.conf.in:
2045 * dbus/dbus-bus.c: (dbus_bus_acquire_service),
2046 (dbus_bus_service_exists), (dbus_bus_activate_service):
2049 Add some convenience API which lets you activate a service, and did a
2050 bunch of s/0/DBUS_TYPE_INVALID/ in calls to dbus_message_append_args()
2051 and dbus_message_get_args()
2053 2003-05-11 Havoc Pennington <hp@pobox.com>
2055 * dbus/dbus-marshal.c (_dbus_marshal_validate_arg): fix to avoid
2056 calling _dbus_marshal_validate_arg() for every byte in a byte
2059 * dbus/dbus-message-handler.c: use atomic reference counting to
2060 reduce number of locks slightly; the global lock in here sucks
2062 * dbus/dbus-connection.c
2063 (_dbus_connection_update_dispatch_status_and_unlock): variant of
2064 update_dispatch_status that can be called with lock held; then use
2065 in a couple places to reduce locking/unlocking
2066 (dbus_connection_send): hold the lock over the whole function
2067 instead of acquiring it twice.
2069 * dbus/dbus-timeout.c (_dbus_timeout_new): handle OOM
2071 * bus/connection.c (bus_connections_setup_connection): fix access
2072 to already-freed memory.
2074 * dbus/dbus-connection.c: keep a little cache of linked list
2075 nodes, to avoid using the global linked list alloc lock in the
2076 normal send-message case. Instead we just use the connection lock
2077 that we already have to take.
2079 * dbus/dbus-list.c (_dbus_list_find_last): new function
2081 * dbus/dbus-sysdeps.c (_dbus_atomic_inc, _dbus_atomic_dec):
2082 change to use a struct for the atomic type; fix docs,
2083 they return value before increment, not after increment.
2085 * dbus/dbus-string.c (_dbus_string_append_4_aligned)
2086 (_dbus_string_append_8_aligned): new functions to try to
2087 microoptimize this operation.
2088 (reallocate_for_length): break this out of set_length(), to
2089 improve profile info, and also so we can consider inlining the
2092 * dbus/dbus-message.c (dbus_message_new_empty_header): init data
2093 strings with some preallocation, cuts down on our calls to realloc
2094 a fair bit. Though if we can get the "move entire string to empty
2095 string" optimization below to kick in here, it would be better.
2097 * dbus/dbus-string.c (_dbus_string_move): just call
2098 _dbus_string_move_len
2099 (_dbus_string_move_len): add a special case for moving
2100 an entire string into an empty string; we can just
2101 swap the string data instead of doing any reallocs.
2102 (_dbus_string_init_preallocated): new function
2104 2003-05-11 Havoc Pennington <hp@pobox.com>
2106 Write a "test-profile" that does echo client-server with threads;
2107 profile reveals lock contention, memcpy/realloc of buffers, and
2108 UTF-8 validation as hot spots. 20% of lock contention eliminated
2109 with dbus_atomic_inc/dec implementation on x86. Much remaining
2110 contention is global mempool locks for GList and DBusList.
2112 * dbus/dbus-sysdeps.c (_dbus_atomic_inc, _dbus_atomic_dec): add
2115 * dbus/dbus-connection.c (struct DBusConnection): use
2116 dbus_atomic_t for the reference count
2118 * dbus/dbus-message.c (struct DBusMessage): declare
2119 dbus_atomic_t values as volatile
2121 * configure.in: code to detect ability to use atomic integer
2122 operations in assembly, from GLib patch
2124 * dbus/dbus-internals.c (_dbus_verbose_real): call getpid every
2125 time, tired of it being wrong in threads and forked processes
2127 * glib/test-profile.c: a little program to bounce messages back
2128 and forth between threads and eat CPU
2130 * dbus/dbus-connection.c: add debug spew macros for debugging
2131 thread locks; include config.h at top; fix deadlock in
2132 dbus_connection_flush()
2134 2003-05-08 Havoc Pennington <hp@pobox.com>
2136 * dbus/dbus-spawn.c: s/_exit/exit/ because it was keeping gcov
2137 data from getting written, and there wasn't a good reason to
2140 * test/decode-gcov.c (mark_inside_dbus_build_tests): don't count
2141 dbus_verbose lines in test coverage
2142 (main): add list of functions sorted by # of untested blocks
2143 to the coverage report
2145 * dbus/dbus-mempool.c: put some test-only code in DBUS_BUILD_TESTS
2147 * dbus/dbus-marshal.c (_dbus_marshal_test): extend test coverage
2149 * dbus/dbus-message-handler.c (_dbus_message_handler_test):
2150 extend test coverage
2152 * test/data/auth/cancel.auth-script: test canceling an
2155 * dbus/Makefile.am: remove dbus-server-debug.[hc] for now, as they
2156 aren't used. in CVS history if we end up needing them.
2158 2003-05-04 Havoc Pennington <hp@pobox.com>
2160 * dbus/dbus-message-handler.c (_dbus_message_handler_test): add
2163 * dbus/dbus-marshal.c (_dbus_demarshal_string_array): fix this
2164 function, which assumed length was in # of strings, not bytes
2166 * dbus/dbus-message.c (_dbus_message_test): add tests for some
2169 * dbus/dbus-connection.c
2170 (_dbus_connection_queue_received_message): disable function for
2171 now, we are only using it in test mode
2173 * dbus/dbus-message.c (_dbus_message_loader_queue_messages):
2174 remove a mistaken FIXME
2176 2003-05-04 Havoc Pennington <hp@pobox.com>
2178 * dbus/dbus-connection.c (dbus_connection_preallocate_send):
2179 unlock mutex on successful return, patch from Anders Gustafsson
2181 2003-05-04 Havoc Pennington <hp@pobox.com>
2183 * dbus-glib-1.pc.in (Requires): fix dependencies, from
2186 2003-05-04 Havoc Pennington <hp@pobox.com>
2188 * tools/dbus-launch.c: implement
2190 * bus/main.c (main), bus/bus.c (bus_context_new):
2191 implement --print-pid and --fork
2193 2003-05-03 Havoc Pennington <hp@redhat.com>
2195 * dbus/dbus-address.c (dbus_parse_address): fix bug when a key in
2196 the address had no value, and add to test suite. Fix and
2197 regression test from Miloslav Trmac
2199 2003-05-03 Havoc Pennington <hp@pobox.com>
2201 * dbus/dbus-watch.c (dbus_watch_handle): warn and return if a
2202 watch is invalid when handled
2204 * tools/Makefile.am, tools/dbus-launch.c, tools/dbus-launch.1: add
2205 dbus-launch utility to launch the bus from a shell script. Didn't
2206 actually implement dbus-launch yet, it's just a placeholder still.
2208 2003-05-03 Havoc Pennington <hp@pobox.com>
2210 * bus/Makefile.am, bus/dbus-daemon-1.1.in: man page for the
2211 daemon; also documents daemon config file, so replaces
2212 doc/config-file.txt. Corrected some stuff from config-file.txt in
2213 the process of moving it.
2215 2003-05-03 Havoc Pennington <hp@pobox.com>
2217 * tools/Makefile.am, tools/dbus-send.1, tools/dbus-monitor.1:
2220 2003-05-03 Colin Walters <walters@verbum.org>
2222 * dbus/dbus-sysdeps.c (fill_user_info): Test against
2223 DBUS_UID_UNSET to determine whether to do a uid lookup or not.
2225 * Makefile.am: Update to use new .pc versioning scheme.
2227 2003-05-02 Havoc Pennington <hp@redhat.com>
2229 * bus/system.conf.in: allow send/receive to/from message bus
2232 2003-04-30 Havoc Pennington <hp@redhat.com>
2234 * configure.in: print a note when building with unit tests and
2237 2003-04-30 Havoc Pennington <hp@redhat.com>
2239 * Makefile.am: add a check-local that complains if you didn't
2240 configure with --enable-tests
2242 2003-04-29 Havoc Pennington <hp@redhat.com>
2244 * glib/dbus-gmain.c: docs cleanups
2246 * dbus/dbus-types.h: add docs on int64 types
2248 * dbus/dbus-memory.c: fix docs to avoid putting private API in
2249 public API docs section
2251 2003-04-29 Havoc Pennington <hp@redhat.com>
2253 * dbus-1.pc.in, dbus-glib-1.pc.in: rename these from
2254 dbus-1.0.pc.in, dbus-glib-1.0.pc.in. As these change with the
2255 parallel install API version, not with the D-BUS package version.
2257 * HACKING: move some of README over here
2259 * README: updates, and document API/ABI policy
2261 * configure.in: reindentation
2263 2003-04-29 Havoc Pennington <hp@redhat.com>
2265 * dbus/dbus.h: add "you have to define DBUS_API_SUBJECT_TO_CHANGE
2266 to use this library" to be sure people have the right
2269 2003-04-28 Havoc Pennington <hp@redhat.com>
2271 * configure.in: add --enable-docs which by default is auto yes if
2272 doxygen and db2html found, no otherwise; but can be forced on/off
2274 * doc/Makefile.am: conditionalize whether to build docs on
2277 2003-04-28 Havoc Pennington <hp@redhat.com>
2279 * configure.in: 0.10
2283 * bus/system.conf.in: add <includedir>system.d</includedir>
2285 * dbus/dbus-userdb.c (_dbus_user_database_lookup): fix bug when
2286 username was provided but not uid
2288 * bus/config-parser.c (struct BusConfigParser): keep track of
2289 whether the parser is toplevel or was included; change some
2290 of the error handling if it's included.
2292 2003-04-27 Havoc Pennington <hp@pobox.com>
2296 * dbus/dbus-transport.c (_dbus_transport_get_dispatch_status):
2297 report correct status if we finish processing authentication
2298 inside this function.
2300 * bus/activation.c (try_send_activation_failure): use
2301 bus_transaction_send_error_reply
2303 * bus/connection.c (bus_connection_get_groups): return an error
2304 explaining the problem
2306 * bus/bus.c (bus_context_check_security_policy): implement
2307 restriction here that inactive connections can only send the
2308 hello message. Also, allow bus driver to send anything to
2311 * bus/connection.c (bus_connection_complete): create the
2312 BusClientPolicy here instead of on-demand.
2313 (bus_connection_get_policy): don't return an error
2315 * dbus/dbus-message.c (dbus_message_new_error_reply): allow NULL
2316 sender field in message being replied to
2318 * bus/bus.c (bus_context_check_security_policy): fix silly typo
2319 causing it to return FALSE always
2321 * bus/policy.c (bus_client_policy_check_can_send): fix bug where
2322 we checked sender rather than destination
2324 2003-04-25 Havoc Pennington <hp@redhat.com>
2326 test suite is slightly hosed at the moment, will fix soon
2328 * bus/connection.c (bus_connections_expire_incomplete): fix to
2329 properly disable the timeout when required
2330 (bus_connection_set_name): check whether we can remove incomplete
2331 connections timeout after we complete each connection.
2333 * dbus/dbus-mainloop.c (check_timeout): fix this up a bit,
2334 probably still broken.
2336 * bus/services.c (bus_registry_acquire_service): implement max
2337 number of services owned, and honor allow/deny rules on which
2338 services a connection can own.
2340 * bus/connection.c (bus_connection_get_policy): report errors here
2342 * bus/activation.c: implement limit on number of pending
2345 2003-04-25 Havoc Pennington <hp@redhat.com>
2347 * dbus/dbus-transport.c (_dbus_transport_get_unix_user): fix bug
2348 where we used >= 0 instead of != DBUS_UID_UNSET.
2350 2003-04-25 Havoc Pennington <hp@redhat.com>
2352 * glib/dbus-gmain.c (remove_watch): fix for a crash when watches
2353 were toggled without add/remove, fix from Anders Gustafsson
2355 2003-04-24 Havoc Pennington <hp@redhat.com>
2357 * test/data/valid-config-files/basic.conf: add <limit> tags to
2360 * bus/config-parser.h, bus/config-parser.c, bus/bus.c: Implement
2361 <limit> tag in configuration file.
2363 2003-04-24 Havoc Pennington <hp@redhat.com>
2365 * bus/dispatch.c: somehow missed some name_is
2367 * dbus/dbus-timeout.c (_dbus_timeout_set_enabled)
2368 (_dbus_timeout_set_interval): new
2370 * bus/connection.c (bus_connections_setup_connection): record time
2371 when each connection is first set up, and expire them after the
2372 auth timeout passes.
2374 2003-04-24 Havoc Pennington <hp@redhat.com>
2376 * dbus/dbus-message.c (dbus_message_name_is): rename
2377 (dbus_message_service_is): rename
2378 (dbus_message_sender_is): rename
2379 (dbus_message_get_service): rename
2381 2003-04-24 Havoc Pennington <hp@redhat.com>
2383 * configure.in: add --enable-checks
2385 * dbus/dbus-message.c (dbus_message_new): reverse name/service arguments
2387 * dbus/dbus-connection.c (dbus_connection_preallocate_send): fix
2388 to use thread locks.
2389 (_dbus_connection_handler_destroyed_locked): move some private
2390 functions into proper docs group
2392 * dbus/dbus-internals.h: add _dbus_return_if_fail,
2393 _dbus_return_val_if_fail
2395 Throughout: use dbus_return_if_fail
2397 2003-04-23 James Willcox <jwillcox@gnome.org>
2400 * glib/dbus-gmain.c: (add_timeout), (wakeup_main), (create_source),
2401 (dbus_connection_setup_with_g_main),
2402 (dbus_server_setup_with_g_main):
2403 * glib/test-dbus-glib.c: (main):
2404 * glib/test-thread-client.c: (main):
2405 * glib/test-thread-server.c: (new_connection_callback), (main):
2406 * tools/dbus-monitor.c: (main):
2408 Added a GMainContext argument to dbus_connection_setup_with_g_main()
2409 and dbus_server_setup_with_g_main().
2411 2003-04-20 Havoc Pennington <hp@pobox.com>
2413 * doc/dbus-specification.sgml: document the restrictions on
2414 message and service names
2416 2003-04-22 Havoc Pennington <hp@redhat.com>
2418 * dbus/dbus-message.c, dbus/dbus-marshal.c: add 64-bit integer
2419 support, and do some code cleanups to share more code and
2420 speed up array marshal/demarshal.
2422 * dbus-1.0.pc.in (Cflags): put libdir include file in cflags
2424 * configure.in: generate dbus-arch-deps.h
2426 * dbus/dbus-protocol.h (DBUS_TYPE_INT64, DBUS_TYPE_UINT64): add
2429 2003-04-22 Havoc Pennington <hp@redhat.com>
2431 * test/data/valid-messages/opposite-endian.message: fix test
2432 to use proper type for rply field
2434 * test/data/invalid-messages: add tests for below validation
2436 * dbus/dbus-message.c (decode_header_data): validate field types,
2437 and validate that named fields are valid names
2438 (decode_name_field): consider messages in the
2439 org.freedesktop.Local. namespace to be invalid.
2441 * dbus/dbus-string.c (_dbus_string_validate_name): new
2443 2003-04-19 Havoc Pennington <hp@pobox.com>
2445 * bus/driver.c (bus_driver_handle_hello): check limits and
2446 return an error if they are exceeded.
2448 * bus/connection.c: maintain separate lists of active and inactive
2449 connections, and a count of each. Maintain count of completed
2450 connections per user. Implement code to check connection limits.
2452 * dbus/dbus-list.c (_dbus_list_unlink): export
2454 * bus/bus.c (bus_context_check_security_policy): enforce a maximum
2455 number of bytes in the message queue for a connection
2457 2003-04-18 Havoc Pennington <hp@pobox.com>
2459 * dbus/dbus-auth.c (record_mechanisms): memleak fixes
2461 * dbus/dbus-sysdeps.c (_dbus_string_save_to_file): fix some
2464 * dbus/dbus-keyring.c (add_new_key): fix a memleak, and
2465 on realloc be sure to update the pointer in the keyring
2467 * dbus/dbus-string.c (_dbus_string_zero): compensate for align
2468 offset to avoid writing to unallocated memory
2470 * dbus/dbus-auth.c (process_rejected): return FALSE if we fail to
2471 try the next mechanism, so we properly handle OOM
2473 * dbus/dbus-keyring.c (_dbus_keyring_new_homedir): fix double-free
2475 (_dbus_keyring_new): fix OOM bug
2476 (_dbus_keyring_new_homedir): always set error; impose a maximum
2477 number of keys we'll load from the file, mostly to speed up the
2478 test suite and make its OOM checks more useful, but also for
2481 * dbus/dbus-auth.c (process_error_server): reject authentication
2482 if we get an error from the client
2483 (process_cancel): on cancel, send REJECTED, per the spec
2484 (process_error_client): send CANCEL if we get an error from the
2487 2003-04-18 Havoc Pennington <hp@pobox.com>
2489 * dbus/dbus-mainloop.c (_dbus_loop_iterate): fix UMR in verbose
2492 * dbus/dbus-auth.c (handle_client_data_cookie_sha1_mech): fix OOM
2495 * dbus/dbus-keyring.c (_dbus_keyring_new_homedir): only whine
2496 about DBUS_TEST_HOMEDIR once
2498 * bus/Makefile.am (TESTS_ENVIRONMENT): put DBUS_TEST_HOMEDIR in
2501 * bus/dispatch.c (bus_dispatch_sha1_test): actually load sha1
2502 config file so we test the right thing
2504 Throughout: assorted docs improvements
2506 2003-04-18 Havoc Pennington <hp@pobox.com>
2508 * glib/dbus-gmain.c: adapt to watch changes
2510 * bus/bus.c, bus/activation.c, etc.: adjust to watch changes
2512 * dbus/dbus-server.h: remove dbus_server_handle_watch
2514 * dbus/dbus-connection.h: remove dbus_connection_handle_watch
2516 * dbus/dbus-watch.c (dbus_watch_handle): change DBusWatch to work
2517 like DBusTimeout, so we don't need dbus_connection_handle_watch
2520 2003-04-17 Havoc Pennington <hp@redhat.com>
2522 * dbus/dbus-userdb.c, dbus/dbus-sysdeps.c: redo all the passwd
2523 database usage so it all goes via the DBusUserDatabase cache.
2525 2003-04-17 Havoc Pennington <hp@redhat.com>
2527 * dbus/dbus-mainloop.c (_dbus_loop_iterate): fix logic so that if
2528 there was an OOM watch we skipped, we always return TRUE so we
2529 iterate again to have a look at it again. Fixes test suite hang.
2530 Code rearrangement also lets us lose some memset and only iterate
2531 over callbacks once.
2533 * bus/driver.c (bus_driver_handle_message): sense of test for
2536 2003-04-16 Havoc Pennington <hp@pobox.com>
2538 * doc/dbus-specification.sgml: make spec say serials are unsigned
2540 * dbus/dbus-message.h: change message serials to unsigned
2542 * dbus/dbus-connection.c: adapt to message serials being unsigned
2544 2003-04-15 Havoc Pennington <hp@pobox.com>
2546 * bus/bus.c: create and keep around a shared DBusUserDatabase
2549 * bus/connection.c (bus_connection_get_groups): don't cache
2550 groups for user in the connection object, since user database
2551 object now does that.
2553 2003-04-16 Havoc Pennington <hp@redhat.com>
2555 * dbus/dbus-message.c (_dbus_message_add_size_counter): keep a
2556 list of size counters
2557 (_dbus_message_loader_putback_message_link): put back a popped link
2559 * dbus/dbus-connection.c
2560 (dbus_connection_set_max_live_messages_size): rename
2562 (dbus_connection_get_outgoing_size): get size of outgoing
2564 (_dbus_connection_set_connection_counter): remove this cruft
2566 2003-04-14 Havoc Pennington <hp@redhat.com>
2568 * dbus/dbus-userdb.c: user database abstraction, mostly to get
2569 caching, but at some point we might want to be able to use a
2572 * bus/dispatch.c (bus_dispatch_sha1_test): add a test that uses
2573 SHA1 conf file to test the sha1 auth mechanism, since the regular
2574 test always uses EXTERNAL when available.
2577 test/data/valid-config-files/debug-allow-all-sha1.conf.in:
2578 add conf file that requires use of sha1 auth
2580 2003-04-13 Havoc Pennington <hp@pobox.com>
2582 * tools/dbus-send.c, tools/dbus-monitor.c: two utility programs
2583 from Philip Blundell to send messages and monitor them.
2585 2003-04-13 Havoc Pennington <hp@pobox.com>
2587 * dbus/dbus-mainloop.c: fix some reentrancy issues by refcounting
2590 * test/data/valid-config-files/debug-allow-all.conf.in: allow all
2593 * dbus/dbus-transport.c (_dbus_transport_get_dispatch_status):
2594 fix to only recover unused bytes if we're already authenticated
2595 (_dbus_transport_get_is_authenticated): fix to still mark us
2596 authenticated if there are unused bytes.
2598 * bus/dispatch.c: implement security policy checking
2600 * bus/connection.c (bus_transaction_send_from_driver): new
2602 * bus/bus.c (bus_context_check_security_policy): new
2604 * bus/dispatch.c (send_service_nonexistent_error): delete this,
2605 now we just set the DBusError and it gets converted to an error
2608 * bus/connection.c (allow_user_function): enable code using actual
2609 data from the config file
2611 * bus/policy.c (list_allows_user): handle wildcard rules for
2612 user/group connection perms
2614 2003-04-13 Havoc Pennington <hp@pobox.com>
2616 * bus/config-parser.c: Load up the BusPolicy and BusPolicyRules
2618 * dbus/dbus-sysdeps.c (_dbus_get_user_id): new function
2620 * bus/policy.c (bus_policy_append_mandatory_rule)
2621 (bus_policy_append_default_rule, bus_policy_append_user_rule)
2622 (bus_policy_append_group_rule): new functions
2624 2003-04-12 Havoc Pennington <hp@pobox.com>
2626 * bus/config-parser.c (bus_config_parser_new): fix a memleak
2628 * dbus/dbus-sysdeps.c: change DBusCredentials to use longs for
2629 the pid/gid/uid, just for paranoia.
2631 * test/break-loader.c (randomly_do_n_things): find a byte
2632 containing a type code, and randomly change it to a different
2635 2003-04-12 Havoc Pennington <hp@pobox.com>
2637 * bus/policy.h: change BusPolicy to be the thing from the config
2638 file, and rename old BusPolicy to BusClientPolicy
2640 * bus/bus.c, bus/connection.c, bus/config-parser.c: change to
2641 match change in how policy works
2643 * dbus/dbus-internals.h: mark assert_not_reached as
2644 __attribute((noreturn))__
2646 2003-04-11 Havoc Pennington <hp@redhat.com>
2648 * doc/dbus-specification.sgml: fix a spot with the wrong name for
2649 the broadcast service. Use boolean return for ServiceExists.
2651 2003-04-11 Havoc Pennington <hp@redhat.com>
2653 * configure.in: add another directory to look for qt in.
2655 2003-04-11 Havoc Pennington <hp@redhat.com>
2657 * AUTHORS: add Colin Walters
2659 2003-04-11 Havoc Pennington <hp@redhat.com>
2665 2003-04-11 Havoc Pennington <hp@redhat.com>
2667 * bus/messagebus.in: remove pid file when stopping the
2668 message bus, since the bus won't have privileges to remove it
2671 2003-04-11 Havoc Pennington <hp@redhat.com>
2673 * bus/bus.c (bus_context_new): move credentials change after
2676 2003-04-11 Havoc Pennington <hp@pobox.com>
2678 * test/decode-gcov.c: add "below average functions" to the
2679 coverage report, and change how some of the code works.
2681 * bus/test-main.c: bracket some stuff in DBUS_BUILD_TESTS so it's
2682 not in the coverage stats.
2684 * test/test-service.c (main): use _dbus_verbose not fprintf in a
2685 couple places so running the test suite doesn't result in megaspam.
2687 2003-04-11 Havoc Pennington <hp@pobox.com>
2689 * bus/dispatch.c (check_existent_service_activation): accept a no
2690 memory error in a place we didn't before
2692 * bus/test.c (bus_test_run_everything): remove hacky "do it twice
2693 in case the first one failed," since the test suite is less
2696 2003-04-10 Havoc Pennington <hp@pobox.com>
2698 * bus/dispatch.c (check_segfault_service_activation): add test
2699 for launching an executable that just crashes.
2701 * test/test-segfault.c (main): try setting coredumpsize to 0 so we
2702 don't leave a million cores. We'll see how portable this is.
2704 2003-04-10 Havoc Pennington <hp@pobox.com>
2706 * dbus/dbus-spawn.c (_dbus_spawn_async_with_babysitter): move all
2707 the possible parent failures before we fork, so that we don't
2708 fail to create a babysitter after creating the child.
2710 * bus/activation.c (bus_activation_activate_service): kill child
2711 if we don't successfully complete the activation.
2713 2003-04-10 Havoc Pennington <hp@redhat.com>
2715 * dbus/dbus-connection.c (dbus_connection_flush): don't spin on
2716 the connection if it's disconnected
2718 * bus/activation.c (bus_activation_service_created): use new
2719 transaction features to roll back removal of pending activation if
2720 we don't successfully create the service after all. Don't remove
2721 pending activation if the function fails.
2723 * dbus/dbus-list.c (_dbus_list_insert_before_link)
2724 (_dbus_list_insert_after_link): new code to facilitate
2727 * dbus/dbus-hash.c (_dbus_hash_table_insert_string_preallocated):
2728 new functionality, so we can preallocate the ability to insert
2731 * bus/connection.c (bus_transaction_add_cancel_hook): new function
2732 allowing us to put custom hooks in a transaction to be used for
2733 cancelling said transaction
2735 * doc/dbus-specification.sgml: add some discussion of secondary
2736 service owners, and disallow zero-length service names
2738 * bus/services.c (bus_registry_acquire_service): new function,
2739 splits out part of bus_driver_handle_acquire_service() and fixes
2740 a bug where we didn't remove the service doing the acquiring
2741 from the secondary queue if we failed to remove the current owner
2742 from the front of the queue.
2744 2003-04-10 Alexander Larsson <alexl@redhat.com>
2746 * doc/dbus-specification.sgml:
2747 s/org.freedesktop.Broadcast/org.freedesktop.DBus.Broadcast/
2749 2003-04-10 Alexander Larsson <alexl@redhat.com>
2754 Added files to cvsignore
2756 * dbus/dbus-message.h:
2757 * dbus/dbus-message.c: (dbus_message_iter_get_named):
2758 Make get_named() take two out argument and return a boolean.
2759 (dbus_message_iter_get_args_valist):
2760 Update usage of get_named().
2761 (dbus_message_iter_append_byte):
2763 (dbus_message_iter_append_named)
2765 (message_iter_test), (check_message_handling_type), (_dbus_message_test):
2768 2003-04-10 Alexander Larsson <alexl@redhat.com>
2770 * dbus/dbus-marshal.[ch]:
2771 Add array_type_pos argument to _dbus_marshal_validate_arg.
2772 Let you pass a NULL end_pos to _dbus_marshal_validate_type.
2774 * dbus/dbus-message.[ch]:
2775 Multi-dimensional arrays have full type specification in the
2776 outermost array. Iter code re-arranged to handle this.
2777 Added some more iter tests.
2779 * doc/dbus-specification.sgml:
2782 Update new array encoding description.
2783 Correct DBUS_SERVICE_FLAGS_REPLACE_EXISTING description.
2785 * test/data/invalid-messages/array-with-mixed-types.message:
2786 * test/data/valid-messages/array-of-array-of-uint32.message:
2787 Change to the new array format.
2789 * test/data/invalid-messages/too-short-dict.message:
2792 * test/data/valid-messages/recursive-types.message:
2793 Fix up and extend test.
2795 2003-04-10 Havoc Pennington <hp@pobox.com>
2797 * bus/dispatch.c: lots of fixes
2799 * dbus/dbus-mainloop.c (_dbus_loop_dispatch): export
2800 (_dbus_loop_iterate): remove old "quit if no callbacks" code,
2801 that was crack, broke the test service.
2803 * dbus/dbus-transport.c (_dbus_transport_open): fix error
2804 handling to avoid piling up errors if we get a failure on the
2807 * dbus/dbus-internals.c (_dbus_real_assert_not_reached): include
2808 pid in assertion failures.
2810 * dbus/dbus-mainloop.c (_dbus_loop_iterate): use static arrays up
2811 to some fixed size of file descriptor array. Don't return TRUE
2812 anytime a timeout exists, that led to lots of busy loop silliness
2815 2003-04-09 Havoc Pennington <hp@redhat.com>
2817 * dbus/dbus-mainloop.c (check_timeout): fix timeouts, I thought
2818 I'd checked this in earlier but hadn't.
2820 2003-04-09 Havoc Pennington <hp@redhat.com>
2822 * bus/dispatch.c (bus_dispatch_test): get a bit further through
2823 the activation test (man this is getting old!)
2825 2003-04-09 Havoc Pennington <hp@redhat.com>
2827 * test/test-utils.c: use dispatch status function to fix this up
2829 * bus/connection.c (connection_watch_callback): don't dispatch
2831 (connection_timeout_callback): don't dispatch from here
2832 (bus_connections_setup_connection): set the dispatch status function
2833 (bus_connection_disconnected): unset it
2835 * dbus/dbus-mainloop.c (_dbus_loop_queue_dispatch): new function
2836 used to add a connection to be dispatched
2837 (_dbus_loop_iterate): do the dispatching at the end of each
2840 * dbus/dbus-connection.c
2841 (dbus_connection_set_dispatch_status_function): new function
2842 allowing us to fix up main loop usage
2843 (_dbus_connection_last_unref): free all the various function
2845 (dbus_connection_dispatch): call the DispatchStatusFunction
2846 whenever this function returns
2847 (dbus_connection_handle_watch): call DispatchStatusFunction
2848 (dbus_connection_send_with_reply_and_block): call DispatchStatusFunction
2849 (reply_handler_timeout): call DispatchStatusFunction
2850 (dbus_connection_flush): call DispatchStatusFunction
2852 2003-04-09 Havoc Pennington <hp@redhat.com>
2854 * dbus/dbus-bus.c (dbus_bus_register): fix up error handling and
2857 * bus/dispatch.c (check_service_activated): fix bug in test
2859 * dbus/dbus-mainloop.c (check_timeout): fix this up
2861 * dbus/dbus-internals.c (_dbus_verbose_real): include PID in
2862 verbose output so we can sort out output from different processes,
2863 e.g. in the activation case.
2865 2003-04-08 Colin Walters <walters@gnu.org>
2867 * bus/bus.c (struct BusContext) [pidfile]: New member, to store
2869 (bus_context_new): Set it.
2870 (bus_context_unref): Use it to delete the pid file.
2872 2003-04-08 Havoc Pennington <hp@redhat.com>
2874 * test/data/invalid-messages/array-with-mixed-types.message:
2875 regression test that fails for the moment
2877 * dbus/dbus-test.c (dbus_internal_do_not_use_run_tests): reorder
2878 tests for convenience
2880 * dbus/dbus-marshal.c (_dbus_marshal_validate_arg): don't allow
2881 array of nil, it broke things.
2883 * test/data/invalid-messages/array-of-nil.message: regression test
2885 * test/data/valid-messages/array-of-array-of-uint32.message:
2886 happened to write this so added it to suite
2888 2003-04-08 Havoc Pennington <hp@redhat.com>
2890 * bus/driver.c (bus_driver_handle_acquire_service): init
2891 retval/reply before checking name
2893 * dbus/dbus-marshal.c (_dbus_marshal_validate_arg): add a
2894 recursion depth argument
2896 * dbus/dbus-message.h (struct DBusMessageIter): put some padding
2897 in the public struct for future extension
2899 * dbus/dbus-message-builder.c (_dbus_message_data_load): fix
2902 * dbus/dbus-marshal.c (_dbus_marshal_validate_arg): fix a verbose
2905 * doc/dbus-specification.sgml: fix typo
2907 2003-04-08 Alexander Larsson <alexl@redhat.com>
2909 Implemented recursive types, named types and new-style iters
2912 * glib/test-thread-client.c: (thread_func):
2913 * glib/test-thread-server.c: (handle_test_message):
2914 * test/test-service.c: (handle_echo):
2923 * dbus/dbus-internals.c: (_dbus_type_to_string):
2924 Update for new types.
2926 * dbus/dbus-marshal.[ch]:
2927 Implement recursive types and the new marshalling format.
2928 Remove hardcoded dict marshalling.
2929 Marshal named types.
2931 * dbus/dbus-message-builder.c:
2933 Remove references to old types
2935 * dbus/dbus-message.[ch]:
2936 New non-refcounted iter API that supports recursive iters.
2937 Use iters for appending, including support for recursive
2939 Add byte and named type support.
2940 Update everything to new marshalling formats.
2941 Add tests for new API.
2943 * dbus/dbus-protocol.h:
2944 Remove old array types.
2945 Add types: BYTE, ARRAY, DICT, NAMED
2947 * dbus/dbus-string.c:
2948 * dbus/dbus-sysdeps.c:
2949 Make parse_double locale safe.
2951 * dbus/dbus-test-main.c:
2957 * doc/dbus-specification.sgml:
2960 * test/data/incomplete-messages/missing-body.message:
2961 * test/data/invalid-messages/bad-boolean.message:
2962 * test/data/invalid-messages/bad-boolean-array.message:
2963 * test/data/invalid-messages/boolean-array-length-too-long.message-raw:
2964 * test/data/invalid-messages/boolean-has-no-value.message-raw:
2965 * test/data/invalid-messages/too-short-dict.message:
2966 * test/data/valid-messages/dict-simple.message:
2967 * test/data/valid-messages/dict.message:
2968 * test/data/valid-messages/emptiness.message:
2969 * test/data/valid-messages/lots-of-arguments.message:
2970 * test/data/valid-messages/no-padding.message:
2971 * test/data/valid-messages/recursive-types.message:
2972 Add missing NAME fields
2973 Fix up dicts & arrays
2975 * test/data/invalid-messages/dict-with-nil-value.message:
2976 Removed, this is not invalid anymore.
2978 * test/data/valid-messages/recursive-types.message:
2979 Add new test for deeply recursive types.
2981 2003-04-07 Havoc Pennington <hp@pobox.com>
2983 * bus/driver.c (bus_driver_handle_acquire_service): return an
2984 error if you try to acquire a service that starts with ':'
2986 2003-04-07 Havoc Pennington <hp@redhat.com>
2988 * doc/dbus-specification.sgml: require that base service names
2989 start with ':' and that the base service is created/deleted
2990 as first and last things a connection does on the bus
2992 * bus/dispatch.c (check_existent_service_activation): lots more
2993 work on the activation test; it doesn't fully pass yet...
2995 * test/test-service.c (main): fix so we don't memleak the
2996 connection to the message bus
2997 (filter_func): accept a message asking us to exit
2999 2003-04-06 Havoc Pennington <hp@pobox.com>
3001 * qt/Makefile.am (dbusinclude_HEADERS): install dbus-qt.h,
3004 * configure.in: fixes to Qt detection from Colin Walters
3006 * doc/Makefile.am: Only remove generated docbook dirs if they
3007 exist, from Colin Walters
3009 * dbus/dbus-bus.c: change how we set well-known connections to
3010 NULL, so that it works if a single connection is stored in
3011 two well-known array slots.
3013 * test/Makefile.am: remove a lot of stuff that isn't immediately
3014 useful, it's in CVS history if we want it.
3016 * test/test-service.c: use dbus-mainloop instead of that
3019 2003-04-06 Havoc Pennington <hp@pobox.com>
3021 * dbus/Makefile.am: split lists of sources into stuff that goes in
3022 the library, util functions that go in the lib and are also used
3023 elsewhere, and util functions that are used in tests/daemon but
3024 don't go in the lib.
3026 * dbus/dbus-mainloop.h, dbus/dbus-mainloop.c: move bus/loop.[hc]
3027 here so it can be used in test binaries also
3029 2003-04-06 Havoc Pennington <hp@pobox.com>
3031 * dbus/dbus-sysdeps.c (_dbus_become_daemon): write the pidfile
3032 here in the parent process, so we can return an error if it
3033 fails. Also, move some of the code into the child so the parent
3034 is less hosed if we fail midway through.
3036 * bus/bus.c (bus_context_new): move pidfile detection further up
3037 in the function, before we start overwriting sockets and such.
3039 * bus/messagebus.in: adjust this a bit, not sure if it will work.
3041 * configure.in: add --with-system-pid-file and --with-system-socket
3043 2003-04-06 Colin Walters <walters@verbum.org>
3045 * configure.in (DBUS_SYSTEM_PID_FILE): New variable.
3047 * bus/system.conf.in: Declare a pidfile.
3049 * bus/bus.c (bus_context_new): Test for an existing pid file, and
3050 create one (if appropriate).
3052 * bus/config-parser.c (enum ElementType) [ELEMENT_PIDFILE]: New.
3053 (struct BusConfigParser) [pidfile]: New.
3054 (element_type_to_name, merge_included, start_busconfig_child)
3055 (bus_config_parser_end_element, bus_config_parser_content): Handle it.
3056 (bus_config_parser_unref): Free it.
3057 (bus_config_parser_get_pidfile): New function.
3059 * bus/config-parser.h (_dbus_write_pid_file): Prototype.
3061 * dbus/dbus-errors.h (DBUS_ERROR_PIDFILE_EXISTS): New error.
3063 * dbus/dbus-sysdeps.c (_dbus_write_pid_file): New function.
3065 * dbus/dbus-sysdeps.h: Prototype it.
3067 2003-04-06 Havoc Pennington <hp@pobox.com>
3069 * bus/bus.c (bus_context_new): print the address in here, rather
3070 than in main(), because we need to do it before forking the daemon
3072 * bus/dispatch.c (send_service_nonexistent_error): set the sender
3073 on the service nonexistent error
3075 * bus/driver.c (bus_driver_handle_acquire_service): set the
3076 sender on the AcquireService reply
3078 * test/data/valid-config-files/debug-allow-all.conf.in: Make test
3079 server also listen on a UNIX socket so services can connect to it.
3081 2003-04-06 Havoc Pennington <hp@pobox.com>
3083 * dbus/dbus-threads.c: Redo how the fake debug mutexes are done
3084 so it detects deadlocks and also we actually init threads when
3087 2003-04-06 Havoc Pennington <hp@pobox.com>
3089 * dbus/dbus-server-unix.c (_dbus_server_new_for_domain_socket):
3090 save the domain socket name, and unlink it when we disconnect the
3091 server. Means that at least when we exit normally, we won't leave
3092 a bunch of junk in /tmp
3094 * dbus/dbus-transport-unix.c
3095 (_dbus_transport_new_for_domain_socket): code cleanup (nicer
3096 memory management). (I was making a real change here but then
3099 2003-04-06 Havoc Pennington <hp@pobox.com>
3101 * bus/bus.c (bus_context_new): fix wrong handling of
3102 server_data_slot_unref() in the error case.
3104 * dbus/dbus-internals.h (_dbus_assert): change so it passes
3105 "(condition) != 0" to _dbus_real_assert so that
3106 "_dbus_assert (pointer)" doesn't cause a warning
3108 * bus/main.c (main): accept --print-address option to print out
3109 the message bus address
3111 * dbus/dbus-sysdeps.c (_dbus_generate_random_ascii): export this
3113 * dbus/dbus-transport.c (_dbus_transport_open): special error for
3114 "tmpdir" option to unix: address on client side
3116 * dbus/dbus-server.c (dbus_server_listen): handle "tmpdir" option
3119 * configure.in (TEST_SOCKET_DIR): locate a temporary directory
3120 we can use to create sockets in the test suite.
3122 * bus/main.c (signal_handler): on SIGTERM, exit the daemon
3123 cleanly. To be used for testing.
3125 * dbus/dbus-spawn.c (babysit): use _dbus_set_signal_handler()
3127 * dbus/dbus-sysdeps.c (_dbus_set_signal_handler): new
3129 * dbus/dbus-server-debug-pipe.c (_dbus_transport_debug_pipe_new):
3130 handle trying to call this when there's no servers active
3132 2003-04-05 Havoc Pennington <hp@pobox.com>
3138 2003-04-05 Havoc Pennington <hp@pobox.com>
3140 * bus/bus.c (setup_server): fix this so dbus-daemon-1 doesn't
3141 crash on startup. Need to get "try starting the daemon"
3142 in the test suite I guess. ;-)
3144 * dbus/dbus-server.h, dbus/dbus-server.c: remove the stuff that
3145 tracked the number of open connections; it's better done in
3146 application-specific code as you want it to span all servers etc.
3148 2003-04-05 Havoc Pennington <hp@pobox.com>
3150 * bus/Makefile.am (install-data-hook): add missing DESTDIR,
3151 patch from Colin Walters
3153 2003-04-05 Havoc Pennington <hp@pobox.com>
3155 * doc/config-file.txt (Elements): fix docs of <auth> to reflect
3156 reality; in fact multiple mechanisms are allowed.
3158 * dbus/dbus-internals.c (_dbus_real_assert)
3159 (_dbus_real_assert_not_reached): move guts of _dbus_assert() and
3160 _dbus_assert_not_reached() into functions, so that they don't show
3161 up in basic block counts for test coverage, and don't use up as
3162 much disk space. Does mean slower execution speed though, so
3163 assumes --disable-asserts is the normal production case.
3165 2003-04-05 Havoc Pennington <hp@pobox.com>
3167 * test/Makefile.am (dist-hook): also dist *.in files
3173 2003-04-05 Havoc Pennington <hp@pobox.com>
3175 * dbus/dbus-string.c: docs warning
3177 * dbus/dbus-spawn.c: missing docs
3179 * dbus/dbus-memory.c (struct ShutdownClosure): missing docs
3181 2003-04-05 Havoc Pennington <hp@pobox.com>
3183 * bus/loop.c (bus_loop_iterate): fix the timeout code, using
3186 * dbus/dbus-spawn.c (_dbus_babysitter_unref): set sitter_pid
3187 to -1 once we've reaped the babysitter
3188 (_dbus_babysitter_handle_watch): do as much work as we can, not
3191 * bus/activation.c: add code using DBusBabysitter so that we
3192 handle it when a service fails to start up properly.
3193 (bus_activation_service_created): don't remove the activation
3194 entries as we go, just let them get removed when we free the pending
3195 activation. Unref reply messages after sending them.
3197 2003-04-05 Havoc Pennington <hp@pobox.com>
3199 * test/decode-gcov.c (main): print per-directory stats in the report
3201 * Makefile.am (coverage-report.txt): don't include test/* in gcov stats
3203 2003-04-05 Havoc Pennington <hp@pobox.com>
3205 * Makefile.am (coverage-report.txt): add target "coverage-report.txt"
3207 * test/decode-gcov.c: hack up a little program to suck data
3208 out of gcov files. Yes this is sort of silly.
3210 * configure.in: define something in config.h and do an
3211 AM_CONDITIONAL when gcov is enabled
3213 2003-04-04 Havoc Pennington <hp@redhat.com>
3215 * dbus/dbus-spawn.c, dbus/dbus-spawn.h: Change dbus_spawn to
3216 return a "babysitter" object that is used to monitor the status of
3217 the spawned process and reap it when required.
3219 * test/test-segfault.c, test/test-exit.c,
3220 test/test-sleep-forever.c: binaries that do various lame things,
3221 used in the test suite.
3223 * dbus/dbus-sysdeps.c: kill _dbus_errno_to_string()
3225 2003-04-03 Havoc Pennington <hp@pobox.com>
3227 * dbus/dbus-spawn.c: Move dbus-spawn into a separate file
3228 in preparation for modifying it, dbus-sysdeps is getting
3231 2003-04-03 Havoc Pennington <hp@redhat.com>
3233 * bus/loop.h, bus/loop.c: make the mainloop an object so we can
3236 * bus/*.[hc]: adapt to mainloop change
3238 2003-04-03 Havoc Pennington <hp@redhat.com>
3240 * bus/activation.c (load_directory): fix up memleaks
3241 (bus_activation_entry_free): free the entry
3243 * dbus/dbus-bus.c (dbus_bus_acquire_service): return an error if
3244 we get one from the message bus; fix memleaks.
3246 * dbus/dbus-message.c (dbus_set_error_from_message): new function
3248 2003-04-03 Havoc Pennington <hp@pobox.com>
3250 * bus/config-parser.c (bus_config_parser_unref): free
3251 list of mechanisms, bug discovered by test suite enhancements
3252 (putting system.conf and session.conf into suite)
3254 * test/Makefile.am, test/test-service.c: add placeholder for a
3255 test service that we'll activate as part of test suite. Doesn't
3258 * dbus/dbus-sysdeps.c (_dbus_setenv): support unsetenv by
3259 setting NULL value, and use system malloc not dbus_malloc()
3260 when we have unavoidable memleakage.
3262 * dbus/dbus-bus.c (dbus_bus_get): fix bug where bus type of 0
3263 didn't work, and support DBUS_BUS_ACTIVATION.
3265 * bus/activation.c (child_setup): pass our well-known bus type to
3268 * bus/config-parser.c: support <type> to specify well-known type
3270 * doc/dbus-specification.sgml: document the env variables to
3271 locate well-known buses and find service activator
3273 2003-04-02 Havoc Pennington <hp@redhat.com>
3275 * test/Makefile.am (all-local): add a rule to copy tests to
3276 builddir, so we can have generated tests. Use this to remove the
3277 silly hack for testing system.conf and session.conf. Will use this
3278 shortly to generate .service files pointing to test binaries.
3280 2003-04-02 Havoc Pennington <hp@redhat.com>
3282 * dbus/dbus-string.c (set_length): fix a bug - we allocated max of
3283 current alloc and needed new length, not max of the doubled
3284 allocation and needed new length. Also, when building tests,
3285 don't do the double-allocation stuff, just realloc every time.
3287 2003-04-02 Havoc Pennington <hp@redhat.com>
3289 * dbus/dbus-sysdeps.c (_dbus_file_get_contents): include filenames
3291 (_dbus_string_get_dirname): new
3292 (_dbus_sysdeps_test): new
3293 (_dbus_directory_open): include dirnames in error messages
3295 * bus/config-parser.c: interpret <include> and <includedir> and
3296 <servicedir> relative to config file location if the given
3297 filename is not absolute.
3299 * dbus/dbus-string.c (_dbus_string_find_byte_backward): new
3301 2003-04-02 Havoc Pennington <hp@redhat.com>
3303 * bus/connection.c (bus_transaction_send_error_reply): set sender
3304 service for the error, and unref the reply on success
3306 * bus/activation.c: convert to use BusTransaction so OOM can be
3308 (bus_activation_service_created): set sender of the message
3310 2003-04-01 Havoc Pennington <hp@redhat.com>
3312 * bus/config-parser.c, bus/bus.c: implement <servicedir> and
3313 <includedir> (at least mostly)
3315 * dbus/dbus-sysdeps.c (_dbus_change_identity): set the group ID
3316 first, then the user ID
3318 2003-04-01 Havoc Pennington <hp@pobox.com>
3320 * dbus/dbus-server.c (dbus_server_set_auth_mechanisms): new
3323 * dbus/dbus-auth.c (_dbus_auth_set_mechanisms): new
3325 * dbus/dbus-internals.c (_dbus_dup_string_array): new function
3327 * dbus/dbus-sysdeps.c (_dbus_listen_unix_socket): chmod the
3328 socket 0777, and unlink any existing socket.
3330 * bus/bus.c (bus_context_new): change our UID/GID and fork if
3331 the configuration file so specifies; set up auth mechanism
3334 * bus/config-parser.c (bus_config_parser_content): add support
3335 for <fork> option and fill in code for <auth>
3337 * bus/system.conf.in: add <fork/> to default configuration,
3338 and limit auth mechanisms to EXTERNAL
3340 * doc/config-file.txt (Elements): add <fork>
3342 * dbus/dbus-sysdeps.c (_dbus_become_daemon): new function
3343 (_dbus_change_identity): new function
3345 2003-03-31 Havoc Pennington <hp@redhat.com>
3347 * dbus/dbus-sysdeps.c (_dbus_connect_unix_socket)
3348 (_dbus_listen_unix_socket): fix off-by-one error in null
3349 termination spotted by Nalin
3351 2003-03-31 Havoc Pennington <hp@redhat.com>
3353 * dbus/dbus-keyring.c (_dbus_keyring_new_homedir): allow setting
3354 DBUS_TEST_HOMEDIR when tests are enabled, so we can test without
3355 having a real home directory available.
3357 2003-03-31 Havoc Pennington <hp@redhat.com>
3359 * bus/Makefile.am (install-data-hook): create /var/run/dbus
3361 * bus/messagebus.in: add init script for Red Hat /etc/init.d
3363 * configure.in: add support for specifying a style of init script
3366 2003-03-31 Havoc Pennington <hp@redhat.com>
3368 Fix some annoying DBusString API and fix all affected code.
3370 * dbus/dbus-string.c (_dbus_string_init): get rid of annoying
3372 (_dbus_string_get_data): change to return string instead of using
3374 (_dbus_string_get_const_data): ditto
3375 (_dbus_string_get_data_len): ditto
3376 (_dbus_string_get_const_data_len): ditto
3378 2003-03-31 Havoc Pennington <hp@redhat.com>
3380 * bus/main.c (main): fix up the command line arguments to be nicer
3382 2003-03-31 Havoc Pennington <hp@redhat.com>
3384 * dbus/Makefile.am (INCLUDES): use EXPANDED_LOCALSTATEDIR to
3385 define DBUS_SYSTEM_BUS_PATH as we want to compile in the same
3386 final location that lands in the config file
3388 * bus/config-loader-expat.c (bus_config_load): fix type of
3391 * doc/TODO: remove TODO item for dbus_bus_get()
3393 * dbus/dbus-bus.c (bus_data_free): add missing lock/unlock
3395 2003-03-31 Havoc Pennington <hp@pobox.com>
3397 * dbus/dbus-transport-unix.c (_dbus_transport_new_for_domain_socket)
3398 (_dbus_transport_new_for_tcp_socket): these didn't need the "server"
3399 argument since they are always client side
3401 * dbus/dbus-server.c (dbus_server_get_address): new function
3403 * bus/main.c (main): take the configuration file as an argument.
3405 * test/data/valid-config-files/debug-allow-all.conf: new file to
3406 use with dispatch.c tests for example
3408 * bus/test-main.c (main): require test data dir
3410 * bus/bus.c (bus_context_new): change this to take a
3411 configuration file name as argument
3413 * doc/config-file.txt (Elements): add <servicedir>
3415 * bus/system.conf, bus/session.conf: new files
3417 * dbus/dbus-bus.c (dbus_bus_get): look for system bus on
3418 well-known socket if none set
3420 * configure.in: create system.conf and session.conf
3422 2003-03-30 Havoc Pennington <hp@pobox.com>
3424 * bus/config-parser.c: hacking
3426 * dbus/dbus-memory.c: don't use DBusList for the list of stuff
3427 to shut down, since it could cause weirdness with the DBusList
3430 * dbus/dbus-list.c (_dbus_list_test): add tests for the
3431 link-oriented stack routines
3432 (alloc_link): free the mempool if the first alloc from it fails
3434 * dbus/dbus-mempool.c (struct DBusMemBlock): fix alignment issue
3436 * dbus/dbus-string.c (UNICODE_VALID): sync new version of this
3438 (_dbus_string_skip_white): new
3440 * doc/config-file.txt (Elements): add <includedir>
3442 2003-03-28 Havoc Pennington <hp@pobox.com>
3444 * dbus/dbus-string.c (_dbus_string_copy_data_len)
3445 (_dbus_string_copy_data): new functions
3447 2003-03-28 Anders Carlsson <andersca@codefactory.se>
3449 * dbus/dbus-bus.c: (bus_data_free), (dbus_bus_get):
3453 * dbus/dbus-memory.c:
3456 2003-03-28 Havoc Pennington <hp@pobox.com>
3458 * bus/test.c (bus_test_flush_bus): remove the sleep from here,
3459 I think it may have just been superstition. Not sure.
3461 * dbus/dbus-string.c (_dbus_string_base64_decode): catch some OOM
3462 failures that were not being handled.
3464 * dbus/dbus-auth.c (process_auth): fix a memleak in OOM handling
3466 * dbus/dbus-memory.c: add ability to set number of mallocs in a
3467 row that will fail on out-of-memory.
3469 * dbus/dbus-internals.c (_dbus_test_oom_handling): convenience
3470 function for testing out-of-memory handling.
3472 * bus/config-loader-expat.c (memsuite): don't wrap the dbus
3473 allocation functions, they do map exactly to the expat ones.
3475 2003-03-27 Havoc Pennington <hp@redhat.com>
3477 * bus/config-loader-libxml.c (bus_config_load): add another error
3480 2003-03-26 Anders Carlsson <andersca@codefactory.se>
3483 Add note about automatic service activation.
3485 * doc/dbus-specification.sgml:
3486 Rename the specification and clarify a few things.
3488 2003-03-26 Anders Carlsson <andersca@codefactory.se>
3491 * dbus/dbus-address.c:
3493 * dbus/dbus-marshal.c:
3494 * dbus/dbus-server-debug-pipe.c:
3495 * dbus/dbus-transport-unix.c:
3496 Fix documentation warnings.
3498 2003-03-26 Havoc Pennington <hp@pobox.com>
3500 * bus/test-main.c, dbus/dbus-test.c (main): check memleaks
3501 after every test so it's quick and easy to see which leaked, and
3502 so we test multiple dbus_shutdown() calls
3504 * configure.in: change configure.in XML stuff to also support
3507 * config-loader-libxml.c: some hacking
3509 * config-loader-expat.c: some hacking
3511 * config-parser.c: some hacking, plus tests
3513 2003-03-25 Havoc Pennington <hp@redhat.com>
3515 * throughout - add more _DBUS_ASSERT_ERROR_IS_CLEAR
3517 * configure.in: add --with-xml option to specify XML library,
3518 right now only libxml is supported.
3520 * bus/config-loader-libxml.c, config-parser.c: sync some minor
3521 nonworking code between home and work, still just stubs
3523 2003-03-24 Havoc Pennington <hp@redhat.com>
3525 * dbus/dbus-sysdeps.c (_dbus_set_fd_nonblocking): move to this
3528 * dbus/dbus-errors.c (dbus_set_error, dbus_set_error_const): allow
3529 NULL argument for "message" if the error is a well-known one,
3530 fill in a generic message in this case.
3532 * dbus/dbus-errors.h (DBusResultCode): Kill DBusResultCode in
3535 * bus/test.c (bus_test_flush_bus): add
3537 * bus/policy.c (bus_policy_test): test code stub
3539 2003-03-24 Havoc Pennington <hp@pobox.com>
3541 * bus/connection.c (bus_connections_setup_connection): set up
3542 the "can this user connect" function, but it always returns
3543 TRUE until we have a config file parser so we can have a config
3544 file that allows connections.
3546 2003-03-23 Havoc Pennington <hp@pobox.com>
3548 * dbus/dbus-threads.c (dbus_mutex_new, dbus_condvar_new): with
3549 DBUS_BUILD_TESTS, actually alloc/free a block of memory for
3550 the mutex, so we can check for proper memory management
3553 * dbus/dbus-dataslot.c: remove the mutex from
3554 DBusDataSlotAllocator and lock it manually when using it,
3555 to simplify fitting it into the global slots framework.
3557 * dbus/dbus-threads.c (init_static_locks): rework how we're
3558 handling global locks so they are easily shut down.
3560 * bus/policy.c (bus_policy_append_rule): fix
3562 * bus/test-main.c (main): check for memleaks
3564 * dbus/dbus-test.c (dbus_internal_do_not_use_run_tests): make
3565 test suite check for memleaks
3567 * dbus/dbus-memory.c: add support in test mode for tracking
3568 number of outstanding blocks
3570 2003-03-23 Havoc Pennington <hp@pobox.com>
3572 * bus/policy.c, bus/bus.c, bus/connection.c: implement allow/deny
3575 * dbus/dbus-hash.h: add ULONG hash keys
3577 * dbus/dbus-sysdeps.c (_dbus_get_groups): new
3578 (_dbus_get_group_id): new function
3580 2003-03-20 Havoc Pennington <hp@redhat.com>
3582 * dbus/dbus-connection.c (dbus_connection_set_unix_user_function):
3584 (dbus_connection_get_unix_user): new function
3586 2003-03-20 Havoc Pennington <hp@pobox.com>
3588 * bus/connection.c (bus_connection_send_oom_error): assert that
3589 message has a sender
3590 (connection_execute_transaction): ditto
3591 (bus_connection_preallocate_oom_error): fix to set the sender, and
3592 set recipient to the destination service, not the bus driver
3594 * bus/policy.c: hacking
3596 * dbus/dbus-message.c (dbus_message_service_is): new function
3597 (dbus_message_sender_is): new
3599 2003-03-19 Havoc Pennington <hp@redhat.com>
3601 * bus/policy.c: start sketching code for policy restrictions on
3602 what connections can do.
3604 2003-03-18 Havoc Pennington <hp@redhat.com>
3606 * doc/TODO: some notes on high-level todo items. Little nitpick
3607 stuff is all in @todo, so no need to add it here.
3609 * doc/config-file.txt: some notes on how config file might look
3611 2003-03-18 Anders Carlsson <andersca@codefactory.se>
3617 2003-03-17 Havoc Pennington <hp@redhat.com>
3619 * dbus/dbus-internals.h: add gcc attributes so that
3620 our printf-style functions warn on bad arguments to
3623 * dbus/dbus-sysdeps.c (_dbus_connect_tcp_socket): fix printf
3626 * dbus/dbus-message.c (_dbus_message_loader_queue_messages): fix
3629 2003-03-17 Havoc Pennington <hp@redhat.com>
3631 * bus/test-main.c (main): make it print something as it runs
3632 so make check doesn't look stuck
3634 * doc/negotiation.txt, doc/dbus-sasl-profile.txt: remove
3635 from CVS, now obsolete
3637 2003-03-17 Anders Carlsson <andersca@codefactory.se>
3639 * bus/dispatch.c: (bus_dispatch):
3640 Refetch the service name since it may have been reallocated
3641 when dbus_message_set_sender was called.
3643 * dbus/dbus-sysdeps.c: (_dbus_accept):
3644 Add address and address length variables and use them to stop
3645 valgrind from complaining.
3647 2003-03-17 Havoc Pennington <hp@pobox.com>
3649 All tests pass, no memleaks, no valgrind complaints.
3651 * bus/test.c: refcount handler_slot
3653 * bus/connection.c (bus_connections_new): refcount
3654 connection_data_slot
3656 * dbus/dbus-auth-script.c (_dbus_auth_script_run): delete unused
3657 bytes so that auth scripts pass.
3659 * bus/dispatch.c: init message_handler_slot so it gets allocated
3662 * bus/dispatch.c (message_handler_slot_ref): fix memleak
3664 * dbus/dbus-server-debug-pipe.c (_dbus_server_debug_pipe_new):
3665 dealloc server_pipe_hash when no longer used for benefit of
3668 * dbus/dbus-auth.c (process_command): memleak fix
3670 * bus/dispatch.c (check_hello_message): memleak fix
3672 2003-03-16 Havoc Pennington <hp@pobox.com>
3674 * dbus/dbus-bus.c (ensure_bus_data): fix double-unref of the data slot
3676 2003-03-17 Anders Carlsson <andersca@codefactory.se>
3678 * bus/activation.c (bus_activation_activate_service): Append
3679 the pending activation entry to the list of pending activations.
3681 2003-03-16 Havoc Pennington <hp@pobox.com>
3683 * bus/dispatch.c (bus_dispatch_test): remove double-unrefs of
3686 * dbus/dbus-address.c (create_entry): fix OOM handling when
3687 failing to alloc entry->method
3689 2003-03-16 Havoc Pennington <hp@pobox.com>
3691 * dbus/dbus-watch.c (_dbus_watch_new): handle failure to malloc
3694 * dbus/dbus-server-debug-pipe.c (_dbus_transport_debug_pipe_new):
3695 add some missing dbus_set_result
3697 * bus/dispatch.c (bus_dispatch_add_connection): handle failure to
3698 alloc the DBusMessageHandler
3700 * dbus/dbus-transport.c (_dbus_transport_disconnect): don't ref
3701 the transport here, since we call this from the finalizer; it
3702 resulted in a double-finalize.
3704 * dbus/dbus-transport.c (_dbus_transport_disconnect): fix a bug
3705 where we tried to use transport->connection that was NULL,
3706 happened when transport was disconnected early on due to OOM
3708 * bus/*.c: adapt to handle OOM for watches/timeouts
3710 * dbus/dbus-transport-unix.c: port to handle OOM during
3713 * dbus/dbus-auth.c (_dbus_auth_get_unused_bytes): return a
3714 reference to unused bytes instead of a copy
3716 * dbus/dbus-server.c (dbus_server_handle_watch): return FALSE for
3719 * dbus/dbus-connection.c (dbus_connection_handle_watch): return
3722 * dbus/dbus-timeout.c (dbus_timeout_handle): return FALSE for out
3725 2003-03-16 Anders Carlsson <andersca@codefactory.se>
3727 * doc/dbus-specification.sgml:
3728 Document reply message for ActivateService.
3730 2003-03-16 Anders Carlsson <andersca@codefactory.se>
3732 * bus/activation.c: (bus_pending_activation_entry_free),
3733 (bus_pending_activation_free), (bus_activation_new),
3734 (bus_activation_unref), (bus_activation_service_created),
3735 (bus_activation_activate_service):
3737 * bus/bus.c: (bus_context_new):
3738 * bus/desktop-file.c: (new_section):
3739 * bus/driver.c: (bus_driver_send_service_deleted),
3740 (bus_driver_handle_activate_service):
3741 * bus/services.c: (bus_registry_new), (bus_registry_ensure):
3743 * dbus/dbus-connection.c:
3744 (dbus_connection_send_with_reply_and_block):
3745 * dbus/dbus-message.c: (dbus_message_append_args_valist):
3746 * dbus/dbus-protocol.h:
3747 Make activation work better. Now pending activations will be queued
3748 and the daemon won't try to activate services that are already registered.
3750 2003-03-16 Havoc Pennington <hp@pobox.com>
3752 * dbus/dbus-bus.c (ensure_bus_data): handle failure to set
3755 * dbus/dbus-memory.c (_dbus_initialize_malloc_debug): support
3756 DBUS_MALLOC_BACKTRACES to print trace when failing an alloc
3758 2003-03-16 Havoc Pennington <hp@pobox.com>
3760 * dbus/dbus-string.c (_dbus_string_validate_utf8): oops, unbreak
3761 this. always run the test suite before commit...
3763 * bus/*: adapt to DBusConnection API changes
3765 * glib/dbus-gmain.c: adapt to DBusConnection API changes,
3766 requires renaming stuff to avoid dbus_connection_dispatch name
3769 * dbus/dbus-transport.c (_dbus_transport_queue_messages): new
3772 * dbus/dbus-message.c (_dbus_message_loader_queue_messages):
3773 separate from _dbus_message_loader_return_buffer()
3775 * dbus/dbus-connection.c (dbus_connection_get_n_messages): remove
3776 this, because it's now always broken to use; the number of
3777 messages in queue vs. the number still buffered by the message
3778 loader is undefined/meaningless. Should use
3779 dbus_connection_get_dispatch_state().
3780 (dbus_connection_dispatch): rename from
3781 dbus_connection_dispatch_message
3783 2003-03-16 Havoc Pennington <hp@pobox.com>
3785 * dbus/dbus-string.c (_dbus_string_validate_utf8): copy in a real
3788 2003-03-16 Anders Carlsson <andersca@codefactory.se>
3790 * dbus/dbus-connection.c:
3791 (dbus_connection_send_with_reply_and_block):
3792 Decrease connection->n_incoming when removing an entry
3794 * dbus/dbus-dict.c: (dbus_dict_entry_free),
3795 (dbus_dict_set_boolean_array), (dbus_dict_set_int32_array),
3796 (dbus_dict_set_uint32_array), (dbus_dict_set_double_array),
3797 (dbus_dict_set_byte_array), (dbus_dict_set_string_array),
3798 (dbus_dict_get_boolean_array), (dbus_dict_get_double_array),
3799 (dbus_dict_get_byte_array):
3800 Handle NULL arrays and strings. Also add support for byte arrays.
3802 * dbus/dbus-marshal.c: (_dbus_marshal_byte_array),
3803 (_dbus_marshal_dict), (_dbus_demarshal_byte_array),
3804 (_dbus_demarshal_int32_array), (_dbus_demarshal_uint32_array),
3805 (_dbus_demarshal_double_array), (_dbus_demarshal_string_array),
3806 (_dbus_demarshal_dict), (demarshal_and_validate_len),
3807 (_dbus_marshal_validate_arg), (_dbus_marshal_test):
3808 * dbus/dbus-marshal.h:
3809 Add support for marshalling and demarshalling empty arrays and strings.
3811 * dbus/dbus-message.c: (dbus_message_append_args_valist),
3812 (dbus_message_append_string_array),
3813 (dbus_message_iter_get_boolean),
3814 (dbus_message_iter_get_boolean_array),
3815 (dbus_message_iter_get_int32_array),
3816 (dbus_message_iter_get_uint32_array),
3817 (dbus_message_iter_get_double_array),
3818 (dbus_message_iter_get_byte_array),
3819 (dbus_message_iter_get_string_array), (dbus_message_iter_get_dict),
3820 (check_message_handling):
3821 Add support for getting empty arrays and dicts.
3823 * dbus/dbus-string.c: (_dbus_string_validate_utf8):
3824 Don't do any validation at all for now, that's better than just checking
3827 * test/data/valid-messages/emptiness.message:
3828 New test message with lots of empty arrays.
3830 2003-03-16 Havoc Pennington <hp@pobox.com>
3832 * dbus/dbus-connection.c
3833 (_dbus_connection_queue_received_message_link): new function that
3834 can't fail due to OOM
3836 * dbus/dbus-message.c (_dbus_message_loader_pop_message_link):
3837 new function pops a message together with a list link
3840 * dbus/dbus-transport-unix.c (queue_messages): use new link-based
3841 message queuing functions to avoid needing to alloc memory
3843 2003-03-16 Havoc Pennington <hp@pobox.com>
3845 Oops - test code was only testing failure of around 30 of the
3846 mallocs in the test path, but it turns out there are 500+
3847 mallocs. I believe this was due to misguided linking setup such
3848 that there was one copy of dbus_malloc etc. in the daemon and one
3849 in the shared lib, and only daemon mallocs were tested. In any
3850 case, the test case now tests all 500+ mallocs, and doesn't pass
3851 yet, though there are lots of fixes in this patch.
3853 * dbus/dbus-connection.c (dbus_connection_dispatch_message): fix
3854 this so that it doesn't need to allocate memory, since it
3855 has no way of indicating failure due to OOM (and would be
3856 annoying if it did).
3858 * dbus/dbus-list.c (_dbus_list_pop_first_link): new function
3860 * bus/Makefile.am: rearrange to create two self-contained
3861 libraries, to avoid having libraries with overlapping symbols.
3862 that was resulting in weirdness, e.g. I'm pretty sure there
3863 were two copies of global static variables.
3865 * dbus/dbus-internals.c: move the malloc debug stuff to
3868 * dbus/dbus-list.c (free_link): free list mempool if it becomes
3871 * dbus/dbus-memory.c (_dbus_disable_mem_pools): new function
3873 * dbus/dbus-address.c (dbus_parse_address): free list nodes
3876 * bus/dispatch.c (bus_dispatch_add_connection): free
3877 message_handler_slot when no longer using it, so
3878 memory leak checkers are happy for the test suite.
3880 * dbus/dbus-server-debug-pipe.c (debug_finalize): free server name
3882 * bus/bus.c (new_connection_callback): disconnect in here if
3883 bus_connections_setup_connection fails.
3885 * bus/connection.c (bus_connections_unref): fix to free the
3887 (bus_connections_setup_connection): if this fails, don't
3888 disconnect the connection, just be sure there are no side
3891 * dbus/dbus-string.c (undo_alignment): unbreak this
3893 * dbus/dbus-auth.c (_dbus_auth_unref): free some stuff we were
3895 (_dbus_auth_new): fix the order in which we free strings
3898 * bus/connection.c (bus_connection_disconnected): fix to
3899 not send ServiceDeleted multiple times in case of memory
3902 * dbus/dbus-bus.c (dbus_bus_get_base_service): new function to
3903 get the base service name
3904 (dbus_bus_register_client): don't return base service name,
3905 instead store it on the DBusConnection and have an accessor
3907 (dbus_bus_register_client): rename dbus_bus_register()
3909 * bus/dispatch.c (check_hello_message): verify that other
3910 connections on the bus also got the correct results, not
3911 just the one sending hello
3913 2003-03-15 Havoc Pennington <hp@pobox.com>
3915 Make it pass the Hello handling test including all OOM codepaths.
3916 Now to do other messages...
3918 * bus/services.c (bus_service_remove_owner): fix crash when
3919 removing owner from an empty list of owners
3920 (bus_registry_ensure): don't leave service in the list of
3921 a connection's owned services if we fail to put the service
3924 * bus/connection.c (bus_connection_preallocate_oom_error): set
3925 error flag on the OOM error.
3927 * dbus/dbus-connection.c (_dbus_connection_new_for_transport):
3928 handle _dbus_transport_set_connection failure
3930 * dbus/dbus-transport-unix.c (_dbus_transport_new_for_fd): modify
3931 to create watches up front and simply enable/disable them as
3933 (unix_connection_set): this can now fail on OOM
3935 * dbus/dbus-timeout.c, dbus/dbus-watch.c: add concept
3936 of enabling/disabling a watch or timeout.
3938 * bus/loop.c (bus_loop_iterate): don't touch disabled
3941 * glib/dbus-gmain.c: adapt to enable/disable watches and timeouts
3943 2003-03-15 Havoc Pennington <hp@pobox.com>
3945 * bus/dispatch.c (bus_dispatch_test): OK, now finally actually
3946 write useful test code, after all that futzing around ;-)
3948 Test does not yet pass because we can't handle OOM in
3949 _dbus_transport_messages_pending (basically,
3950 dbus_connection_preallocate_send() does not prealloc the write
3951 watch). To fix this, I think we need to add new stuff to
3952 set_watch_functions, namely a SetEnabled function so we can alloc
3953 the watch earlier, then enable it later.
3955 * dbus/Makefile.am (libdbus_convenience_la_SOURCES): move
3956 dbus-memory.c to the convenience lib
3958 * bus/test.c: rename some static functions to keep them clearly
3959 distinct from stuff in connection.c. Handle client disconnection.
3961 2003-03-14 Havoc Pennington <hp@pobox.com>
3963 * bus/dispatch.c (bus_dispatch_test): do test using debug-pipe
3964 transport, tests more of the real codepath. Set up clients
3965 with bus_setup_debug_client.
3967 * bus/test.c (bus_setup_debug_client): function to set up debug
3968 "clients" on the main loop
3970 * dbus/dbus-transport.c (_dbus_transport_open): add debug-pipe
3973 * dbus/dbus-server.c (dbus_server_listen): add debug-pipe
3976 * dbus/dbus-server-debug.c: support a debug server based on pipes
3978 * dbus/dbus-sysdeps.c (_dbus_full_duplex_pipe): new function
3979 (_dbus_close): new function
3981 * configure.in: check for socketpair
3983 2003-03-14 Havoc Pennington <hp@redhat.com>
3985 * dbus/dbus-memory.c: add a "detect buffer overwrites on free"
3988 * dbus/dbus-transport-debug.c: rework this a good bit to be
3989 less complicated. hopefully still works.
3991 * dbus/dbus-server-debug.c (handle_new_client): remove timeout
3994 * glib/dbus-gmain.c (timeout_handler): don't remove timeout
3997 * dbus/dbus-message.c (dbus_message_copy): rename from
3998 dbus_message_new_from_message, fix it up to copy
3999 all the message fields, add test case
4001 * bus/dispatch.c (bus_dispatch_test): add some more test code,
4002 not quite passing yet
4004 2003-03-14 Havoc Pennington <hp@pobox.com>
4006 * bus/loop.c (bus_loop_iterate): add this so we can "run loop
4007 until no work remains" in test code. (the large diff here
4008 is just code movement, no actual changes)
4010 * dbus/dbus-server-debug.c (DEFAULT_INTERVAL): change interval to
4011 1, no point waiting around for test code.
4012 (_dbus_server_debug_accept_transport): unref the timeout
4013 after adding it (right?)
4015 * dbus/dbus-transport-debug.c (DEFAULT_INTERVAL): ditto
4017 2003-03-13 Havoc Pennington <hp@redhat.com>
4019 * dbus/dbus-timeout.c (_dbus_timeout_list_set_functions): handle
4022 * dbus/dbus-watch.c (_dbus_watch_list_set_functions): handle out
4025 * dbus/dbus-connection.h: Make AddWatchFunction and
4026 AddTimeoutFunction return a bool so they can fail on out-of-memory
4028 * bus/bus.c (bus_context_new): set up timeout handlers
4030 * bus/connection.c (bus_connections_setup_connection): set up
4033 * glib/dbus-gmain.c: adapt to the fact that set_functions stuff
4036 * bus/bus.c (bus_context_new): adapt to changes
4038 * bus/connection.c: adapt to changes
4040 * test/watch.c: adapt to DBusWatch changes
4042 * bus/dispatch.c (bus_dispatch_test): started adding this but
4045 2003-03-14 Anders Carlsson <andersca@codefactory.se>
4047 * bus/dispatch.c (send_service_nonexistent_error): Fix typo.
4049 2003-03-13 Havoc Pennington <hp@pobox.com>
4051 * bus/test.c, bus/test.h, bus/Makefile.am, bus/test-main.c:
4052 set up a test framework as for the library
4054 2003-03-12 Havoc Pennington <hp@pobox.com>
4056 Throughout: purge global variables, introduce BusActivation,
4057 BusConnections, BusRegistry, etc. objects instead.
4059 * bus/bus.h, bus/bus.c: introduce BusContext as a global
4062 * test/Makefile.am (TEST_BINARIES): disable bus-test for now,
4063 going to redo this a bit differently I think
4065 2003-03-12 Havoc Pennington <hp@redhat.com>
4067 Mega-patch that gets the message bus daemon initially handling
4068 out-of-memory. Work still needed. Also lots of random
4069 moving stuff to DBusError instead of ResultCode.
4071 * dbus/dbus-list.c (_dbus_list_length_is_one): new function
4073 * dbus/dbus-connection.c
4074 (dbus_connection_send_with_reply_and_block): use DBusError
4076 * dbus/dbus-bus.c: adapt to API changes, make it use DBusError not
4079 * dbus/dbus-connection.c (dbus_connection_send): drop the result
4080 code here, as the only failure possible is OOM.
4082 * bus/connection.c (bus_connection_disconnect):
4083 rename bus_connection_disconnected as it's a notification only
4085 * bus/driver.c (bus_driver_handle_acquire_service): don't free
4086 "name" on get_args failure, should be done by get_args;
4087 don't disconnect client for bad args, just return an error.
4088 (bus_driver_handle_service_exists): ditto
4090 * bus/services.c (bus_services_list): NULL-terminate returned array
4092 * bus/driver.c (bus_driver_send_service_lost)
4093 (bus_driver_send_service_acquired): send messages from driver to a
4094 specific client to the client's unique name, not to the broadcast
4097 * dbus/dbus-message.c (decode_header_data): reject messages that
4098 contain no name field
4099 (_dbus_message_get_client_serial): rename to
4100 dbus_message_get_serial and make public
4101 (_dbus_message_set_serial): rename from set_client_serial
4102 (_dbus_message_set_reply_serial): make public
4103 (_dbus_message_get_reply_serial): make public
4105 * bus/connection.c (bus_connection_foreach): allow stopping
4106 iteration by returning FALSE from foreach function.
4108 * dbus/dbus-connection.c (dbus_connection_send_preallocated)
4109 (dbus_connection_free_preallocated_send)
4110 (dbus_connection_preallocate_send): new API for sending a message
4111 without possibility of malloc failure.
4112 (dbus_connection_send_message): rename to just
4113 dbus_connection_send (and same for whole function family)
4115 * dbus/dbus-errors.c (dbus_error_free): make this reinit the error
4117 * dbus/dbus-sysdeps.c (_dbus_exit): new function
4119 * bus/activation.c: handle/return errors
4121 * dbus/dbus-errors.h: add more DBUS_ERROR #define
4123 * dbus/dbus-sysdeps.c (_dbus_directory_open) (_dbus_file_get_contents)
4124 (_dbus_directory_get_next_file): use DBusError instead of DBusResultCode
4125 (_dbus_result_from_errno): move to this file
4127 2003-03-10 Anders Carlsson <andersca@codefactory.se>
4129 * dbus/dbus-marshal.c:
4130 (_dbus_marshal_set_string):
4131 Take a length argument so we can marshal the correct string
4134 (_dbus_marshal_dict), (_dbus_demarshal_dict),
4135 (_dbus_marshal_get_arg_end_pos), (_dbus_marshal_validate_arg),
4136 (_dbus_marshal_test):
4137 * dbus/dbus-marshal.h:
4138 Add support for marshalling and demarshalling dicts.
4140 * dbus/dbus-message-builder.c: (_dbus_message_data_load):
4141 Add support for TYPE DICT.
4143 * dbus/dbus-message.c: (set_string_field):
4144 Adjust header padding.
4146 (dbus_message_append_args_valist), (dbus_message_append_dict),
4147 (dbus_message_get_args_valist), (dbus_message_iter_get_arg_type),
4148 (dbus_message_iter_get_dict), (_dbus_message_loader_return_buffer),
4149 (check_message_handling), (check_have_valid_message):
4150 * dbus/dbus-message.h:
4151 Add functions for setting and getting dicts.
4153 * dbus/dbus-protocol.h:
4159 * doc/dbus-specification.sgml:
4160 Add information about how dicts are marshalled.
4162 * test/data/invalid-messages/dict-with-nil-value.message:
4163 * test/data/invalid-messages/too-short-dict.message:
4164 * test/data/valid-messages/dict-simple.message:
4165 * test/data/valid-messages/dict.message:
4166 Add sample messages containing dicts.
4168 2003-03-08 Anders Carlsson <andersca@codefactory.se>
4170 * dbus/dbus-dict.h: Add DBUS_END_DECLS.
4172 2003-03-07 Anders Carlsson <andersca@codefactory.se>
4175 * dbus/dbus-dict.c: (dbus_dict_entry_free), (dbus_dict_new),
4176 (dbus_dict_get_keys), (insert_entry), (dbus_dict_set_boolean),
4177 (dbus_dict_set_int32), (dbus_dict_set_uint32),
4178 (dbus_dict_set_double), (dbus_dict_set_string),
4179 (dbus_dict_set_boolean_array), (dbus_dict_set_int32_array),
4180 (dbus_dict_set_uint32_array), (dbus_dict_set_double_array),
4181 (dbus_dict_set_string_array), (_dbus_dict_test):
4183 Fix according to comments from Havoc.
4185 2003-03-06 Michael Meeks <michael@server.home>
4187 * configure.in: if we don't have kde-config, disable have_qt.
4189 2003-03-07 Anders Carlsson <andersca@codefactory.se>
4194 * dbus/dbus-dict.c: (dbus_dict_entry_free), (dbus_dict_new),
4195 (dbus_dict_ref), (dbus_dict_unref), (dbus_dict_contains),
4196 (dbus_dict_remove), (dbus_dict_get_value_type),
4197 (dbus_dict_get_keys), (dbus_dict_put_boolean),
4198 (dbus_dict_put_int32), (dbus_dict_put_uint32),
4199 (dbus_dict_put_double), (dbus_dict_put_string),
4200 (dbus_dict_put_boolean_array), (dbus_dict_put_int32_array),
4201 (dbus_dict_put_uint32_array), (dbus_dict_put_double_array),
4202 (dbus_dict_put_string_array), (dbus_dict_get_boolean),
4203 (dbus_dict_get_int32), (dbus_dict_get_uint32),
4204 (dbus_dict_get_double), (dbus_dict_get_string),
4205 (dbus_dict_get_boolean_array), (dbus_dict_get_int32_array),
4206 (dbus_dict_get_uint32_array), (dbus_dict_get_double_array),
4207 (dbus_dict_get_string_array), (_dbus_dict_test):
4209 Add DBusDict implementation
4211 * dbus/dbus-test.c: (dbus_internal_do_not_use_run_tests):
4215 2003-03-04 Havoc Pennington <hp@pobox.com>
4217 * test/data/auth/*: adapt to changes
4219 * dbus/dbus-auth-script.c (_dbus_auth_script_run): add
4220 USERID_BASE64 and change USERNAME_BASE64 to put in username not
4223 * dbus/dbus-keyring.c (_dbus_keyring_validate_context): prevent
4224 more stuff from being in a context name, to make the protocol
4225 simpler to deal with
4227 * dbus/dbus-errors.c (dbus_error_has_name): new function
4228 (dbus_error_is_set): new function
4230 * dbus/dbus-auth.c: replace DBUS_STUPID_TEST_MECH auth
4231 with DBUS_COOKIE_SHA1, implement DBUS_COOKIE_SHA1
4233 * dbus/dbus-connection.c (dbus_connection_flush): also read
4234 messages during a flush operation
4236 * dbus/Makefile.am: remove dbus-md5 since it isn't currently used.
4238 2003-03-05 Anders Carlsson <andersca@codefactory.se>
4240 * configure.in: Check for gethostbyname on Solaris.
4242 * dbus/dbus-transport.c: (_dbus_transport_open):
4243 Remove duplicate "tcp" entry.
4245 * doc/dbus-specification.sgml:
4246 Clarify some things.
4248 2003-03-05 Anders Carlsson <andersca@codefactory.se>
4250 * dbus/dbus-auth.c: (send_rejected), (process_test_subdir):
4251 * dbus/dbus-keyring.c: (_dbus_keyring_new_homedir),
4252 (_dbus_keyring_test):
4253 * dbus/dbus-md5.c: (_dbus_md5_compute):
4254 * dbus/dbus-sha.c: (_dbus_sha_compute):
4257 2003-03-05 Anders Carlsson <andersca@codefactory.se>
4259 * README: Add some things.
4261 2003-03-04 Anders Carlsson <andersca@codefactory.se>
4263 * dbus/dbus-message.c (dbus_message_append_args_valist): Add a break;
4264 after case DBUS_TYPE_BOOELAN.
4266 2003-03-02 Havoc Pennington <hp@pobox.com>
4268 * test/break-loader.c (randomly_set_extreme_ints): add test that
4269 sets really huge and small integers
4271 * dbus/dbus-marshal.c (_dbus_marshal_validate_arg): add check
4272 that length of boolean array fits in the string, and that
4273 string has room for boolean value in single-bool case.
4275 * dbus/dbus-message-builder.c (_dbus_message_data_load): add
4276 optional value to "ALIGN" command which is what to fill the
4279 * test/data/valid-messages/no-padding.message: add regression
4280 test for the message padding problem
4282 2003-03-02 Havoc Pennington <hp@pobox.com>
4284 * dbus/dbus-message.c (decode_header_data): fix to always init
4285 message_padding, from Benjamin Dauvergne
4287 2003-03-02 Havoc Pennington <hp@pobox.com>
4293 2003-03-01 Joe Shaw <joe@assbarn.com>
4295 * configure.in: Check for "struct cmsgcred" and try to access its
4296 members for BSD-like unices.
4298 * dbus/dbus-sysdeps.c (read_credentials_byte): Fold this back into
4299 _dbus_read_credentials_unix_socket().
4300 (_dbus_read_credentials_unix_socket): Use recvmsg() instead of
4301 read() for reading the credential byte off the unix socket. Use
4302 struct cmsgcred on systems that support it.
4304 2003-02-27 Alexander Larsson <alexl@redhat.com>
4308 Make gthreads-2.0 dependency optional. Don't build thread test if
4311 2003-02-27 Havoc Pennington <hp@pobox.com>
4313 * dbus/dbus-connection.c
4314 (dbus_connection_send_message_with_reply_and_block): fix doh!
4315 doh! doh! bug that resulted in never removing a reply from the
4316 queue, no wonder we called get_reply_serial so much ;-)
4318 * dbus/dbus-message.c (struct DBusMessage): cache reply serial
4319 and client serial instead of demarshaling them every time
4321 2003-02-27 Havoc Pennington <hp@pobox.com>
4323 * dbus/dbus-marshal.c (_dbus_demarshal_int32): rewrite to be much
4324 more inlined, using dbus-string-private.h, speeds things up
4327 * dbus/dbus-string.c (_dbus_string_free): apply align offset
4328 when freeing the string
4329 (_dbus_string_steal_data): fix for align offset
4330 (undo_alignment): new function
4332 2003-02-26 Havoc Pennington <hp@redhat.com>
4334 All kinds of audit fixes from Owen, plus initial attempt to
4335 handle unaligned memory returned from malloc.
4337 * dbus/dbus-string.c (_dbus_string_init): clamp max length to
4338 leave room for align_offset and nul byte
4339 (fixup_alignment): function to track an align_offset and
4340 ensure real->str is aligned
4341 (DBUS_GENERIC_STRING_PREAMBLE): len must be less than allocated,
4342 to allow a nul byte plus align offset
4343 (_dbus_string_lock): fix overflow issue
4344 (_dbus_string_init_const_len): add assertions on sanity of len,
4345 assign allocated to be ALLOCATION_PADDING larger than len
4346 (set_length): fixup the overflow handling
4347 (_dbus_string_get_data_len): fix overflow in assertion
4348 (open_gap): detect overflow in size of gap to be opened
4349 (_dbus_string_lengthen): add overflow check
4350 (_dbus_string_align_length): fix overflow with _DBUS_ALIGN_VALUE
4351 (_dbus_string_append): add overflow check
4352 (_dbus_string_append_unichar): overflow
4353 (_dbus_string_delete): fix overflow in assertion
4354 (_dbus_string_copy_len): overflow in assertion
4355 (_dbus_string_replace_len): overflows in assertions
4356 (_dbus_string_find): change to implement in terms of
4357 _dbus_string_find_to
4358 (_dbus_string_find_to): assorted fixage
4359 (_dbus_string_equal_c_str): assert c_str != NULL,
4360 fix logic so the function works
4361 (_dbus_string_ends_with_c_str): fix overflow thingy
4362 (_dbus_string_base64_encode): overflow fix
4363 (_dbus_string_validate_ascii): overflow
4364 (_dbus_string_validate_nul): overflow
4366 2003-02-26 Havoc Pennington <hp@redhat.com>
4368 * dbus/dbus-marshal.c (_dbus_marshal_test): fix to work with DISABLE_ASSERTS
4370 2003-02-26 Alexander Larsson <alexl@redhat.com>
4373 Set DBUS_GLIB_THREADS_LIBS for apps using gthread-2.0
4375 * dbus/dbus-connection.c:
4376 * dbus/dbus-connection.h:
4377 Fix _dbus_connection_acquire_io_path and _dbus_connection_acquire_dispatch.
4378 Add dbus_connection_set_wakeup_main_function and use it when queueing
4379 incoming and outgoing messages.
4382 * dbus/dbus-dataslot.c:
4383 Threadsafe usage of DBusDataSlotAllocator
4385 * dbus/dbus-message.c: (dbus_message_get_args_iter):
4388 * dbus/dbus-server-unix.c:
4391 * glib/dbus-gmain.c:
4392 Implement the new wakeup functions for glib.
4395 * glib/test-thread-client.c:
4396 * glib/test-thread-server.c:
4397 * glib/test-thread.h:
4398 Initial cut at some thread test code. Not really done yet.
4400 2003-02-26 Havoc Pennington <hp@pobox.com>
4402 * dbus/dbus-connection.c
4403 (dbus_connection_send_message_with_reply_and_block): fix crash
4404 where we ref'd the outgoing message instead of the returned reply
4406 * dbus/dbus-transport-unix.c (do_authentication): check read watch
4407 at the end of this function, so if we didn't need to read for
4408 authentication, we reinstall it for receiving messages
4410 * dbus/dbus-message.c (dbus_message_new_reply): allow replies to
4411 a NULL sender for peer-to-peer case
4413 * dbus/dbus-transport-unix.c (check_read_watch): handle
4414 !authenticated case correctly
4416 * glib/dbus-gmain.c: add support for DBusServer
4418 * dbus/dbus-server.c: add data slot support
4420 * glib/dbus-gmain.c (dbus_connection_setup_with_g_main): check
4421 return values and handle errors
4423 * dbus/dbus-dataslot.c: factor out the data slot stuff from
4426 * Doxyfile.in (INPUT): add glib subdir
4428 * glib/dbus-gmain.c (dbus_connection_setup_with_g_main): rename
4429 setup_with_g_main instead of hookup_with_g_main; write docs
4431 2003-02-24 Anders Carlsson <andersca@codefactory.se>
4433 * dbus/dbus-marshal.c: (_dbus_marshal_validate_arg):
4434 * dbus/dbus-message-builder.c: (_dbus_message_data_load):
4435 * dbus/dbus-message.c: (dbus_message_append_boolean),
4436 (dbus_message_append_boolean_array),
4437 (dbus_message_get_args_valist), (_dbus_message_test):
4438 * dbus/dbus-message.h:
4439 * doc/dbus-specification.sgml:
4440 Various fixes as pointed out by Havoc.
4442 * test/data/invalid-messages/bad-boolean-array.message:
4443 * test/data/invalid-messages/bad-boolean.message:
4444 Add invalid boolean value test cases.
4446 2003-02-24 Anders Carlsson <andersca@codefactory.se>
4448 * dbus/dbus-internals.c: (_dbus_type_to_string):
4449 * dbus/dbus-marshal.c: (_dbus_marshal_get_arg_end_pos),
4450 (_dbus_marshal_validate_arg):
4451 * dbus/dbus-message-builder.c: (_dbus_message_data_load):
4452 * dbus/dbus-message.c: (dbus_message_append_args_valist),
4453 (dbus_message_append_boolean), (dbus_message_append_boolean_array),
4454 (dbus_message_get_args_valist), (dbus_message_iter_get_boolean),
4455 (dbus_message_iter_get_int32), (dbus_message_iter_get_uint32),
4456 (dbus_message_iter_get_double),
4457 (dbus_message_iter_get_boolean_array), (message_iter_test):
4458 * dbus/dbus-message.h:
4459 * dbus/dbus-protocol.h:
4460 * doc/dbus-specification.sgml:
4461 * test/data/valid-messages/lots-of-arguments.message:
4462 Add support for boolean and boolean array types.
4464 2003-02-23 Havoc Pennington <hp@pobox.com>
4466 * dbus/dbus-keyring.c: finish most of this implementation and
4469 * dbus/dbus-errors.c (dbus_set_error_const, dbus_set_error): make
4470 these barf if the error isn't cleared to NULL
4472 * dbus/dbus-sysdeps.c (_dbus_delete_file): set error on failure
4473 (_dbus_create_directory): new function
4475 * dbus/dbus-errors.c (dbus_set_error): fix warning
4477 * dbus/dbus-string.c (_dbus_string_hex_encode): new function
4478 (_dbus_string_hex_decode): new function
4479 (test_hex_roundtrip): test code
4481 * dbus/dbus-sha.c (_dbus_sha_compute): use dbus_string_hex_encode
4483 * dbus/dbus-md5.c (_dbus_md5_compute): use dbus_string_hex_encode
4485 * dbus/dbus-sysdeps.c (_dbus_string_save_to_file): make this use
4486 the save-to-temp/rename trick to atomically write the new file
4487 (_dbus_string_parse_uint): new function
4489 2003-02-22 Havoc Pennington <hp@pobox.com>
4491 * test/Makefile.am (dist-hook): fix dist for test/data/sha-1
4493 2003-02-22 Havoc Pennington <hp@pobox.com>
4495 * dbus/dbus-message.c (dbus_message_iter_get_string_array):
4496 (dbus_message_iter_get_byte_array): Fix up doxygen warnings
4498 * dbus/dbus-sha.c: add implementation of SHA-1 algorithm
4500 * dbus/test/data/sha-1: add US government test suite for SHA-1
4502 2003-02-21 Anders Carlsson <andersca@codefactory.se>
4504 * dbus/dbus-marshal.c: (_dbus_demarshal_string_array):
4505 Make string arrays NULL-terminated.
4507 * dbus/dbus-memory.c: (dbus_free_string_array):
4508 * dbus/dbus-memory.h:
4509 New function for freeing NULL-terminated string arrays.
4511 * dbus/dbus-message-builder.c: (append_quoted_string),
4512 (_dbus_message_data_load):
4513 Add support for array types.
4515 * dbus/dbus-message.c: (check_message_handling):
4516 Add more types as test cases.
4518 * dbus/dbus-sysdeps.c: (_dbus_string_parse_int),
4519 (_dbus_string_parse_double):
4520 Add the start offset to the end offset.
4522 * test/data/valid-messages/lots-of-arguments.message:
4523 New test message with lots of arguments.
4525 2003-02-21 Anders Carlsson <andersca@codefactory.se>
4527 * dbus/dbus-message.c: (dbus_message_append_nil),
4528 (dbus_message_append_int32), (dbus_message_append_uint32),
4529 (dbus_message_append_double), (dbus_message_append_string),
4530 (dbus_message_append_int32_array),
4531 (dbus_message_append_uint32_array),
4532 (dbus_message_append_double_array),
4533 (dbus_message_append_byte_array),
4534 (dbus_message_append_string_array):
4535 Fix all out-of-memory handling in these functions.
4537 2003-02-21 Anders Carlsson <andersca@codefactory.se>
4539 * dbus/dbus-message.c: (dbus_message_append_nil):
4542 2003-02-21 Anders Carlsson <andersca@codefactory.se>
4544 * dbus/dbus-message.c: (dbus_message_append_args_valist),
4545 (dbus_message_append_nil), (dbus_message_append_int32_array),
4546 (dbus_message_append_uint32_array),
4547 (dbus_message_append_double_array),
4548 (dbus_message_append_byte_array),
4549 (dbus_message_append_string_array), (dbus_message_get_args_valist),
4550 (dbus_message_iter_get_int32_array),
4551 (dbus_message_iter_get_uint32_array),
4552 (dbus_message_iter_get_double_array),
4553 (dbus_message_iter_get_byte_array),
4554 (dbus_message_iter_get_string_array):
4556 * dbus/dbus-message.h:
4557 Add functions for appending and getting arrays.
4559 2003-02-21 Anders Carlsson <andersca@codefactory.se>
4561 * dbus/dbus-mempool.c (_dbus_mem_pool_new): Make the
4562 element size at least 8 bytes, fixes mempool tests on
4565 2003-02-20 Alexander Larsson <alexl@redhat.com>
4567 * dbus/dbus-transport-unix.c (unix_do_iteration):
4568 Unlock the connection mutex during a blocking select call.
4569 Add todo about how we need a way to wake up the select.
4571 * dbus/dbus-connection-internal.h:
4572 * dbus/dbus-connection.c:
4573 Add _dbus_connection_lock and _dbus_connection_unlock.
4575 2003-02-19 Havoc Pennington <hp@pobox.com>
4577 * Doxyfile.in (PREDEFINED): put DOXYGEN_SHOULD_SKIP_THIS in
4578 Doxyfile.in, not Doxyfile
4580 * dbus/dbus-keyring.c: do some hacking on this
4582 * dbus/dbus-sysdeps.c (_dbus_delete_file): new
4584 * dbus/dbus-errors.c (dbus_set_error_const): do not call
4586 (dbus_set_error): remove dbus_error_init, check for message ==
4587 NULL *before* we sprintf into it, and add @todo about including
4588 system headers in this file
4590 * dbus/dbus-sysdeps.c (_dbus_create_file_exclusively): new
4592 * dbus/dbus-errors.h (DBUS_ERROR_FAILED): add
4594 * dbus/dbus-sysdeps.c (get_user_info): break this function out to
4595 get various bits of user information based on either username
4597 (_dbus_homedir_from_username): new function
4599 2003-02-19 Anders Carlsson <andersca@codefactory.se>
4602 Add check for nonposix getpwnam_r
4604 * dbus/dbus-mempool.c: (_dbus_mem_pool_new):
4605 Align the pool element size to a sizeof (void *) boundary.
4607 * dbus/dbus-sysdeps.c: (_dbus_setenv), (_dbus_connect_unix_socket),
4608 (_dbus_listen_unix_socket), (_dbus_credentials_from_username):
4609 General Solaris fixes.
4611 * test/data/valid-messages/simplest-manual.message:
4612 Explicitly state that we want little-endian packing.
4614 2003-02-19 Mikael Hallendal <micke@codefactory.se>
4616 * dbus/dbus-server.c (dbus_server_listen): Support tcp: addresses.
4618 * dbus/dbus-transport-unix.c (_dbus_transport_new_for_tcp_socket):
4619 Added to create a transport connecting using a tcp/ip socket.
4621 * dbus/dbus-sysdeps.c (_dbus_connect_tcp_socket): Added to connect
4622 to a tcp socket at given host and port.
4623 (_dbus_listen_tcp_socket): added to listen on tcp socket for given
4626 * dbus/dbus-server.c (dbus_server_listen): Support tcp: addresses.
4628 * dbus/dbus-server-unix.c (_dbus_server_new_for_tcp_socket):
4629 Added to create a server listening on a TCP/IP socket.
4631 2003-02-19 Havoc Pennington <hp@pobox.com>
4633 Throughout: mop up all the Doxygen warnings and undocumented
4636 * dbus/dbus-sysdeps.c (do_exec): do not use execvp, we don't want
4637 to search any paths.
4639 * dbus/dbus-threads.c: move global mutex initializers to
4640 dbus-internals.h, multiple prototypes was confusing doxygen
4641 besides being kind of ugly
4643 * Doxyfile (PREDEFINED): have Doxygen define
4644 DOXYGEN_SHOULD_SKIP_THIS so we can exclude things from
4645 docs with #ifndef DOXYGEN_SHOULD_SKIP_THIS
4646 (do not abuse the feature! it's for stuff like the autogenerated
4647 macros in dbus-md5.c, not just for things you don't feel like
4650 2003-02-18 Havoc Pennington <hp@pobox.com>
4652 * dbus/dbus-string.c (_dbus_string_zero): new function
4654 * dbus/dbus-md5.c: include MD5 implementation by L. Peter Deutsch,
4655 wrap it in some dbus-friendly API
4657 * dbus/dbus-types.h: add 16-bit types
4659 2003-02-18 Joe Shaw <joe@assbarn.com>
4661 * dbus/dbus-auth.c (handle_server_data_stupid_test_mech): Just get
4662 credentials from our currently running process.
4663 (get_word): Fix a buglet where we were copying the entire length
4664 instead of relative to our position.
4666 * dbus/dbus-hash.c (_dbus_hash_test): Don't try to allocate the
4667 keys on the stack... it's 640k of data.
4669 * dbus/dbus-sysdeps.c (_dbus_read_credentials_unix_socket): Always
4670 read the credentials byte off the socket, even if we don't have
4672 (_dbus_poll): Implement poll() using select() for systems which
4675 * glib/test-dbus-glib.c (main): Print out an error if no
4676 parameters are given.
4678 * test/data/auth/fallback.auth-script: Added. Tests that a client
4679 can fallback to a secondary auth mechanism if the first fails.
4681 2003-02-18 Havoc Pennington <hp@pobox.com>
4685 2003-02-17 Havoc Pennington <hp@pobox.com>
4687 * doc/dbus-specification.sgml: lots of cosmetic
4688 cleanups/rearrangement, add assorted FIXME, change DBUS_ADDRESS
4689 env variable to DBUS_BUS_ADDRESS, s/client/application/,
4690 s/server/bus/ (except in authentication section). Add a section
4691 "Message Bus Message Routing"
4693 2003-02-17 Anders Carlsson <andersca@codefactory.se.>
4699 2003-02-17 Anders Carlsson <andersca@codefactory.se>
4701 * doc/dbus-specification.sgml:
4702 Specification updates.
4704 2003-02-17 Anders Carlsson <andersca@codefactory.se>
4706 * bus/activation.c: (bus_activation_init), (child_setup),
4707 (bus_activation_activate_service):
4709 * bus/main.c: (main):
4710 Set DBUS_ADDRESS environment variable.
4712 * dbus/dbus-errors.c: (dbus_set_error):
4713 Don't use va_copy since that's a C99 feature.
4715 * dbus/dbus-sysdeps.c: (_dbus_setenv), (do_exec),
4716 (_dbus_spawn_async):
4717 * dbus/dbus-sysdeps.h:
4718 Add child_setup_func to _dbus_spawn_async.
4720 * doc/dbus-specification.sgml:
4721 Update specification.
4723 * test/spawn-test.c: (setup_func), (main):
4726 2003-02-17 Alexander Larsson <alexl@redhat.com>
4728 * dbus/dbus-connection.c (_dbus_connection_handler_destroyed_locked):
4731 2003-02-17 Anders Carlsson <andersca@codefactory.se>
4735 * doc/dbus-test-plan.sgml:
4736 Add test plan document.
4741 2003-02-17 Anders Carlsson <andersca@codefactory.se>
4743 * dbus/dbus-message.c: (decode_header_data),
4744 (_dbus_message_loader_return_buffer):
4745 Set the header padding amount when loading a message.
4747 2003-02-16 Anders Carlsson <andersca@codefactory.se>
4749 * bus/dispatch.c: (send_one_message):
4750 Only send broadcast messages to registered connections.
4752 * dbus/dbus-message.c: (dbus_message_name_is):
4753 * dbus/dbus-message.h:
4754 New convenience function.
4756 * dbus/dbus-transport-debug.c: (do_reading):
4757 Only dispatch one message per run.
4760 * test/bus-test.c: (new_connection_callback), (die),
4761 (test_hello_client1_handler), (test_hello_client2_handler),
4762 (test_hello_replies), (main):
4764 * test/bus-test-loop.[ch]:
4767 2003-02-16 Havoc Pennington <hp@pobox.com>
4769 * dbus/dbus-connection.c (dbus_connection_dispatch_message): fix
4770 backward conditional
4772 2003-02-16 Alexander Larsson <alexl@redhat.com>
4774 * dbus/dbus-connection.c:
4775 Implement sent_message_with_reply. (with_reply_and block is still
4777 Made dispatch_message not lose message if OOM.
4779 * dbus/dbus-errors.h:
4780 Add NoReply error (for reply timeouts).
4782 2003-02-16 Alexander Larsson <alexl@redhat.com>
4784 * dbus/dbus-hash.c (_dbus_hash_table_unref):
4785 Actually free keys and values when destroying hashtable.
4787 2003-02-16 Anders Carlsson <andersca@codefactory.se>
4789 * dbus/dbus-auth.c: (client_try_next_mechanism):
4792 * dbus/dbus-threads.c: (dbus_condvar_wait_timeout):
4793 Return TRUE if there's no thread implementation around.
4795 * glib/dbus-gmain.c: (free_source),
4796 (dbus_connection_hookup_with_g_main):
4797 Make sure to remove the GSource when the connection is finalized.
4799 2003-02-16 Anders Carlsson <andersca@codefactory.se>
4801 * bus/dispatch.c: (bus_dispatch_message_handler):
4802 * dbus/dbus-errors.h:
4803 Return an error if someone tries to send a message to a service
4806 2003-02-16 Anders Carlsson <andersca@codefactory.se>
4808 * bus/activation.c: (load_directory), (bus_activation_init),
4809 (bus_activation_activate_service):
4812 (bus_driver_handle_activate_service), (bus_driver_handle_message):
4813 More work on the activation handling.
4815 * dbus/dbus-errors.h:
4816 Add some error messages
4818 * dbus/dbus-message.c: (dbus_message_new_error_reply):
4819 * dbus/dbus-message.h:
4820 New function that creates an error message.
4822 * dbus/dbus-protocol.h:
4823 Add ACTIVATE_SERVER message.
4825 * dbus/dbus-server-unix.c: (unix_handle_watch),
4826 (_dbus_server_new_for_domain_socket):
4827 Call _dbus_fd_set_close_on_exec.
4829 * dbus/dbus-sysdeps.c: (make_pipe), (do_exec),
4830 (_dbus_spawn_async), (_dbus_disable_sigpipe),
4831 (_dbus_fd_set_close_on_exec):
4832 * dbus/dbus-sysdeps.h:
4833 Add _dbus_fd_set_close_on exec function. Also add function that checks
4834 that all open fds are set to close-on-exec and warns otherwise.
4836 * dbus/dbus-transport-unix.c:
4837 (_dbus_transport_new_for_domain_socket):
4838 Call _dbus_fd_set_close_on_exec.
4840 2003-02-16 Havoc Pennington <hp@pobox.com>
4842 * dbus/dbus-connection.c (dbus_connection_set_change_sigpipe):
4843 allow people to avoid setting SIGPIPE to SIG_IGN
4844 (_dbus_connection_new_for_transport): disable SIGPIPE unless
4845 we've been asked not to
4847 2003-02-15 Anders Carlsson <andersca@codefactory.se>
4849 * dbus/dbus-list.c: (_dbus_list_append_link),
4850 (_dbus_list_prepend_link):
4851 * dbus/dbus-memory.c: (dbus_malloc), (dbus_malloc0),
4855 2003-02-15 Anders Carlsson <andersca@codefactory.se>
4858 * bus/activation.c: (bus_activation_entry_free),
4859 (add_desktop_file_entry), (load_directory), (bus_activation_init):
4861 * bus/main.c: (main):
4862 Add simple activation support, doesn't work yet though.
4864 2003-02-15 Zack Rusin <zack@kde.org>
4866 * qt/dbus-qthread.cpp: small casting fix
4868 2003-02-15 Anders Carlsson <andersca@codefactory.se>
4870 * dbus/dbus-errors.c: (dbus_set_error):
4871 * dbus/dbus-errors.h:
4872 Add a few errors and make dbus_set_error void.
4874 * dbus/dbus-sysdeps.c:
4875 (_dbus_errno_to_string), (close_and_invalidate), (make_pipe),
4876 (write_err_and_exit), (read_ints), (do_exec), (_dbus_spawn_async):
4877 * dbus/dbus-sysdeps.h:
4878 Add _dbus_spawn_async.
4880 * test/spawn-test.c: (main):
4881 Test for _dbus_spawn_async.
4883 2003-02-15 Anders Carlsson <andersca@codefactory.se>
4885 * dbus/dbus-internals.h:
4886 Fix build without tests.
4888 * dbus/dbus-list.c: (alloc_link):
4889 Fix a segfault when a malloc fails.
4891 * dbus/dbus-memory.c: (initialize_malloc_debug), (dbus_malloc),
4892 (dbus_malloc0), (dbus_realloc):
4893 Add support for malloc debugging.
4895 2003-02-15 Alexander Larsson <alexl@redhat.com>
4897 * dbus/dbus-threads.c:
4898 * dbus/dbus-threads.h:
4899 Add condvars. Remove static mutext from API.
4900 Implement static mutexes by initializing them from threads_init.
4902 * glib/dbus-gthread.c:
4903 * qt/dbus-qthread.cpp:
4904 Update with the thread api changes.
4909 Turn StaticMutex into normal mutex + init function.
4910 Export new functions _dbus_list_alloc_link, _dbus_list_free_link,
4911 _dbus_list_append_link, _dbus_list_prepend_link
4914 * dbus/dbus-sysdeps.c:
4915 * dbus/dbus-sysdeps.h:
4916 New type dbus_atomic_t, and new functions _dbus_atomic_inc,
4917 _dbus_atomic_dec. Only slow fallback implementation at the moment.
4919 * dbus/dbus-protocol.h:
4920 Add DBUS_MESSAGE_LOCAL_DISCONNECT define
4922 * dbus/dbus-message.c:
4923 Make ref/unref atomic.
4926 * dbus/dbus-connection-internal.h:
4927 * dbus/dbus-connection.c:
4928 * dbus/dbus-connection.h:
4930 Change _peek to _borrow,_return & _steal_borrowed.
4931 Change disconnect callback to event.
4932 Make dbus_connection_dispatch_messages reentrant.
4934 * dbus/dbus-transport.c:
4935 Don't ref the connection on calls to the transport
4938 * dbus/dbus-message-handler.c:
4941 * glib/dbus-gmain.c:
4942 Don't use peek_message anymore
4945 * test/debug-thread.c:
4946 * test/debug-thread.h:
4947 Simple thread implementation that asserts() on deadlocks in
4948 single-threaded code.
4951 (main) Call debug_threads_init.
4954 Use disconnect message instead of disconnect callback.
4958 Don't call dbus_connection_set_disconnect_function. Instead export
4959 bus_connection_disconnect.
4962 Call bus_connection_disconnect when we get a disconnected message.
4964 2003-02-15 Havoc Pennington <hp@pobox.com>
4966 * dbus/dbus-message.c (dbus_message_new): fool around with the
4969 2003-02-14 Havoc Pennington <hp@pobox.com>
4971 * dbus/dbus-mempool.c: fail if the debug functions so indicate
4973 * dbus/dbus-memory.c: fail if the debug functions indicate we
4976 * dbus/dbus-internals.c (_dbus_set_fail_alloc_counter)
4977 (_dbus_decrement_fail_alloc_counter): debug functions to
4978 simulate memory allocation failures
4980 2003-02-14 Havoc Pennington <hp@pobox.com>
4982 * dbus/dbus-errors.h (struct DBusError): add a word of padding
4985 2003-02-13 Anders Carlsson <andersca@codefactory.se>
4987 * bus/driver.c: (bus_driver_handle_hello):
4989 * bus/services.c: (bus_service_lookup):
4990 Reorder message sending so we get a more sane order.
4992 * test/bus-test.c: (message_handler):
4995 2003-02-13 Anders Carlsson <andersca@codefactory.se>
4997 * bus/driver.c: (bus_driver_send_service_deleted),
4998 (bus_driver_send_service_created), (bus_driver_send_service_lost),
4999 (bus_driver_send_service_acquired), (bus_driver_handle_hello),
5000 (bus_driver_send_welcome_message),
5001 (bus_driver_handle_list_services),
5002 (bus_driver_handle_acquire_service),
5003 (bus_driver_handle_service_exists):
5004 * dbus/dbus-bus.c: (dbus_bus_register_client),
5005 (dbus_bus_acquire_service), (dbus_bus_service_exists):
5006 * dbus/dbus-errors.c: (dbus_result_to_string):
5007 * dbus/dbus-errors.h:
5008 * dbus/dbus-message.c: (dbus_message_append_args),
5009 (dbus_message_append_args_valist), (dbus_message_get_args),
5010 (dbus_message_get_args_valist), (dbus_message_get_args_iter),
5011 (dbus_message_iter_get_arg_type), (dbus_message_iter_get_string),
5012 (dbus_message_iter_get_byte_array),
5013 (dbus_message_iter_get_string_array), (message_iter_test),
5014 (check_message_handling), (_dbus_message_test):
5015 * dbus/dbus-message.h:
5016 * test/bus-test.c: (main):
5017 Change fields to arguments in messages, so that they won't be
5018 confused with header fields.
5020 * glib/test-dbus-glib.c: (main):
5021 Remove append_fields from hello message.
5023 2003-02-13 Anders Carlsson <andersca@codefactory.se>
5025 * dbus/dbus-errors.c:
5026 * dbus/dbus-message.c:
5027 * dbus/dbus-string.c:
5028 Documentation fixes.
5030 2003-02-13 Anders Carlsson <andersca@codefactory.se>
5032 * glib/dbus-gmain.c: (timeout_handler), (add_timeout),
5034 Implement support for timeouts in dbus-glib.
5036 2003-02-13 Anders Carlsson <andersca@codefactory.se>
5038 * dbus/dbus-message-builder.c: (_dbus_message_data_load):
5039 * dbus/dbus-message.c: (process_test_subdir):
5040 * test/break-loader.c: (find_breaks_based_on):
5041 Plug some memory leaks.
5043 2003-02-13 Richard Hult <rhult@codefactory.se>
5045 * bus/main.c: Fix build.
5047 * dbus/dbus-errors.h:
5048 * dbus/dbus-errors.c: Fix copyright for Anders.
5050 2003-02-13 Anders Carlsson <andersca@codefactory.se>
5055 * bus/connection.c: (bus_connection_foreach):
5058 * bus/desktop-file.c: (grow_lines_in_section), (grow_sections),
5059 (unescape_string), (new_section), (parse_section_start),
5060 (parse_key_value), (report_error), (bus_desktop_file_load),
5061 (bus_desktop_file_get_string):
5062 * bus/desktop-file.h:
5063 Use DBusError for error reporting.
5065 * bus/dispatch.c: (send_one_message),
5066 (bus_dispatch_message_handler):
5067 * bus/driver.c: (bus_driver_send_service_deleted),
5068 (bus_driver_send_service_created), (bus_driver_send_service_lost),
5069 (bus_driver_send_service_acquired), (bus_driver_handle_hello),
5070 (bus_driver_send_welcome_message),
5071 (bus_driver_handle_list_services),
5072 (bus_driver_handle_acquire_service),
5073 (bus_driver_handle_service_exists):
5074 * bus/loop.c: (bus_loop_run):
5076 Use BUS_HANDLE_OOM instead of _DBUS_HANDLE_OOM.
5078 * bus/utils.c: (bus_wait_for_memory):
5080 New files with general utility functions.
5082 * dbus/dbus-internals.h:
5083 Remove _DBUS_HANDLE_OOM.
5085 2003-02-13 Anders Carlsson <andersca@codefactory.se>
5087 * dbus/dbus-errors.c: (dbus_result_to_string), (dbus_error_init),
5088 (dbus_error_free), (dbus_set_error_const), (dbus_set_error):
5089 * dbus/dbus-errors.h:
5090 Add DBusError structure.
5092 2003-02-13 Anders Carlsson <andersca@codefactory.se>
5094 * test/data/valid-messages/standard-acquire-service.message:
5095 * test/data/valid-messages/standard-hello.message:
5096 * test/data/valid-messages/standard-list-services.message:
5097 * test/data/valid-messages/standard-service-exists.message:
5098 Add some standard messages.
5100 2003-02-13 Anders Carlsson <andersca@codefactory.se>
5102 * bus/driver.c: (bus_driver_send_welcome_message),
5103 (bus_driver_handle_list_services),
5104 (bus_driver_handle_acquire_service),
5105 (bus_driver_handle_service_exists), (bus_driver_handle_message):
5106 Update for API changes in libdbus.
5108 * dbus/dbus-message.c: (dbus_message_new_reply):
5109 * dbus/dbus-message.h:
5110 Remove the name argument. The spec states that replies shouldn't
5113 2003-02-13 Anders Carlsson <andersca@codefactory.se>
5115 * bus/desktop-file.c: (parse_section_start), (parse_key_value),
5116 (report_error), (bus_desktop_file_load), (lookup_section),
5117 (lookup_line), (bus_desktop_file_get_raw),
5118 (bus_desktop_file_get_string):
5119 * bus/desktop-file.h:
5120 Some fixes, and new functions for getting a key value from a section.
5122 2003-02-13 Havoc Pennington <hp@pobox.com>
5124 * test/data/auth/fail-after-n-attempts.auth-script: new test
5126 * dbus/dbus-auth.c (send_rejected): shutdown_mech() when we
5129 2003-02-13 Havoc Pennington <hp@pobox.com>
5131 * dbus/dbus-auth.c (handle_server_data_external_mech): args to
5132 dbus_credentials_match were backward
5134 * dbus/dbus-auth-script.c (_dbus_auth_script_run): support
5135 NO_CREDENTIALS and ROOT_CREDENTIALS
5137 * dbus/dbus-auth.c (_dbus_auth_do_work): move get_state() routine
5138 into here. Never process more commands after we've reached an
5139 end state; store further data as unused bytes.
5141 * test/data/auth/*: add more auth tests
5143 * dbus/dbus-auth-script.c (_dbus_auth_script_run): support EXPECT
5144 command to match exact string and EXPECT_UNUSED to match unused
5147 * test/Makefile.am (dist-hook): fix to dist all the test stuff
5149 2003-02-12 Havoc Pennington <hp@pobox.com>
5151 * dbus/dbus-string.c (_dbus_string_pop_line): fix to also strip
5152 \r off of popped lines
5154 * dbus/dbus-auth.c (_dbus_auth_test): write code to run auth
5157 * dbus/dbus-auth-script.c (_dbus_auth_script_run): when doing a
5160 2003-02-12 Havoc Pennington <hp@pobox.com>
5162 * dbus/Makefile.am: remove break-loader from the build, since it
5165 * configure.in: add --enable-gcov to turn on coverage profiling
5166 flags and disable optimization
5168 2003-02-10 Havoc Pennington <hp@pobox.com>
5170 * dbus/dbus-auth-script.c, dbus/dbus-auth-script.h: sync
5171 initial cut at test framework for DBusAuth from laptop.
5172 Doesn't quite work yet but it compiles and I need to get
5173 it off the 266mhz laptop. ;-)
5175 * dbus/dbus-server-debug.c (_dbus_server_debug_accept_transport):
5176 fix a memleak in error case
5178 2003-02-12 Anders Carlsson <andersca@codefactory.se>
5181 * bus/desktop-file.c:
5182 * bus/desktop-file.h:
5183 Add a desktop file parser.
5185 2003-02-11 Zack Rusin <zack@kde.org>
5187 * qt/message.[h|cpp]: sample implementation
5188 of the KDE wrapper for DBusMessage
5190 2003-02-09 Zack Rusin <zack@kde.org>
5192 * test/bus-test.c: make_it_compile
5193 * doc/dbus-specification.sgml: minimal semantic fix
5195 2003-02-06 Anders Carlsson <andersca@codefactory.se>
5201 2003-02-06 Anders Carlsson <andersca@codefactory.se>
5204 * dbus/dbus-break-loader.c:
5206 * test/break-loader.c:
5207 Move dbus-break-loader to test/ and rename it to break-loader.
5209 2003-02-02 Havoc Pennington <hp@pobox.com>
5211 * dbus/dbus-keyring.c, dbus/dbus-keyring.h: template files
5212 for code to manage cookies in your home directory
5214 * dbus/dbus-sysdeps.c (_dbus_generate_random_bytes): new function
5216 * dbus/dbus-auth.c (get_state): impose a maximum number of tries
5217 to authenticate, then disconnect the client.
5219 2003-02-03 Alexander Larsson <alexl@redhat.com>
5221 * dbus/dbus-message.c (dbus_message_append_fields):
5224 2003-02-02 Anders Carlsson <andersca@codefactory.se>
5226 * doc/dbus-specification.sgml:
5227 Update address format section.
5229 2003-02-02 Anders Carlsson <andersca@codefactory.se>
5232 * test/bus-test.c: (get_time), (add_timeout), (remove_timeout),
5233 (message_handler), (new_connection_callback), (loop_quit),
5237 2003-02-02 Anders Carlsson <andersca@codefactory.se>
5239 * bus/driver.c: (bus_driver_handle_service_exists):
5240 Simplify the code a bit.
5242 * dbus/dbus-bus.c: (dbus_bus_service_exists):
5245 2003-02-02 Anders Carlsson <andersca@codefactory.se>
5248 Add libdbus-daemon.la and link to it.
5250 2003-02-01 James Willcox <jwillcox@gnome.org>
5252 * bus/driver.c: (bus_driver_handle_own_service):
5253 Actually include the service reply code in the message.
5255 2003-02-02 Anders Carlsson <andersca@codefactory.se>
5257 * bus/driver.c: (bus_driver_handle_service_exists):
5258 Don't unref the incoming message.
5260 2003-02-02 Anders Carlsson <andersca@codefactory.se>
5262 * dbus/dbus.h: Add dbus-address.h and dbus-bus.h
5264 2003-02-02 Anders Carlsson <andersca@codefactory.se>
5266 * dbus/dbus-server.c: (dbus_server_listen):
5267 * dbus/dbus-transport.c: (_dbus_transport_open):
5268 ifdef out the calls to the debug transport and server.
5270 2003-02-02 Alexander Larsson <alexl@redhat.com>
5272 * dbus/dbus-watch.c (dbus_watch_get_flags):
5273 Add note in the docs that ERROR or HANGUP won't be returned
5274 and are assumed always on.
5276 * glib/dbus-gmain.c (add_watch):
5277 Always add IO_ERR | IO_HUP
5279 * dbus/dbus-message.h:
5280 Add semicolon after dbus_message_iter_get_string_array().
5281 Makes qt code build again
5283 2003-02-01 Anders Carlsson <andersca@codefactory.se>
5285 * bus/driver.c: (create_unique_client_name),
5286 (bus_driver_handle_hello):
5287 Don't take a name, just use a numeric id to identify
5291 * dbus/dbus-bus.c: (dbus_bus_register_client),
5292 (dbus_bus_acquire_service), (dbus_bus_service_exists):
5294 Add new convenience functions for communicating with the bus.
5296 * dbus/dbus-message.h:
5298 * dbus/dbus-protocol.h:
5301 2003-02-01 Alexander Larsson <alexl@redhat.com>
5303 * dbus/dbus-message.c (dbus_message_append_fields):
5304 Add some more doc comments.
5306 2003-02-01 Havoc Pennington <hp@pobox.com>
5308 * dbus/dbus-break-loader.c (randomly_modify_length): change
5309 a 4-byte value in the message as if it were a length
5311 * dbus/dbus-sysdeps.c (_dbus_string_save_to_file): don't set
5312 execute bit on saved files
5314 2003-02-01 Havoc Pennington <hp@pobox.com>
5316 * dbus/dbus-break-loader.c (main): new program to find messages
5317 that break the loader.
5319 * dbus/dbus-sysdeps.c (_dbus_string_append_uint): new function
5320 * dbus/dbus-sysdeps.c (_dbus_string_save_to_file): new function
5322 * dbus/dbus-string.c (_dbus_string_set_byte): new
5324 2003-01-31 Havoc Pennington <hp@pobox.com>
5326 * dbus/dbus-message.c: refactor the test code to be more general,
5327 in preparation for writing a "randomly permute test cases to
5328 try to break the loader" program.
5330 2003-01-31 Havoc Pennington <hp@pobox.com>
5332 * doc/dbus-specification.sgml: work on the specification
5334 * dbus/dbus-message.c (_dbus_message_loader_return_buffer): check
5335 the protocol version of the message.
5337 * dbus/dbus-protocol.h: drop special _REPLY names, the spec
5338 no longer specifies that.
5339 (DBUS_SERVICE_REPLY_SERVICE_EXISTS): fix flags (1/2/4/8 not
5342 * dbus/dbus-marshal.c (_dbus_marshal_get_arg_end_pos): add missing
5343 "break" for DBUS_TYPE_NIL, remove @todo
5345 2003-01-31 Havoc Pennington <hp@pobox.com>
5347 * dbus/dbus-message.c (dbus_message_set_is_error_reply): rename
5348 just set_is_error/get_is_error as this is a commonly-used
5349 function, and write docs.
5351 2003-01-31 Anders Carlsson <andersca@codefactory.se>
5353 * dbus/dbus-address.c: (dbus_address_entry_free):
5354 Free key and value lists.
5356 * dbus/dbus-internals.c: (_dbus_type_to_string):
5357 Add the types we didn't have.
5359 * dbus/dbus-marshal.c: (_dbus_marshal_get_arg_end_pos),
5360 (_dbus_marshal_validate_arg):
5363 * dbus/dbus-message.c: (dbus_message_set_sender):
5364 Remove todo about being able to set sender to NULL.
5366 (dbus_message_set_is_error_reply),
5367 (dbus_message_get_is_error_reply):
5368 * dbus/dbus-message.h:
5371 * dbus/dbus-protocol.h:
5372 Add error reply flag.
5374 * test/data/valid-messages/opposite-endian.message:
5375 Add NIL type to test.
5377 2003-01-31 Havoc Pennington <hp@pobox.com>
5379 * doc/dbus-specification.sgml: fully specify the header. Add
5380 flags and major protocol version, and change header/body len to
5383 * dbus/dbus-message-builder.c (append_saved_length): append length
5386 * dbus/dbus-message.c (dbus_message_create_header): change header
5387 length and body length to unsigned. Add the new fields from the
5389 (_dbus_message_loader_return_buffer): unsigned header/body len
5391 2003-01-30 Havoc Pennington <hp@pobox.com>
5393 * dbus/dbus-auth.c: rework to use only REJECTED, no
5396 * doc/dbus-sasl-profile.txt: drop MECHANISMS and just
5397 use REJECTED, suggested by Mark McLoughlin
5399 2003-01-30 Havoc Pennington <hp@pobox.com>
5401 * dbus/dbus-server.c (dbus_server_listen): @todo about how we need
5402 a better way to report errors here. e.g. "unix address lacks
5403 path" or something. also "no such file" when the path doesn't
5406 * dbus/dbus-address.c (dbus_address_entries_free): add @todo about
5408 (dbus_parse_address): add @todo about documenting address format,
5409 and allowing , and ; to be escaped
5411 2003-01-30 Anders Carlsson <andersca@codefactory.se>
5414 Add dbus-address.[ch]
5416 * dbus/dbus-address.c: (dbus_address_entry_free),
5417 (dbus_address_entries_free), (create_entry),
5418 (dbus_address_entry_get_method), (dbus_address_entry_get_value),
5419 (dbus_parse_address), (_dbus_address_test):
5420 * dbus/dbus-address.h:
5421 New files for dealing with address parsing.
5423 * dbus/dbus-connection.c:
5424 Document timeout functions.
5426 * dbus/dbus-message.c:
5427 Document dbus_message_new_from_message.
5429 * dbus/dbus-server-debug.c:
5432 * dbus/dbus-server.c: (dbus_server_listen):
5433 Parse address and use correct server implementation.
5435 * dbus/dbus-string.c: (_dbus_string_find_to), (_dbus_string_test):
5436 * dbus/dbus-string.h:
5437 New function with test.
5439 * dbus/dbus-test.c: (dbus_internal_symbol_do_not_use_run_tests):
5443 * dbus/dbus-transport-debug.c:
5446 * dbus/dbus-transport.c: (_dbus_transport_open):
5447 Parse address and use correct transport implementation.
5449 2003-01-30 Havoc Pennington <hp@pobox.com>
5451 * dbus/dbus-message.c: use message->byte_order instead of
5452 DBUS_COMPILER_BYTE_ORDER throughout.
5453 (dbus_message_create_header): pad header to align the
5454 start of the body of the message to 8-byte boundary
5456 * dbus/dbus-marshal.h: make all the demarshalers take const
5457 DBusString arguments.
5459 * dbus/dbus-message.c (_dbus_message_loader_return_buffer):
5460 validate message args here, so we don't have to do slow validation
5461 later, and so we catch bad messages as they are incoming. Also add
5462 better checks on header_len and body_len. Also fill in
5465 * dbus/dbus-string.c (_dbus_string_validate_utf8): new (not
5466 implemented properly)
5467 (_dbus_string_validate_nul): new function to check all-nul
5469 * dbus/dbus-marshal.c (_dbus_marshal_get_field_end_pos): rename
5470 get_arg_end_pos and remove all validation
5471 (_dbus_marshal_validate_arg): actually do validation here.
5473 2003-01-29 Havoc Pennington <hp@pobox.com>
5475 * dbus/dbus-message.c (check_message_handling): fix assertion
5476 failure on set_client_serial
5478 2003-01-28 Havoc Pennington <hp@pobox.com>
5480 * dbus/dbus-server-debug.c: Add doc section comments
5482 * dbus/dbus-transport-debug.c: add doc section comments
5484 2003-01-28 Havoc Pennington <hp@redhat.com>
5486 * dbus/dbus-string.c (_dbus_string_base64_decode): append bytes in
5487 the reverse order from how I had it
5488 (_dbus_string_base64_encode): reverse encoding order. I was
5489 basically byteswapping everything during encoding.
5491 2003-01-28 Anders Carlsson <andersca@codefactory.se>
5493 * dbus/dbus-connection-internal.h:
5494 * dbus/dbus-connection.c: (_dbus_connection_add_timeout),
5495 (_dbus_connection_remove_timeout):
5496 Add functions for adding and removing timeouts.
5498 * dbus/dbus-message.c: (dbus_message_new_from_message):
5499 Add new function that takes a message and creates an exact
5500 copy of it, but with the refcount set to 1.
5501 (check_message_handling):
5504 * dbus/dbus-server-protected.h:
5505 * dbus/dbus-server.c: (_dbus_server_init_base),
5506 (_dbus_server_finalize_base), (_dbus_server_add_timeout),
5507 (dbus_server_set_timeout_functions):
5508 (_dbus_server_remove_timeout):
5509 New functions so that a server can add and remove timeouts.
5511 (dbus_server_listen):
5512 Add commented out call to dbus_server_debug_new.
5514 * dbus/dbus-timeout.c: (_dbus_timeout_new):
5515 Actually set the handler, doh.
5517 * dbus/dbus-transport.c: (_dbus_transport_open):
5518 Add commented out call to dbus_transport_debug_client_new.
5521 Add dbus-transport-debug.[ch] and dbus-server-debug.[ch]
5523 2003-01-28 Havoc Pennington <hp@pobox.com>
5525 * dbus/dbus-message.c (check_message_handling): function to check
5526 on the loaded message, iterates over it etc.
5528 2003-01-28 Havoc Pennington <hp@pobox.com>
5530 * test/Makefile.am (dist-hook): fix make distdir
5532 * dbus/Makefile.am (TESTS_ENVIRONMENT): fix make check
5534 2003-01-27 Havoc Pennington <hp@pobox.com>
5536 * dbus/dbus-mempool.c (time_for_size): replace printf with
5539 * dbus/dbus-message-builder.c (_dbus_message_data_load): allow
5540 empty lines; fix the SAVE_LENGTH stuff to be
5541 START_LENGTH/END_LENGTH so it actually works; couple other
5544 * test/Makefile.am (dist-hook): add dist-hook for .message files
5546 * dbus/dbus-string.c (DBUS_STRING_COPY_PREAMBLE): source of a copy
5547 can be constant or locked.
5548 (_dbus_string_free): allow freeing a const string as
5551 * dbus/dbus-sysdeps.c (_dbus_concat_dir_and_file): utility
5553 * dbus/dbus-test-main.c (main): take an argument which is the
5554 directory containing test data
5556 * dbus/dbus-message.c (_dbus_message_test): pass a test_data_dir
5557 argument to this and load all the messages in test/data/
5558 checking that they can be loaded or not loaded as appropriate.
5560 2003-01-27 Anders Carlsson <andersca@codefactory.se>
5562 * bus/dispatch.c: (bus_dispatch_message_handler):
5563 Dispatch messages sent to services.
5565 * bus/driver.c: (bus_driver_send_service_deleted),
5566 (bus_driver_send_service_created), (bus_driver_send_service_lost),
5567 (bus_driver_send_service_acquired):
5568 Add helper functions for sending service related messages.
5570 (bus_driver_send_welcome_message):
5571 Send HELLO_REPLY instead of WELCOME.
5573 (bus_driver_handle_list_services):
5574 Send LIST_SERVICES_REPLY instead of SERVICES.
5576 (bus_driver_handle_own_service),
5577 (bus_driver_handle_service_exists):
5578 New message handlers.
5580 (bus_driver_handle_message):
5581 Invoke new message handlers.
5583 (bus_driver_remove_connection):
5584 Don't remove any services here since that's done automatically
5585 by bus_service_remove_owner now.
5588 New function signatures.
5590 * bus/services.c: (bus_service_add_owner):
5591 Send ServiceAcquired message if we're the only primary owner.
5593 (bus_service_remove_owner):
5594 Send ServiceAcquired/ServiceLost messages.
5596 (bus_service_set_prohibit_replacement),
5597 (bus_service_get_prohibit_replacement):
5598 Functions for setting prohibit replacement.
5600 (bus_service_has_owner):
5601 New function that checks if a connection is in the owner queue of
5605 Add new function signatures.
5607 * dbus/dbus-list.c: (_dbus_list_test):
5608 Add tests for _dbus_list_remove_last and traversing the list backwards.
5611 Fix a typo in _dbus_list_get_prev_link, if we're at the first element we can't
5612 go any further, so return NULL then.
5614 * dbus/dbus-protocol.h:
5615 Add new messages, service flags and service replies.
5617 2003-01-26 Havoc Pennington <hp@pobox.com>
5619 * dbus/dbus-message-builder.c: implement, completely untested.
5621 * test/data/*: add data to be used in testing.
5622 ".message" files are our simple loadable text format.
5623 ".message-raw" will be binary dumps of messages.
5625 * dbus/dbus-string.c (_dbus_string_starts_with_c_str): new
5627 2003-01-26 Havoc Pennington <hp@pobox.com>
5629 * dbus/dbus-sysdeps.c (_dbus_file_get_contents): new function
5631 * dbus/dbus-errors.c (dbus_result_to_string): add
5634 * dbus/dbus-message-builder.c: new file, will contain code to load
5635 up messages from files. Not implemented yet.
5637 2003-01-26 Havoc Pennington <hp@pobox.com>
5639 * dbus/dbus-message.c (dbus_message_set_sender): support deleting
5640 the sender by setting to NULL
5642 2003-01-26 Havoc Pennington <hp@pobox.com>
5644 The unit tests pass, but otherwise untested. If it breaks, the
5645 tests should have been better. ;-)
5647 * bus/driver.c (bus_driver_handle_hello): return if we disconnect
5650 * dbus/dbus-message.c: redo everything so we maintain
5651 message->header as the only copy of the various fields.
5652 This avoids the possibility of out-of-memory in some cases,
5653 for example dbus_message_lock() can't run out of memory anymore,
5654 and avoids extra copying. Figured I may as well go ahead and do
5655 this since it was busted for dbus_message_lock to not return
5656 failure on OOM, and dbus_message_write_header was totally
5657 unchecked for OOM. Also fixed some random other bugs.
5659 * dbus/dbus-marshal.c (_dbus_marshal_get_field_end_pos): verify
5660 that strings are nul-terminated. Also, end_pos can be equal
5661 to string length just not greater than, I think.
5662 (_dbus_marshal_set_int32): new function
5663 (_dbus_marshal_set_uint32): new function
5664 (_dbus_marshal_set_string): new function
5666 * dbus/dbus-connection.c (_dbus_connection_new_for_transport): fix
5667 a warning, init timeout_list to NULL
5668 (dbus_connection_send_message): don't use uninitialized variable
5671 * dbus/dbus-string.c (_dbus_string_replace_len): new function
5673 2003-01-26 Anders Carlsson <andersca@codefactory.se>
5675 * bus/driver.c: (bus_driver_handle_hello),
5676 (bus_driver_send_welcome_message):
5679 2003-01-26 Anders Carlsson <andersca@codefactory.se>
5681 * dbus/dbus-auth.c: (process_auth), (_dbus_auth_unref):
5682 * dbus/dbus-connection.c: (_dbus_connection_new_for_transport),
5683 (dbus_connection_unref):
5684 * dbus/dbus-marshal.c: (_dbus_marshal_test):
5685 * dbus/dbus-message.c: (dbus_message_unref),
5688 (dbus_message_get_fields):
5689 Remove debugging printout.
5691 (_dbus_message_loader_return_buffer):
5692 Don't store the header string.
5694 (_dbus_message_test):
5697 2003-01-26 Richard Hult <rhult@codefactory.se>
5699 * glib/dbus-gmain.c (dbus_connection_dispatch): Traverse a copy of
5700 the file descriptor list, since it can change under us.
5702 2003-01-25 Anders Carlsson <andersca@codefactory.se>
5704 * glib/dbus-gmain.c: (dbus_connection_prepare),
5705 (dbus_connection_check), (dbus_connection_dispatch), (add_watch),
5706 (remove_watch), (dbus_connection_hookup_with_g_main):
5707 Rewrite the glib handling to use its own GSource instead of a
5708 GIOChannel so we can catch messages put in the queue while waiting
5711 2003-01-25 Anders Carlsson <andersca@codefactory.se>
5714 * bus/connection.c: (connection_disconnect_handler),
5715 (connection_watch_callback), (bus_connection_setup):
5716 * bus/dispatch.c: (send_one_message),
5717 (bus_dispatch_broadcast_message), (bus_dispatch_message_handler),
5718 (bus_dispatch_add_connection), (bus_dispatch_remove_connection):
5720 * bus/driver.c: (bus_driver_send_service_deleted),
5721 (bus_driver_send_service_created), (bus_driver_handle_hello),
5722 (bus_driver_send_welcome_message),
5723 (bus_driver_handle_list_services), (bus_driver_remove_connection),
5724 (bus_driver_handle_message):
5726 Refactor code, put the message dispatching in its own file. Use
5727 _DBUS_HANDLE_OOM. Also send ServiceDeleted messages when a client
5730 2003-01-25 Anders Carlsson <andersca@codefactory.se>
5732 * dbus/dbus-internals.h:
5733 Add _DBUS_HANDLE_OOM macro, it doesn't do anything currently.
5735 * dbus/dbus-message.c: (dbus_message_get_sender):
5736 * dbus/dbus-message.h:
5737 Implement dbus_message_get_sender.
5739 * dbus/dbus-protocol.h:
5740 Add message and service defines.
5742 2003-01-25 Anders Carlsson <andersca@codefactory.se>
5744 * dbus/dbus-connection.c: (dbus_connection_send_message):
5745 * dbus/dbus-message-internal.h:
5746 * dbus/dbus-message.c: (_dbus_message_get_client_serial),
5747 (dbus_message_write_header):
5748 Remove _dbus_messag_unlock and don't set the client serial on a
5749 message if one already exists.
5751 2003-01-24 Havoc Pennington <hp@pobox.com>
5753 * dbus/dbus-list.c (alloc_link): put a thread lock on the global
5756 * bus/driver.c (bus_driver_handle_list_services): fix a leak
5759 2003-01-25 Anders Carlsson <andersca@codefactory.se>
5761 * dbus/dbus-list.c: (alloc_link), (free_link):
5762 Use a memory pool for the links.
5764 2003-01-25 Anders Carlsson <andersca@codefactory.se>
5766 * bus/connection.c: (bus_connection_foreach):
5768 Add new bus_connection_foreach function.
5770 * bus/driver.c: (send_one_message), (bus_driver_broadcast_message):
5771 Add function that broadcasts a message to all clients.
5773 (bus_driver_send_service_created), (bus_driver_handle_hello),
5774 (bus_driver_send_welcome_message),
5775 (bus_driver_handle_list_services), (bus_driver_message_handler):
5776 Implement functions that take care of listing services, and notifying
5777 clients when new services are created.
5779 * bus/services.c: (bus_services_list):
5781 Add new function that returns an array of strings with the currently
5782 registered services.
5785 * glib/dbus-gmain.c:
5786 Update copyright year.
5788 2003-01-25 Anders Carlsson <andersca@codefactory.se>
5790 * dbus/dbus-connection.c: (dbus_connection_send_message):
5791 Unlock the message in case it was sent earlier.
5793 (dbus_connection_send_message_with_reply_and_block):
5794 Remove the reply message from the list.
5796 * dbus/dbus-marshal.c: (_dbus_demarshal_string_array):
5797 Set array_len and new_pos correctly.
5799 (_dbus_marshal_test):
5800 Remove debug output.
5802 * dbus/dbus-message-internal.h:
5803 * dbus/dbus-message.c: (_dbus_message_get_reply_serial):
5804 New function that returns the reply serial.
5806 (_dbus_message_unlock):
5807 New function that unlocks a message and resets its header.
5809 (dbus_message_append_string_array),
5810 (dbus_message_get_fields_valist),
5811 (dbus_message_iter_get_field_type),
5812 (dbus_message_iter_get_string_array),
5813 (dbus_message_get_fields),
5814 (dbus_message_append_fields_valist):
5815 Handle string arrays.
5817 (dbus_message_set_sender):
5818 Make this function public since the bus daemon needs it.
5820 (decode_header_data):
5821 Set the reply serial to -1 initially.
5823 * dbus/dbus-message.h:
5824 Add dbus_message_set_sender.
5826 2003-01-24 Havoc Pennington <hp@pobox.com>
5828 * doc/dbus-specification.sgml: add some stuff
5830 2003-01-22 Havoc Pennington <hp@pobox.com>
5832 * doc/dbus-specification.sgml: Start to document the protocol.
5834 2003-01-22 Havoc Pennington <hp@pobox.com>
5836 * dbus/dbus-connection.c
5837 (dbus_connection_send_message_with_reply_and_block): add some @todo
5839 * bus/driver.c (bus_driver_add_connection): add a FIXME about memleak
5841 2003-01-21 Havoc Pennington <hp@pobox.com>
5843 (patch untested because can't compile)
5845 * bus/driver.c (create_unique_client_name): make this function
5846 never recycle client names. Also, caller should initialize
5849 * dbus/dbus-sysdeps.c (_dbus_get_current_time): new function
5851 2003-01-21 Anders Carlsson <andersca@codefactory.se>
5853 * dbus/dbus-marshal.c: (_dbus_marshal_double),
5854 (_dbus_marshal_int32), (_dbus_marshal_uint32),
5855 (_dbus_marshal_int32_array), (_dbus_marshal_uint32_array),
5856 (_dbus_marshal_double_array), (_dbus_marshal_string_array),
5857 (_dbus_demarshal_int32_array), (_dbus_demarshal_uint32_array),
5858 (_dbus_demarshal_double_array), (_dbus_demarshal_string_array),
5859 (_dbus_marshal_get_field_end_pos), (_dbus_marshal_test):
5860 * dbus/dbus-marshal.h:
5861 * dbus/dbus-protocol.h:
5862 Add support for marshalling and demarshalling integer, double
5865 2003-01-21 Anders Carlsson <andersca@codefactory.se>
5870 * bus/connection.c: (connection_disconnect_handler):
5871 Remove the connection from the bus driver's list.
5873 (connection_watch_callback): Dispatch messages.
5875 (free_connection_data): Free connection name.
5877 (bus_connection_setup): Add connection to the bus driver's list.
5878 (bus_connection_remove_owned_service):
5879 (bus_connection_set_name), (bus_connection_get_name):
5880 Add functions for setting and getting the connection's name.
5883 Add function headers.
5885 * bus/driver.c: (create_unique_client_name),
5886 (bus_driver_handle_hello_message),
5887 (bus_driver_send_welcome_message), (bus_driver_message_handler),
5888 (bus_driver_add_connection), (bus_driver_remove_connection):
5891 * bus/services.c: (bus_service_free):
5893 New file that handles communication and registreation with the bus
5896 2003-01-21 Anders Carlsson <andersca@codefactory.se>
5898 * dbus/dbus-connection.c: (dbus_connection_send_message):
5899 Add a new client_serial parameter.
5901 (dbus_connection_send_message_with_reply):
5902 Remove a @todo since we've implemented the blocking function.
5904 (dbus_connection_send_message_with_reply_and_block):
5905 New function that sends a message and waits for a reply and
5906 then returns the reply.
5908 * dbus/dbus-connection.h:
5911 * dbus/dbus-errors.c: (dbus_result_to_string):
5912 * dbus/dbus-errors.h:
5913 Add new DBUS_RESULT.
5915 * dbus/dbus-message-internal.h:
5916 * dbus/dbus-message.c: (_dbus_message_get_reply_serial),
5917 (_dbus_message_set_sender), (dbus_message_write_header),
5918 (dbus_message_new_reply), (decode_header_data),
5919 (_dbus_message_loader_return_buffer), (_dbus_message_test):
5920 * dbus/dbus-message.h:
5921 Add new functions that set the reply serial and sender.
5922 Also marshal and demarshal them correctly and add test.
5924 * dbus/dbus-protocol.h:
5925 Add new DBUS_MESSAGE_TYPE_SENDER.
5928 * glib/dbus-gmain.c: (watch_callback), (free_callback_data),
5929 (add_watch), (remove_watch), (add_timeout), (remove_timeout),
5930 (dbus_connection_hookup_with_g_main):
5931 * glib/test-dbus-glib.c: (main):
5932 Rewrite to use GIOChannel and remove the GSource crack.
5934 * test/echo-client.c: (main):
5935 * test/watch.c: (check_messages):
5936 Update for changed APIs
5938 2003-01-19 Anders Carlsson <andersca@codefactory.se>
5940 * dbus/Makefile.am: Add dbus-timeout.[cħ]
5942 * dbus/dbus-connection.c: (_dbus_connection_new_for_transport):
5943 Create a DBusTimeoutList.
5944 (dbus_connection_set_timeout_functions): Add new function to
5945 set timeout callbacks
5947 * dbus/dbus-connection.h: Add public DBusTimeout API.
5949 * dbus/dbus-message.c: (dbus_message_get_service):
5950 * dbus/dbus-message.h: New function.
5952 * dbus/dbus-server.c: Fix small doc typo.
5954 * dbus/dbus-timeout.[ch]: New files for mainloop timeouts.
5956 2003-01-19 Anders Carlsson <andersca@codefactory.se>
5958 * dbus/dbus-string.c (_dbus_string_move_len): Don't delete all
5959 of the string, just as long as specified.
5961 2003-01-19 Havoc Pennington <hp@pobox.com>
5963 * dbus/dbus-connection.c (dbus_connection_get_is_authenticated):
5966 * dbus/dbus-server.c (dbus_server_set_max_connections)
5967 (dbus_server_get_max_connections, dbus_server_get_n_connections):
5968 keep track of current number of connections, and add API for
5969 setting a max (but haven't implemented enforcing the max yet)
5971 2003-01-18 Havoc Pennington <hp@pobox.com>
5973 * dbus/dbus-transport-unix.c (unix_do_iteration): only do the
5974 reading/writing if read_watch != NULL or write_watch != NULL.
5976 * dbus/dbus-message.c (_dbus_message_loader_return_buffer): fix
5977 the message loader code to actually load message->header and
5978 message->body into the newly-created message.
5980 * dbus/dbus-transport-unix.c (check_write_watch): fix a mem leak
5983 * dbus/dbus-connection.c (dbus_connection_set_max_message_size)
5984 (dbus_connection_get_max_message_size)
5985 (dbus_connection_set_max_live_messages_size)
5986 (dbus_connection_get_max_live_messages_size): implement some
5987 resource limitation functions
5989 * dbus/dbus-resources.c: new file implementing some of the
5990 resource limits stuff
5992 * dbus/dbus-message.c (dbus_message_iter_get_byte_array): add
5993 missing docs, add @todo to handle OOM etc.
5995 * dbus/dbus-marshal.c (_dbus_demarshal_byte_array): add missing
5998 2003-01-18 Havoc Pennington <hp@pobox.com>
6000 * dbus/dbus-connection.c (dbus_connection_unref): disconnect the
6001 connection if it hasn't been already.
6003 * dbus/dbus-connection.h: kill off the idea of an ErrorFunction,
6004 replace with DisconnectFunction.
6006 2003-01-18 Havoc Pennington <hp@pobox.com>
6008 Building --disable-verbose-mode --disable-asserts --disable-tests
6009 cuts the library from 112K to 45K or so
6011 * configure.in: check for varargs macro support,
6012 add --enable-verbose-mode, --enable-asserts.
6014 * dbus/dbus-internals.h (_dbus_assert): support
6016 (_dbus_verbose): support DBUS_ENABLE_VERBOSE_MODE
6018 2003-01-18 Havoc Pennington <hp@pobox.com>
6020 * dbus/dbus-test.c: include config.h so that tests actually run
6022 * dbus/dbus-string.c: add assertions that stuff is 8-byte aligned,
6023 so the failure mode when that assumption fails will be plenty
6026 2003-01-18 Havoc Pennington <hp@pobox.com>
6028 * configure.in: default --enable-tests to $USE_MAINTAINER_MODE
6030 * dbus/Makefile.am: fix it up so dubs-test-main.c is included in
6033 * test/Makefile.am: don't use special variable "TESTS" for echo-*
6034 since we don't want to use those in make check
6036 2003-01-15 Havoc Pennington <hp@redhat.com>
6042 2003-01-15 Havoc Pennington <hp@redhat.com>
6044 * test/Makefile.am: fix so that test source code ends up in the
6045 distribution on make distcheck
6047 2003-01-15 Havoc Pennington <hp@redhat.com>
6053 2003-01-15 Havoc Pennington <hp@redhat.com>
6055 * dbus/dbus-test.c (dbus_internal_symbol_do_not_use_run_tests):
6056 fix build when --disable-tests
6058 * Makefile.am (EXTRA_DIST): put HACKING in here
6060 * HACKING: document procedure for making a tarball release.
6062 2003-01-14 Anders Carlsson <andersca@codefactory.se>
6064 * bus/connection.c: (connection_error_handler),
6065 (bus_connection_setup):
6066 * bus/main.c: (main):
6067 Make sure that the DBusConnectionData struct is NULLed
6068 out to prevent a segfault.
6070 * dbus/dbus-errors.c: (dbus_result_to_string):
6071 * dbus/dbus-errors.h:
6072 * dbus/dbus-message.c: (dbus_message_get_fields),
6073 (dbus_message_get_fields_valist), (_dbus_message_test):
6074 * dbus/dbus-message.h:
6075 Make dbus_message_get_fields return a result code so we can
6076 track invalid fields as well as oom.
6078 2003-01-11 Havoc Pennington <hp@pobox.com>
6080 * configure.in: change --enable-test/--enable-ansi action-if-given
6081 to enable_foo=$enableval instead of enable_foo=yes
6083 2003-01-08 Havoc Pennington <hp@pobox.com>
6085 * dbus/dbus-string.c (_dbus_string_align_length): new function
6087 * dbus/dbus-test-main.c: move main() for test app here
6089 (dbus_internal_symbol_do_not_use_run_tests): we have to export a
6090 symbol to run tests, because dbus-test isn't in the main
6093 Code review nitpicks.
6095 * dbus/dbus-message.c (dbus_message_write_header): add newlines
6096 for people with narrow emacs ;-). Assert client_serial was filled
6097 in. Assert message->name != NULL.
6098 (dbus_message_append_fields): have "first_field_type" arg separate
6099 from va list, needed for C++ binding that also uses varargs IIRC
6100 and helps with type safety
6101 (dbus_message_new): add @todo about using DBusString to store
6102 service/name internally
6103 (dbus_message_new): don't leak ->service and ->name on OOM later
6105 (dbus_message_unref): free the service name
6106 (dbus_message_get_fields): same change to varargs
6107 i.e. first_field_type
6108 (_dbus_message_loader_return_buffer): assert that the message data
6109 is aligned (if not it's a bug in our code). Put in verbose griping
6110 about why we set corrupted = TRUE.
6111 (decode_header_data): add FIXME that char* is evil. Was going to
6112 add FIXME about evil locale-specific string.h strncmp, but just
6113 switched to wacky string-as-uint32 optimization. Move check for
6114 "no room for field name" above get_const_data_len() to avoid
6115 assertion failure in get_const_data_len if we have trailing 2
6116 bytes or the like. Check for service and name fields being
6117 provided twice. Don't leak service/name on error. Require field
6118 names to be aligned to 4 bytes.
6120 * dbus/dbus-marshal.c: move byte swap stuff to header
6121 (_dbus_pack_int32): uscore-prefix
6122 (_dbus_unpack_int32): uscore-prefix
6123 (_dbus_unpack_uint32): export
6124 (_dbus_demarshal_string): add @todo complaining about use of
6126 (_dbus_marshal_get_field_end_pos): add @todo about bad error
6127 handling allowing corrupt data to go unchecked
6129 2003-01-08 Havoc Pennington <hp@redhat.com>
6131 * dbus/dbus-transport-unix.c (unix_do_iteration): add read/write
6132 to the select() as needed for authentication. (should be using
6133 _dbus_poll() not select, but for another day)
6135 * dbus/dbus.h: include dbus/dbus-protocol.h
6137 2003-01-08 Anders Carlsson <andersca@codefactory.se>
6139 * dbus/Makefile.am (dbusinclude_HEADERS): Install
6142 2003-01-08 Anders Carlsson <andersca@codefactory.se>
6144 * dbus/dbus-internals.c: (_dbus_type_to_string):
6145 New function that returns a string describing a type.
6147 * dbus/dbus-marshal.c: (_dbus_demarshal_byte_array):
6148 * dbus/dbus-marshal.h:
6149 * dbus/dbus-message.c: (dbus_message_get_fields_valist),
6150 (dbus_message_iter_get_field_type), (dbus_message_iter_get_double),
6151 (dbus_message_iter_get_byte_array):
6152 * dbus/dbus-message.h:
6153 Add new convenience functions for appending and getting message fields.
6154 Also add demarshalling routines for byte arrays.
6156 2003-01-07 Anders Carlsson <andersca@codefactory.se>
6158 * dbus/dbus-connection-internal.h:
6159 * dbus/dbus-connection.c: (_dbus_connection_new_for_transport),
6160 (_dbus_connection_get_next_client_serial),
6161 (dbus_connection_send_message):
6162 * dbus/dbus-internals.h:
6163 * dbus/dbus-marshal.c: (unpack_uint32), (dbus_unpack_int32),
6164 (dbus_pack_int32), (_dbus_marshal_double), (_dbus_marshal_int32),
6165 (_dbus_marshal_uint32), (_dbus_demarshal_double),
6166 (_dbus_demarshal_int32), (_dbus_demarshal_uint32),
6167 (_dbus_demarshal_string), (_dbus_marshal_get_field_end_pos),
6168 (_dbus_verbose_bytes), (_dbus_marshal_test):
6169 * dbus/dbus-marshal.h:
6170 * dbus/dbus-message-internal.h:
6171 * dbus/dbus-message.c: (_dbus_message_set_client_serial),
6172 (dbus_message_write_header), (_dbus_message_lock),
6173 (dbus_message_new), (dbus_message_ref), (dbus_message_unref),
6174 (dbus_message_get_name), (dbus_message_append_int32),
6175 (dbus_message_append_uint32), (dbus_message_append_double),
6176 (dbus_message_append_string), (dbus_message_append_byte_array),
6177 (dbus_message_get_fields_iter), (dbus_message_iter_ref),
6178 (dbus_message_iter_unref), (dbus_message_iter_has_next),
6179 (dbus_message_iter_next), (dbus_message_iter_get_field_type),
6180 (dbus_message_iter_get_string), (dbus_message_iter_get_int32),
6181 (dbus_message_iter_get_uint32), (dbus_message_iter_get_double),
6182 (decode_header_data), (_dbus_message_loader_return_buffer),
6183 (message_iter_test), (_dbus_message_test):
6184 * dbus/dbus-message.h:
6185 * dbus/dbus-protocol.h:
6186 * dbus/dbus-test.c: (main):
6188 * glib/test-dbus-glib.c: (message_handler), (main):
6189 * test/echo-client.c: (main):
6190 * test/watch.c: (check_messages):
6191 Make messages sendable and receivable for real.
6193 2003-01-07 Anders Carlsson <andersca@codefactory.se>
6195 * dbus/dbus-marshal.c: (_dbus_marshal_double),
6196 (_dbus_marshal_string), (_dbus_marshal_byte_array):
6197 * dbus/dbus-message.c: (dbus_message_append_int32),
6198 (dbus_message_append_uint32), (dbus_message_append_double),
6199 (dbus_message_append_string), (dbus_message_append_byte_array):
6200 Handle OOM restoration.
6202 2003-01-07 Anders Carlsson <andersca@codefactory.se>
6204 * dbus/dbus-marshal.c: (_dbus_marshal_string),
6205 (_dbus_demarshal_string), (_dbus_marshal_test):
6206 * dbus/dbus-marshal.h:
6207 * dbus/dbus-message.c: (dbus_message_get_name),
6208 Document these functions.
6210 (dbus_message_append_int32), (dbus_message_append_uint32),
6211 (dbus_message_append_double), (dbus_message_append_string),
6212 (dbus_message_append_byte_array):
6213 * dbus/dbus-message.h:
6214 Add functions for adding message fields of different types.
6216 * dbus/dbus-protocol.h:
6217 Add the different types.
6219 2003-01-05 Havoc Pennington <hp@pobox.com>
6221 * bus/connection.c: implement routines for handling connections,
6222 first thing is keeping a list of owned services on each connection
6223 and setting up watches etc.
6225 * bus/services.c: implement a mapping from service names to lists
6228 * dbus/dbus-hash.c: add DBUS_HASH_POINTER
6230 * dbus/dbus-threads.c (dbus_static_mutex_lock): add functions
6231 to use static mutexes for global data
6233 * dbus/dbus-connection.c (dbus_connection_set_data): add new
6234 collection of functions to set/get application-specific data
6235 on the DBusConnection.
6237 2003-01-04 Havoc Pennington <hp@pobox.com>
6239 * dbus/dbus-sysdeps.c (_dbus_sleep_milliseconds): new function
6240 (_dbus_poll): new function
6242 * dbus/dbus-internals.h (_DBUS_STRUCT_OFFSET): new macro
6245 * bus/loop.c: initial code for the daemon main loop
6247 2003-01-04 Havoc Pennington <hp@pobox.com>
6249 * test/watch.c (error_handler): make it safe if the error handler
6250 is called multiple times (if we s/error handler/disconnect
6251 handler/ we should just guarantee it's called only once)
6253 * dbus/dbus-transport.c (_dbus_transport_disconnect): call the
6254 error handler on disconnect (it's quite possible we should
6255 just change the error handler to a "disconnect handler," I'm
6256 not sure we have any other meaningful errors)
6258 * configure.in: check for getpwnam_r
6260 * dbus/dbus-transport.c, dbus/dbus-transport-unix.c,
6261 dbus/dbus-auth.c: add credentials support, add EXTERNAL auth
6262 mechanism as in SASL spec, using socket credentials
6264 * dbus/dbus-sysdeps.c (_dbus_read_credentials_unix_socket): new function
6265 (_dbus_send_credentials_unix_socket): new function
6267 * dbus/dbus-sysdeps.c (_dbus_accept_unix_socket): rename just
6269 (_dbus_write): only check errno if <0 returned
6270 (_dbus_write_two): ditto
6272 2003-01-02 Anders Carlsson <andersca@codefactory.se>
6274 * dbus/dbus-marshal.c: (_dbus_marshal_utf8_string),
6275 (_dbus_marshal_byte_array), (_dbus_demarshal_utf8_string),
6276 (_dbus_marshal_test):
6277 * dbus/dbus-marshal.h:
6278 Add _dbus_marshal_byte_array and rename _dbus_marshal_string
6279 to _dbus_marshal_utf8_string. Also fix some tests.
6281 2002-12-28 Harri Porten <porten@kde.org>
6283 * configure.in: added check for C++ compiler and a very cheesy
6284 check for the Qt integration
6286 * Makefile.am (SUBDIRS): compile qt subdir if support is enabled
6288 * qt/Makefile.am: added
6290 * qt/.cvsignore: added
6292 * qt/dbus-qthread.cc, qt/dbus-qthread.cpp: renamed former to
6293 latter, added #ifdef QT_THREAD_SUPPORT guard.
6295 * dbus/Makefile.am: added missing headers for make dist
6297 2002-12-28 Kristian Rietveld <kris@gtk.org>
6299 * dbus/Makefile.am: fixup export-symbols-regex.
6301 2002-12-27 Anders Carlsson <andersca@codefactory.se>
6303 * acinclude.m4: Add this file and put the
6304 PKG_CHECK_MODULE macro in it.
6306 2002-12-27 Anders Carlsson <andersca@codefactory.se>
6308 * dbus/dbus-marshal.c: (_dbus_marshal_string),
6309 (_dbus_demarshal_double), (_dbus_demarshal_int32),
6310 (_dbus_demarshal_uint32), (_dbus_demarshal_string),
6311 (_dbus_marshal_test):
6312 Make the demarshalling routines align the pos argument.
6313 Add string marshalling tests and fix the obvious bugs
6316 2002-12-26 Havoc Pennington <hp@pobox.com>
6318 * dbus/dbus-auth.c: fixes fixes fixes
6320 * dbus/dbus-transport-unix.c: wire up support for
6321 encoding/decoding data on the wire
6323 * dbus/dbus-auth.c (_dbus_auth_encode_data)
6324 (_dbus_auth_decode_data): append to target string
6325 instead of nuking it.
6327 2002-12-26 Havoc Pennington <hp@pobox.com>
6329 * dbus/dbus-marshal.h (DBUS_COMPILER_BYTE_ORDER): #ifdef
6330 WORDS_BIGENDIAN then compiler byte order is DBUS_BIG_ENDIAN,
6333 * dbus/dbus-marshal.c: Add macros to do int swapping in-place and
6334 avoid swap_bytes() overhead (ignoring possible assembly stuff for
6335 now). Main point is because I wanted unpack_uint32 to implement
6337 (_dbus_verbose_bytes): new function
6339 * dbus/dbus-string.c (_dbus_string_validate_ascii): new function
6341 * dbus/dbus-message.c (_dbus_message_loader_get_is_corrupted): add
6342 mechanism to handle a corrupt message stream
6343 (_dbus_message_loader_new): fix preallocation to only prealloc,
6346 * dbus/dbus-string.c (_dbus_string_skip_blank): fix this function
6347 (_dbus_string_test): enhance tests for copy/move and fix the
6350 * dbus/dbus-transport-unix.c: Hold references in more places to
6351 avoid reentrancy problems
6353 * dbus/dbus-transport.c: ditto
6355 * dbus/dbus-connection.c (dbus_connection_dispatch_message): don't
6356 leak reference count in no-message case
6358 * test/watch.c (do_mainloop): handle adding/removing watches
6359 during iteration over the watches. Also, ref the connection/server
6360 stored on a watch, so we don't try to mangle a destroyed one.
6362 * dbus/dbus-transport-unix.c (do_authentication): perform
6365 * dbus/dbus-auth.c (get_state): add a state
6366 AUTHENTICATED_WITH_UNUSED_BYTES and return it if required
6367 (_dbus_auth_get_unused_bytes): append the unused bytes
6368 to the passed in string, rather than prepend
6370 * dbus/dbus-transport.c (_dbus_transport_init_base): create
6371 the auth conversation DBusAuth
6373 * dbus/dbus-transport-unix.c (_dbus_transport_new_for_fd)
6374 (_dbus_transport_new_for_domain_socket): when creating a
6375 transport, pass in whether it's a client-side or server-side
6376 transport so we know which DBusAuth to create
6378 2002-12-03 Havoc Pennington <hp@pobox.com>
6380 * dbus/dbus-transport-unix.c (unix_finalize): finalize base
6381 _after_ finalizing the derived members
6382 (unix_connection_set): unref watch if we fail to add it
6384 * dbus/dbus-connection.c (dbus_connection_unref): delete the
6385 transport first, so that the connection owned by the
6386 transport will be valid as the transport finalizes.
6388 * dbus/dbus-transport-unix.c (unix_finalize): free the write_watch
6389 if necessary, and remove watches from the connection.
6391 * dbus/dbus-watch.c (_dbus_watch_list_free): improve a comment
6393 2002-12-26 Anders Carlsson <andersca@codefactory.se>
6395 * dbus/dbus-marshal.c: (_dbus_marshal_string),
6396 (_dbus_demarshal_double), (_dbus_demarshal_int32),
6397 (_dbus_demarshal_uint32), (_dbus_demarshal_string),
6398 (_dbus_marshal_test):
6399 * dbus/dbus-marshal.h:
6400 Add string marshal functions and have the demarshal functions
6401 return the new position.
6403 2002-12-25 Havoc Pennington <hp@pobox.com>
6405 * doc/dbus-sasl-profile.txt: docs on the authentication protocol,
6406 it is a simple protocol that just maps directly to SASL.
6408 * dbus/dbus-auth.h, dbus/dbus-auth.c: authentication protocol
6409 initial implementation, not actually used yet.
6411 * dbus/dbus-string.c (_dbus_string_find): new function
6412 (_dbus_string_equal): new function
6413 (_dbus_string_base64_encode): new function
6414 (_dbus_string_base64_decode): new function
6416 2002-12-25 Anders Carlsson <andersca@codefactory.se>
6419 * dbus/dbus-marshal.c: (swap_bytes), (_dbus_marshal_double),
6420 (_dbus_marshal_int32), (_dbus_marshal_uint32),
6421 (_dbus_demarshal_double), (_dbus_demarshal_int32),
6422 (_dbus_demarshal_uint32), (_dbus_marshal_test):
6423 * dbus/dbus-marshal.h:
6424 * dbus/dbus-protocol.h:
6425 * dbus/dbus-test.c: (main):
6427 Add un-optimized marshalling/demarshalling routines.
6429 2002-12-25 Harri Porten <porten@kde.org>
6431 * qt/dbus-qt.h: adjusted ctor and getter to KDE/Qt conventions
6433 2002-12-24 Zack Rusin <zack@kde.org>
6435 * qt/dbus-qthread.cc: adding - integrates QMutex into Dbus
6436 * qt/dbus-qt.h: skeleton with two sample implemenatation of the
6439 2002-12-24 Havoc Pennington <hp@pobox.com>
6441 * glib/dbus-gthread.c: fix include
6443 * glib/dbus-glib.h: rename DBusMessageHandler for now.
6444 I think glib API needs to change, though, as you don't
6445 want to use DBusMessageFunction, you want to use the
6446 DBusMessageHandler object. Probably
6447 dbus_connection_open_with_g_main_loop()
6448 and dbus_connection_setup_g_main_loop() or something like that
6449 (but think of better names...) that just create a connection
6450 that has watch/timeout functions etc. already set up.
6452 * dbus/dbus-connection.c
6453 (dbus_connection_send_message_with_reply): new function just to
6454 show how the message handler helps us deal with replies.
6456 * dbus/dbus-list.c (_dbus_list_remove_last): new function
6458 * dbus/dbus-string.c (_dbus_string_test): free a string that
6461 * dbus/dbus-hash.c: use memory pools for the hash entries
6462 (rebuild_table): be more paranoid about overflow, and
6463 shrink table when we can
6464 (_dbus_hash_test): reduce number of sprintfs and write
6465 valid C89. Add tests for case where we grow and then
6466 shrink the hash table.
6468 * dbus/dbus-mempool.h, dbus/dbus-mempool.c: memory pools
6470 * dbus/dbus-connection.c (dbus_connection_register_handler)
6471 (dbus_connection_unregister_handler): new functions
6473 * dbus/dbus-message.c (dbus_message_get_name): new
6475 * dbus/dbus-list.c: fix docs typo
6477 * dbus/dbus-message-handler.h, dbus/dbus-message-handler.c:
6478 an object representing a handler for messages.
6480 2002-12-16 Anders Carlsson <andersca@codefactory.se>
6483 * glib/dbus-gthread.c: (dbus_gthread_init):
6484 Don't use the gdbus prefix for public functions.
6486 2002-12-16 Anders Carlsson <andersca@codefactory.se>
6490 Add GLib checks and fixup .pc files
6494 * glib/dbus-gmain.c: (gdbus_connection_prepare),
6495 (gdbus_connection_check), (gdbus_connection_dispatch),
6496 (gdbus_add_connection_watch), (gdbus_remove_connection_watch),
6497 (dbus_connection_gsource_new):
6498 * glib/dbus-gthread.c: (dbus_gmutex_new), (dbus_gmutex_free),
6499 (dbus_gmutex_lock), (dbus_gmutex_unlock), (dbus_gthread_init):
6500 * glib/test-dbus-glib.c: (message_handler), (main):
6503 2002-12-15 Harri Porten <porten@kde.org>
6505 * autogen.sh: check for libtoolize before attempting to use it
6507 * dbus/dbus-transport-unix.c: include <sys/time.h> for timeval
6510 * .cvsignore: ignore more stamp files
6512 * dbus/dbus-watch.c (_dbus_watch_list_new): fixed doc error
6514 * test/Makefile.am: added -I$(top_srcdir) to be able to compile
6515 without make install.
6517 2002-12-15 Havoc Pennington <hp@pobox.com>
6519 * dbus/dbus-threads.c: add thread stubs that a higher library
6520 layer can fill in. e.g. the GLib wrapper might fill them in with
6521 GThread stuff. We still need to use this thread API to
6522 thread-safe-ize the library.
6524 2002-12-12 Havoc Pennington <hp@pobox.com>
6526 * dbus/dbus-transport-unix.c, dbus/dbus-server-unix.c: use the
6527 below new interfaces and include fewer system headers.
6529 * dbus/dbus-sysdeps.c (_dbus_read): new function
6530 (_dbus_write): new function
6531 (_dbus_write_two): new function
6532 (_dbus_connect_unix_socket): new function
6533 (_dbus_listen_unix_socket): new function
6535 * dbus/dbus-message-internal.h: change interfaces to use
6538 2002-12-11 Havoc Pennington <hp@pobox.com>
6540 * dbus/dbus-types.h: add dbus_unichar
6542 * dbus/dbus-internals.c (_dbus_verbose): use _dbus_getenv
6544 * dbus/dbus-connection.c (dbus_connection_send_message): return
6547 * dbus/dbus-transport.c: include dbus-watch.h
6549 * dbus/dbus-connection.c: include dbus-message-internal.h
6551 * HACKING: add file with coding guidelines stuff.
6553 * dbus/dbus-string.h, dbus/dbus-string.c: Encapsulate all string
6554 handling here, for security purposes (as in vsftpd). Not actually
6555 using this class yet.
6557 * dbus/dbus-sysdeps.h, dbus/dbus-sysdeps.c: Encapsulate all
6558 system/libc usage here, as in vsftpd, for ease of auditing (and
6559 should also simplify portability). Haven't actually moved all the
6560 system/libc usage into here yet.
6562 2002-11-25 Havoc Pennington <hp@pobox.com>
6564 * dbus/dbus-internals.c (_dbus_verbose): fix to not
6565 always print the first verbose message.
6567 2002-11-24 Havoc Pennington <hp@pobox.com>
6569 * test/echo-client.c, test/echo-server.c: cheesy test
6572 * configure.in (AC_CHECK_FUNCS): check for writev
6574 * dbus/dbus-message.c (_dbus_message_get_network_data): new
6577 * dbus/dbus-list.c (_dbus_list_foreach): new function
6579 * dbus/dbus-internals.c (_dbus_verbose): new function
6581 * dbus/dbus-server.c, dbus/dbus-server.h: public object
6582 representing a server that listens for connections.
6584 * dbus/.cvsignore: create
6586 * dbus/dbus-errors.h, dbus/dbus-errors.c:
6587 public API for reporting errors
6589 * dbus/dbus-connection.h, dbus/dbus-connection.c:
6590 public object representing a connection that
6591 sends/receives messages. (Same object used for
6592 both client and server.)
6594 * dbus/dbus-transport.h, dbus/dbus-transport.c:
6595 Basic abstraction for different kinds of stream
6596 that we might read/write messages from.
6598 2002-11-23 Havoc Pennington <hp@pobox.com>
6600 * dbus/dbus-internals.h (_DBUS_INT_MAX): add _DBUS_INT_MIN
6603 * dbus/dbus-test.c (main): add list test, and include
6604 dbus-test.h as intended
6606 * dbus/dbus-hash.c (_dbus_hash_table_remove_string)
6607 (_dbus_hash_table_remove_int): return value indicates
6608 whether the entry existed to remove
6610 * dbus/dbus-list.c: add linked list utility class,
6613 * dbus/dbus-hash.c: add TODO item about shrinking the hash bucket
6616 2002-11-23 Havoc Pennington <hp@pobox.com>
6618 * Doxyfile.in (INCLUDE_FILE_PATTERNS): expand DBUS_BEGIN_DECLS/
6619 DBUS_END_DECLS to nothing, that should fix this once and for all
6621 * Doxyfile.in (JAVADOC_AUTOBRIEF): set to YES
6623 * dbus/dbus-message.c, dbus/dbus-hash.c:
6624 add some missing @brief
6626 2002-11-23 Havoc Pennington <hp@pobox.com>
6628 * dbus/dbus-message.h: put semicolons after DEBUG_BEGIN_DECLS
6629 to avoid confusing Doxygen
6631 * dbus/dbus-hash.c: @} not }@
6633 * dbus/dbus-message.c (struct DBusMessage): split out
6636 2002-11-23 Havoc Pennington <hp@pobox.com>
6638 * configure.in: pile on more warning flags if using gcc
6640 * Doxyfile.in (EXTRACT_STATIC): set to NO, so we don't have
6641 to document static functions
6643 * configure.in: add summary to end of configure so it
6644 looks nice and attractive
6646 * dbus/dbus-hash.c: finish implementation and write unit
6649 * configure.in: add --enable-tests to enable unit tests
6651 * dbus/dbus-test.c: test program to run unit tests
6652 for all files in dbus/*, initially runs a test for
6655 * dbus/dbus-internals.h: file to hold some internal utility stuff
6657 2002-11-22 Havoc Pennington <hp@redhat.com>
6659 * dbus/dbus-hash.c: copy in Tcl hash table, not yet
6660 "ported" away from Tcl
6662 * dbus/dbus-types.h: header for types such as dbus_bool_t
6664 2002-11-22 Havoc Pennington <hp@redhat.com>
6666 * dbus/dbus.h: fixups for doc warnings
6668 * Doxyfile.in (FILE_PATTERNS): we need to scan .h to pick up
6670 (QUIET): make it quiet so we can see warnings
6672 * dbus/dbus-memory.c: teach D-BUS to allocate and free memory
6674 2002-11-22 Havoc Pennington <hp@redhat.com>
6676 * Makefile.am: include "Doxyfile" target in all-local
6678 * configure.in: generate the Doxyfile
6680 * Doxyfile.in: move Doxyfile here, so we can use
6681 configure to generate a Doxyfile with the right
6684 2002-11-22 Havoc Pennington <hp@redhat.com>
6686 * dbus/dbus-message.c: move inline docs into .c file
6688 * Doxyfile (OUTPUT_DIRECTORY): move output to doc/api
6689 so all docs are under doc/
6690 (MAN_EXTENSION): generate man pages. Use extension
6691 ".3dbus" which matches ".3qt" on my system,
6692 I guess this is OK, I don't know really.
6693 (FILE_PATTERNS): look for .c files not .h, makes sense
6696 2002-11-22 Havoc Pennington <hp@pobox.com>
6698 * Makefile.am (SUBDIRS): rename subdir "server" to "bus"
6699 because any app can be a server, and any app can be a client,
6700 the bus is a special kind of server.
6702 Thu Nov 21 23:35:31 2002 Zack Rusin <zack@kde.org>
6704 * Doxyfile : adding. Still needs Makefile rules to be generated
6705 automatically (just run "doxygen" in the toplevel dir for now to
6708 * dbus/dbus-message.h : Adding sample docs (javadoc since
6709 resembles gtk-doc a little more)
6711 * dbus/dbus.h : Adding sample docs
6713 2002-11-21 Havoc Pennington <hp@redhat.com>
6715 * dbus/Makefile.am (INCLUDES): define DBUS_COMPILATION
6716 so we can allow ourselves to include files directly,
6717 instead of having to use dbus.h
6719 * dbus/dbus.h: fill in
6721 * dbus/dbus-message.h: sketch out a sample header file.
6722 Include griping if you include it directly instead of
6725 * dbus/dbus-macros.h: new file with macros for extern "C",
6726 TRUE/FALSE, NULL, etc.
6728 * doc/file-boilerplate.c: put include guards in here
6730 2002-11-21 Havoc Pennington <hp@redhat.com>
6732 * doc/file-boilerplate.c: include both AFL and GPL boilerplate.
6734 * COPYING: include the GPL as well, and license code
6735 under both AFL and GPL.
6737 2002-11-21 Havoc Pennington <hp@redhat.com>
6739 * acconfig.h: get rid of this
6741 * autogen.sh (run_configure): add --no-configure option
6743 * configure.in: remove AC_ARG_PROGRAM to make
6744 autoconf complain less. add AC_PREREQ.
6745 add AC_DEFINE third arg.
6747 2002-11-21 Anders Carlsson <andersca@codefactory.se>
6750 Fix references so we can distcheck.
6752 2002-11-21 Havoc Pennington <hp@redhat.com>
6754 * Initial module creation