1 2004-12-26 Havoc Pennington <hp@redhat.com>
3 * dbus/dbus-internals.h: add _DBUS_GNUC_NORETURN to _dbus_assert
5 2005-01-03 Havoc Pennington <hp@redhat.com>
7 * dbus/dbus-sysdeps.c (_dbus_sysdeps_test): fix using == on
10 * dbus/dbus-string.c (_dbus_string_insert_alignment): new function
12 2005-01-02 Havoc Pennington <hp@redhat.com>
14 * dbus/dbus-internals.h (_DBUS_ALIGN_OFFSET): new macro
16 2005-01-01 Havoc Pennington <hp@redhat.com>
18 * configure.in: add -Wfloat-equal
20 2005-01-01 Havoc Pennington <hp@redhat.com>
22 * dbus/dbus-sysdeps.h: add _DBUS_DOUBLES_BITWISE_EQUAL macro,
23 for a variety of reasons '==' doesn't do this.
25 2004-12-31 Havoc Pennington <hp@redhat.com>
27 * dbus/dbus-string.c (_dbus_string_equal_substrings): new function
30 2004-12-30 John (J5) Palmieri <johnp@redhat.com>
32 * python/dbus.py: s/ACTIVATION_REPLY_ACTIVE/ACTIVATION_REPLY_ACTIVATED
34 2004-12-30 John (J5) Palmieri <johnp@redhat.com>
36 * python/dbus_bindings.pyx.in: Change DBUS_ACTIVATION_REPLY_ACTIVATED
37 and DBUS_ACTIVATION_REPLY_ALREADY_ACTIVE to match the values in
38 dbus-protocol.h. Because they are defines and not enums they are not
41 2004-12-26 John (J5) Palmieri <johnp@redhat.com>
43 * python/dbus_bindings.pyx.in (bus_activate_service): Bind
44 dbus_bus_activate_service
46 * python/dbus.py (Bus.activate_service): activate a service on the
49 2004-12-24 Havoc Pennington <hp@redhat.com>
51 * test/decode-gcov.c: change to use .gcno and .gcda files, but the
52 file format has also changed and I haven't adapted to that yet
54 * Makefile.am: load .gcno files from latest gcc
56 2004-12-23 John (J5) Palmieri <johnp@redhat.com>
57 * Patch from Rob Taylor <robtaylor@fastmail.fm>
59 * python/dbus_bindings.pyx.in (bus_get_unix_user): New
62 * python/dbus.py (get_unix_user): Added binding to
63 call dbus_bindings.bus_get_unix_user
65 * python/extract.py: Modified the proto_pat regex to
68 2004-12-21 Olivier Andrieu <oliv__a@users.sourceforge.net>
70 * dbus/make-dbus-glib-error-enum.sh: omit the function keyword for
71 better POSIX compliance.
73 2004-12-19 Havoc Pennington <hp@redhat.com>
75 * dbus/dbus-string.c (_dbus_string_insert_4_aligned)
76 (_dbus_string_insert_8_aligned): new functions
78 * dbus/dbus-string.c (_dbus_string_alloc_space): new function
80 2004-12-18 Havoc Pennington <hp@redhat.com>
82 * dbus/dbus-string.c (_dbus_string_validate_ascii): use ISASCII
85 * dbus/dbus-message.c: fix a comment, and add a still-unused
86 not-implemented function
88 * dbus/dbus-marshal.h: fix comment
90 * dbus/dbus-internals.h (_DBUS_ISASCII): new macro
92 2004-12-17 Joe Shaw <joeshaw@novell.com>
94 * mono/DBusType/Byte.cs, mono/DBusType/Int32.cs,
95 mono/DBusType/Int64.cs, mono/DBusType/UInt32.cs,
96 mono/DBusType/UInt64.cs: Use Enum.GetUnderlyingType() instead of
97 Type.UnderlyingSystemType to get the actual system type
98 underneath. This code previously depended on the broken Mono
99 behavior, which was fixed in 1.1.3.
101 2004-11-27 Havoc Pennington <hp@redhat.com>
103 * dbus/dbus-string.h (_dbus_string_get_byte): inline when asserts
105 (_dbus_string_get_const_data): inline when asserts are disabled
107 * dbus/dbus-message.c: record the _dbus_current_generation of
108 creation so we can complain if dbus_shutdown() is used improperly.
109 Do this only if checks are enabled.
111 * dbus/dbus-connection.c: ditto
113 2004-11-26 Havoc Pennington <hp@redhat.com>
115 * test/glib/test-profile.c: add with_bus mode to profile echoes
116 that go through the bus.
118 * test/glib/run-test.sh: add ability to run test-profile
120 * bus/dbus-daemon-1.1.in: fix to say that SIGHUP causes partial
123 2004-11-26 Havoc Pennington <hp@redhat.com>
125 * test/glib/test-profile.c: clean up how the fake_malloc_overhead
126 thing was implemented
128 2004-11-26 Havoc Pennington <hp@redhat.com>
130 * test/glib/test-profile.c: tweak a bit, add support for some
131 made-up minimal malloc overhead with plain sockets, since in
132 real life some sort of buffers are unavoidable thus we could
133 count them in the theoretical best case
135 2004-11-26 Havoc Pennington <hp@redhat.com>
137 * dbus/dbus-message.c (dbus_message_cache_or_finalize): fix bug
138 where I was trying to cache one too many messages
140 2004-11-26 Havoc Pennington <hp@redhat.com>
142 * dbus/dbus-message.c: reimplement message cache as an array which
143 makes the cache about twice as fast and saves maybe 1.5% overall
145 2004-11-26 Havoc Pennington <hp@redhat.com>
147 * dbus/dbus-threads.c (init_global_locks): forgot to put the
148 message cache lock here
150 2004-11-26 Havoc Pennington <hp@redhat.com>
152 * dbus/dbus-message.c (struct DBusMessage): put the locked bit and
153 the "char byte_order" next to each other to save 4 bytes
154 (dbus_message_new_empty_header): reduce preallocation, since the
155 message cache should achieve a similar effect
156 (dbus_message_cache_or_finalize, dbus_message_get_cached): add a
157 message cache that keeps a few DBusMessage around in a pool,
158 another 8% speedup or so.
160 * dbus/dbus-dataslot.c (_dbus_data_slot_list_clear): new function
162 2004-11-25 Havoc Pennington <hp@redhat.com>
164 * dbus/dbus-transport-unix.c (unix_do_iteration): if we're going
165 to write, without reading or blocking, try it before the poll()
166 and skip the poll() if nothing remains to write. This is about a
167 3% speedup in the echo client/server
169 2004-11-25 Havoc Pennington <hp@redhat.com>
171 The primary change here is to always write() once before adding
172 the write watch, which gives us about a 10% performance increase.
174 * dbus/dbus-transport-unix.c: a number of modifications to cope
175 with removing messages_pending
176 (check_write_watch): properly handle
177 DBUS_AUTH_STATE_WAITING_FOR_MEMORY; adapt to removal of
178 messages_pending stuff
179 (check_read_watch): properly handle WAITING_FOR_MEMORY and
181 (unix_handle_watch): after writing, see if the write watch can be
183 (unix_do_iteration): assert that write_watch/read_watch are
184 non-NULL rather than testing that they aren't, since they
185 aren't allowed to be NULL. check_write_watch() at the end so
186 we add the watch if we did not finish writing (e.g. got EAGAIN)
188 * dbus/dbus-transport-protected.h: remove messages_pending call,
189 since it resulted in too much inefficient watch adding/removing;
190 instead we now require that the transport user does an iteration
191 after queueing outgoing messages, and after trying the first
192 write() we add a write watch if we got EAGAIN or exceeded our
193 max bytes to write per iteration setting
195 * dbus/dbus-string.c (_dbus_string_validate_signature): add this
198 * dbus/dbus-server-unix.c (unix_finalize): the socket name was
199 freed and then accessed, valgrind flagged this bug, fix it
201 * dbus/dbus-message.c: fix several bugs where HEADER_FIELD_LAST was taken
202 as the last valid field plus 1, where really it is equal to the
203 last valid field. Corrects some message corruption issues.
205 * dbus/dbus-mainloop.c: verbosity changes
207 * dbus/dbus-keyring.c (_dbus_keyring_new_homedir): handle OOM
208 instead of aborting in one of the test codepaths
210 * dbus/dbus-internals.c (_dbus_verbose_real): fix a bug that
211 caused not printing the pid ever again if a verbose was missing
212 the newline at the end
213 (_dbus_header_field_to_string): add HEADER_FIELD_SIGNATURE
215 * dbus/dbus-connection.c: verbosity changes;
216 (dbus_connection_has_messages_to_send): new function
217 (_dbus_connection_message_sent): no longer call transport->messages_pending
218 (_dbus_connection_send_preallocated_unlocked): do one iteration to
219 try to write() immediately, so we can avoid the write watch. This
220 is the core purpose of this patchset
221 (_dbus_connection_get_dispatch_status_unlocked): if disconnected,
222 dump the outgoing message queue, so nobody will get confused
223 trying to send them or thinking stuff is pending to be sent
225 * bus/test.c: verbosity changes
227 * bus/driver.c: verbosity/assertion changes
229 * bus/dispatch.c: a bunch of little tweaks to get it working again
230 because this patchset changes when/where you need to block.
232 2004-11-23 Havoc Pennington <hp@redhat.com>
234 * test/glib/test-profile.c: modify to accept a plain_sockets
235 argument in which case it will bench plain sockets instead of
236 libdbus, for comparison purposes.
238 2004-11-22 Havoc Pennington <hp@redhat.com>
240 * test/glib/test-profile.c (N_CLIENT_THREADS): run multiple
241 threads for more time, so sysprof can get a grip on it.
243 * dbus/dbus-string.c (_dbus_string_validate_utf8): remove
246 2004-11-13 Havoc Pennington <hp@redhat.com>
248 * test/glib/test-profile.c: fix this thing up a bit
250 * dbus/dbus-message.c (dbus_message_new_empty_header): increase
251 preallocation sizes by a fair bit; not sure if this will be an
252 overall performance win or not, but it does reduce reallocs.
254 * dbus/dbus-string.c (set_length, reallocate_for_length): ignore
255 the test hack that forced constant realloc if asserts are
256 disabled, so we can profile sanely. Sprinkle in some
257 _DBUS_UNLIKELY() which are probably pointless, but before I
258 noticed the real performance problem I put them in.
259 (_dbus_string_validate_utf8): micro-optimize this thing a little
260 bit, though callgrind says it didn't help; then special-case
261 ascii, which did help a lot; then be sure we detect nul bytes as
262 invalid, which is a bugfix.
263 (align_length_then_lengthen): add some more _DBUS_UNLIKELY
264 superstition; use memset to nul the padding instead of a manual
266 (_dbus_string_get_length): inline this as a
267 macro; it showed up in the profile because it's used for loop
270 2004-11-10 Colin Walters <walters@verbum.org>
272 * dbus/dbus-spawn.c (check_babysit_events): Handle EINTR,
275 2004-11-09 Colin Walters <walters@verbum.org>
277 * dbus/dbus-string.c (_dbus_string_get_length): New
278 function, writes DBusString to C buffer.
280 * dbus/dbus-string.h: Prototype it.
282 * dbus/dbus-message.c (dbus_message_type_to_string): New
283 function, converts message type into C string.
285 * dbus/dbus-message.h: Prototype it.
287 * bus/selinux.c (bus_selinux_check): Take source pid,
288 target pid, and audit data. Pass audit data to
290 (log_audit_callback): New function, appends extra
292 (bus_selinux_allows_acquire_service): Also take
293 service name, add it to audit data.
294 (bus_selinux_allows_send): Also take message
295 type, interface, method member, error name,
296 and destination, and add them to audit data.
297 (log_cb): Initialize func_audit.
299 * bus/selinux.h (bus_selinux_allows_acquire_service)
300 (bus_selinux_allows_send): Update prototypes
302 * bus/services.c (bus_registry_acquire_service): Pass
303 service name to bus_selinux_allows_acquire_service.
305 * bus/bus.c (bus_context_check_security_policy): Pass
306 additional audit data. Move assignment of dest
309 2004-11-07 Colin Walters <walters@verbum.org>
311 * dbus/dbus-transport-unix.c (do_authentication): Always
312 initialize auth_completed.
314 2004-11-07 Colin Walters <walters@verbum.org>
316 * bus/bus.c (load_config): Break into three
317 separate functions: process_config_first_time_only,
318 process_config_every_time, and process_config_postinit.
319 (process_config_every_time): Move call of
320 bus_registry_set_service_context_table into
321 process_config_postinit.
322 (process_config_postinit): New function, does
323 any processing that needs to happen late
324 in initialization (and also on reload).
325 (bus_context_new): Instead of calling load_config,
326 open config parser here and call process_config_first_time_only
327 and process_config_every_time directly. Later, after
328 we have forked but before changing UID,
329 invoke bus_selinux_full_init, and then call
330 process_config_postinit.
331 (bus_context_reload_config): As in bus_context_new,
332 load parse file inside here, and call process_config_every_time
333 and process_config_postinit.
335 * bus/services.h, bus/services.c
336 (bus_registry_set_service_context_table): Rename
337 from bus_registry_set_sid_table. Take string hash from config
338 parser, and convert them here into SIDs.
340 * bus/config-parser.c (struct BusConfigParser): Have
341 config parser only store a mapping of service->context
343 (merge_service_context_hash): New function.
344 (merge_included): Merge context string hashes instead
345 of using bus_selinux_id_table_union.
346 (bus_config_parser_new): Don't use bus_selinux_id_table_new;
347 simply create a new string hash.
348 (bus_config_parser_unref): Unref it.
349 (start_selinux_child): Simply insert strings into hash,
350 don't call bus_selinux_id_table_copy_over.
352 * bus/selinux.h, bus/selinux.c (bus_selinux_id_table_union)
353 (bus_selinux_id_table_copy_over): Delete.
355 2004-11-03 Colin Walters <walters@verbum.org>
357 * bus/selinux.c (bus_selinux_pre_init): Kill some unused
360 2004-11-03 Colin Walters <walters@verbum.org>
362 * bus/test-main.c (test_pre_hook): Fix test logic,
363 thanks Joerg Barfurth <Joerg.Barfurth@Sun.COM>.
365 2004-11-02 Colin Walters <walters@redhat.com>
367 * bus/selinux.c (bus_selinux_init): Split into two functions,
368 bus_selinux_pre_init and bus_selinux_post_init.
369 (bus_selinux_pre_init): Just determine whether SELinux is
371 (bus_selinux_post_init): Do everything else.
373 * bus/main.c (main): Call bus_selinux_pre_init before parsing
374 config file, and bus_selinux_post_init after. This ensures that
375 we don't lose the policyreload notification thread that
376 bus_selinux_init created before forking previously.
378 * bus/test-main.c (test_pre_hook): Update for split.
380 2004-10-31 Owen Fraser-Green <owen@discobabe.net>
382 Patch from Johan Fischer <linux@fischaz.com>
384 * mono/doc/Makefile.am (install-data-local): Added directory
387 2004-10-29 Colin Walters <walters@redhat.com>
389 * dbus/dbus-sysdeps.h (_dbus_become_daemon): Also take
390 parameter for fd to write pid to.
392 * dbus/dbus-sysdeps.c (_dbus_become_daemon): Implement it.
394 * bus/bus.c (bus_context_new): Pass print_pid_fd
395 to _dbus_become_daemon (bug #1720)
397 2004-10-29 Colin Walters <walters@redhat.com>
399 Patch from Ed Catmur <ed@catmur.co.uk>
401 * mono/doc/Makefile.am (install-data-local): Handle
404 2004-10-29 Colin Walters <walters@redhat.com>
406 * bus/.cvsignore, qt/.cvsignore: Update.
408 2004-10-29 Colin Walters <walters@redhat.com>
410 Patch from Kristof Vansant <de_lupus@pandora.be>
412 * configure.in: Detect Slackware.
413 * bus/Makefile.am (SCRIPT_IN_FILES): Add rc.messagebus.in.
414 * bus/rc.messagebus.in: New file.
416 2004-10-29 Colin Walters <walters@redhat.com>
418 * tools/dbus-monitor.c (filter_func): Return
419 DBUS_HANDLER_RESULT_HANDLED in filter function
421 http://freedesktop.org/pipermail/dbus/2004-August/001433.html
423 2004-10-29 Colin Walters <walters@redhat.com>
425 Patch from Matthew Rickard <mjricka@epoch.ncsc.mil>
427 * bus/services.c (bus_registry_acquire_service):
428 Correctly retrieve service name from DBusString
431 2004-10-29 Colin Walters <walters@redhat.com>
433 * dbus/dbus-glib.h: Update documentation to not
434 refer to internal APIs.
436 2004-10-27 Joe Shaw <joeshaw@novell.com>
438 * mono/Arguments.cs (GetDBusTypeConstructor):
439 type.UnderlyingSystemType will return "System.Byte" if you do it
440 on "byte[]", which is not what we want. So check the type.IsArray
441 property and use System.Array instead.
443 2004-10-25 John (J5) Palmieri <johnp@redhat.com>
445 * dbus/dbus-sysdeps.c (fill_user_info): On errors do not free
446 the DBusUserInfo structure since this is passed into the function.
447 This would cause a double free when the function that allocated
448 the structure would try to free it when an error occured.
450 * (bus/session.conf.in, bus/Makefile.am, dbus/configure.in):
451 use /usr/share/dbus-1/services instead of /usr/lib/dbus-1.0/services
452 for service activation to avoid 32bit/64bit parallel install issues
454 2004-10-21 Colin Walters <walters@verbum.org>
456 * AUTHORS: Fix my email address, the @gnu.org one
457 has been bouncing for some time. Also add J5.
459 2004-10-21 Colin Walters <walters@verbum.org>
461 * dbus/dbus-transport-unix.c (do_authentication): Return
462 authentication status to callers.
463 (unix_handle_watch): If we completed authentication this round,
464 don't do another read. Instead wait until the next iteration,
465 after we've read any pending data in the auth buffer.
466 (unix_do_iteration): Ditto.
467 (unix_handle_watch): Updated for new do_authentication prototype.
469 2004-10-18 Colin Walters <walters@verbum.org>
471 * bus/selinux.c (bus_selinux_enabled): Handle
472 --disable-selinux case.
474 2004-10-18 Colin Walters <walters@verbum.org>
476 * bus/selinux.h: Add bus_selinux_enabled.
478 * bus/selinux.c (bus_selinux_enabled): Implement it.
480 * bus/config-parser.c (struct include): Add
481 if_selinux_enabled member.
482 (start_busconfig_child): Parse if_selinux_enabled
483 attribute for include.
484 (bus_config_parser_content): Handle it.
486 * bus/session.conf.in, bus/system.conf.in: Add
487 inclusion of context mapping to default config files;
488 conditional on SELinux being enabled.
490 * doc/busconfig.dtd: Add to if_selinux_enabled to default DTD.
492 * test/data/invalid-config-files/badselinux-1.conf,
493 test/data/invalid-config-files/badselinux-2.conf:
494 Test files for bad syntax.
496 2004-10-17 Colin Walters <walters@verbum.org>
498 * dbus/dbus-memory.c (_dbus_initialize_malloc_debug, check_guards)
499 (dbus_malloc, dbus_malloc0, dbus_realloc): Fix up printf
500 format specifier mismatches.
502 2004-10-07 Olivier Andrieu <oliv__a@users.sourceforge.net>
504 * dbus/dbus-sysdeps.c (_dbus_file_get_contents): fix an incorrect
507 * glib/dbus-dbus-gmain.c (dbus_g_bus_get): do not mangle NULL
508 pointer (bug #1540, Leonardo Boiko).
510 2004-09-28 Jon Trowbridge <trow@ximian.com>
512 * mono/BusDriver.cs: Changed BusDriver struct to remove
513 the ServiceCreated and ServiceDeleted events and replace them
514 with the new ServiceOwnerChanged event.
516 * mono/example/BusListener.cs: Added a new example program,
517 which listens for and reports any ServiceOwnerChanged events
520 * mono/example/Makefile.am (DESTDIR): Build changes for the
521 new BusListener.cs example.
523 2004-09-27 Olivier Andrieu <oliv__a@users.sourceforge.net>
525 * bus/signals.c (bus_match_rule_parse): validate the components of
526 match rules (bug #1439).
528 * dbus/dbus-bus.c (dbus_bus_add_match): add a missing OOM test.
530 2004-09-24 Olivier Andrieu <oliv__a@users.sourceforge.net>
532 * doc/dbus-specification.xml: document ServiceOwnerChanged
535 * bus/driver.c, bus/driver.h, bus/services.c: Use
536 ServiceOwnerChanged signal instead of ServiceCreated and
539 * bus/dispatch.c: update testcase for the new signal.
541 2004-09-20 Jon Trowbridge <trow@ximian.com>
543 Patch from Nat Friedman <nat@novell.com>
545 * mono/Makefile.am: A number of small build fixes to allow "make
546 distcheck" to succeed.
548 * mono/example/Makefile.am: "make distcheck" fixes.
550 * mono/AssemblyInfo.cs.in: When signing the assembly, look for the
553 * test/Makefile.am: "make distcheck" fixes.
555 2004-09-17 Olivier Andrieu <oliv__a@users.sourceforge.net>
557 * dbus/dbus-sysdeps.c (_dbus_user_at_console): fix memleak in OOM.
559 * doc/busconfig.dtd: update the DTD for the at_console attribute.
561 * bus/driver.c (bus_driver_handle_hello): correctly handle Hello
562 messages after the first one (bug #1389).
564 * bus/dispatch.c (check_double_hello_message): add a test case for
565 the double hello message bug.
566 (check_existent_service_activation): fix check of spawning error.
568 2004-09-16 David Zeuthen <david@fubar.dk>
570 * python/dbus_bindings.pyx.in: Add support for int64 and uint64
572 2004-09-12 David Zeuthen <david@fubar.dk>
574 Patch from Kay Sievers <kay.sievers@vrfy.org>
576 * bus/bus.c (bus_context_new):
580 Add commandline option --nofork to override configuration file
583 2004-09-09 Olivier Andrieu <oliv__a@users.sourceforge.net>
585 * dbus/dbus-*.h: remove the ; after DBUS_(BEGIN|END)_DECLS. Some C
586 compilers don't like it (bug #974).
588 2004-09-04 Harald Fernengel <harry@kdevelop.org>
590 * qt/connection.*: Applied patch by Jérôme Lodewyck
591 <lodewyck@clipper.ens.fr> to integrate an existing
592 connection into the Qt eventloop
594 2004-08-30 Jon Trowbridge <trow@ximian.com>
596 * mono/BusDriver.cs: Added. This is a class for interacting with
597 the org.freedesktop.DBus service.
599 * mono/Message.cs: Added a mechanism to expose the message that is
600 currently being dispatched via the static Message.Current
601 property. Added Message.Sender and Message.Destination
604 * mono/Handler.cs: Expose the dispatched message via
605 Message.Current when handling method calls.
607 * mono/Service.cs: Expose the dispatched message via
608 Message.Current when handling signal emissions.
610 * mono/Connection.cs: Bind dbus_bus_get_base_service via the
611 Connection.BaseService property.
613 2004-08-28 Havoc Pennington <hp@redhat.com>
615 * dbus/dbus-userdb.c (_dbus_is_console_user): remove unused variable
617 More fixes from Steve Grubb
619 * dbus/dbus-sysdeps.c (_dbus_connect_tcp_socket): fix fd leak
620 (_dbus_listen_tcp_socket): fix fd leak
622 * dbus/dbus-spawn.c (read_pid, read_ints): move the "again:" for
623 EINTR to a bit lower in the code
625 2004-08-26 Jon Trowbridge <trow@ximian.com>
627 * bus/driver.c (bus_driver_handle_service_exists): Respond with
628 TRUE if we are inquiring about the existence of the built-in
629 org.freedesktop.DBus service.
631 2004-08-25 John Palmieri <johnp@redhat.com>
632 * bus/config-parser.c:
633 (struct PolicyType): Add POLICY_CONSOLE
634 (struct Element.d.policy): s/gid_or_uid/gid_uid_or_at_console
635 (start_busconfig_child): Sets up console element when
636 <policy at_console=""> is encountered in a policy file
637 (append_rule_from_element): Convert console elements to console
641 (bus_policy_create_client_policy): Add console rules to the client
642 policy based on if the client is at the console
643 (bus_policy_append_console_rule): New function for adding a
644 console rule to a policy
645 (bus_policy_merge): Handle console rule merging
647 * dbus/dbus-sysdeps.h: Added the DBUS_CONSOLE_DIR constant
648 where we check for console user files
650 * dbus/dbus-sysdeps.c:
651 (_dbus_file_exists): New function which checks if the given
653 (_dbus_user_at_console): New function which does the system
654 specific process of checking if the user is at the console
656 * dbus/dbus-userdb.c:
657 (_dbus_is_console_user): New function converts a UID to user name
658 and then calls the system specific _dbus_user_at_console to
659 see if the user is at the console and therefor a console user
661 2004-08-25 Olivier Andrieu <oliv__a@users.sourceforge.net>
663 * bus/config-parser.c (set_limit):
664 * bus/dbus-daemon-1.1.in:
665 * test/data/valid-config-files/many-rules.conf: set the
666 max_match_rules_per_connection limt from the config file.
668 * doc/busconfig.dtd: update the DTD.
670 * bus/driver.c: remove some unused variables.
672 2004-08-24 Mikael Hallendal <micke@imendio.com>
674 * dbus/dbus-glib-lowlevel.h: Removed dbus_bus_get_with_g_main since
675 it's been replaced by dbus_g_bus_get
677 2004-08-23 Colin Walters <walters@redhat.com>
679 Updated SELinux support from Matthew Rickard <mjricka@epoch.ncsc.mil>
681 * bus/selinux.h: Prototype bus_selinux_get_policy_root.
683 * bus/selinux.c: Create a thread for policy reload notification.
684 (bus_selinux_get_policy_root): Implement.
686 * bus/config-parser.c (start_busconfig_child)
687 (bus_config_parser_content): Support SELinux-root relative
690 * configure.in <HAVE_SELINUX>: Add -lpthread.
692 * bus/test-main.c (test_pre_hook, test_post_hook): New.
693 (test_post_hook): Move memory checking into here.
694 (test_pre_hook, test_post_hook): Move SELinux checks in
695 here, but conditional on a DBUS_TEST_SELINUX environment
696 variable. Unfortunately we can't run the SELinux checks
697 as a normal user, since they won't have any permissions
698 for /selinux. So this will have to be tested manually
699 for now, until we have virtualization for most of
702 2004-08-23 Havoc Pennington <hp@redhat.com>
704 * dbus/dbus-sysdeps.c (_dbus_change_identity): add setgroups() to
705 drop supplementary groups, suggested by Steve Grubb
707 2004-08-20 Colin Walters <walters@redhat.com>
709 * bus/config-parser.c (start_busconfig_child): Remove some unused
712 * bus/selinux.c (bus_selinux_id_table_insert): Avoid compiler
715 2004-08-17 Joe Shaw <joeshaw@novell.com>
717 * configure.in: If --enable-mono is passed in, if we can't find
720 * mono/Makefile.am: Use /gacutil to install assemblies into the
723 2004-08-12 Havoc Pennington <hp@redhat.com>
725 * NEWS: update for 0.22
727 * configure.in: release 0.22
729 2004-08-11 Colin Walters <walters@redhat.com>
731 * tools/dbus-send.c (main, usage): Add --reply-timeout
734 2004-08-10 Olivier Andrieu <oliv__a@users.sourceforge.net>
736 * bus/bus.c (process_config_first_time_only): get rid of an unused
737 DBusError that was causing a memoy leak (bug #989).
739 * dbus/dbus-keyring.c, dbus/dbus-message.c:
740 fix compilation on Solaris/Forte C (bug #974)
742 * bus/main.c (main): plug two minuscule memleaks.
744 2004-08-10 Havoc Pennington <hp@redhat.com>
746 * doc/dbus-tutorial.xml: add some more info on GLib bindings
748 2004-08-09 Havoc Pennington <hp@redhat.com>
750 * COPYING: switch to Academic Free License version 2.1 instead of
751 2.0, to resolve complaints about patent termination clause.
753 2004-07-31 John (J5) Palmieri <johnp@redhat.com>
755 * README: added documentation for the --enable-python
758 2004-07-31 Olivier Andrieu <oliv__a@users.sourceforge.net>
760 * bus/config-parser.c (bus_config_parser_new): fix an invalid
761 _unref in the SELinux support.
763 * doc/busconfig.dtd: update DTD for SELinux support.
765 * bus/config-loader-libxml.c: fix error handler and parser
766 initialisation/cleanup. OOM test now works with libxml2 HEAD.
768 * configure.in: remove the warning about libxml2.
770 * dbus/dbus-bus.c: silence doxygen warning.
772 2004-07-31 Colin Walters <walters@redhat.com>
774 * configure.in: Move #error in SELinux check to its own line.
776 2004-07-31 Olivier Andrieu <oliv__a@users.sourceforge.net>
778 * dbus/dbus-internals.h (_DBUS_SET_OOM):
779 * bus/utils.h (BUS_SET_OOM): use dbus_error_set_const instead of
782 * bus/dispatch.c (check_send_exit_to_service): fix the test case,
783 broken by the change in the _SET_OOM macros.
785 2004-07-31 Colin Walters <walters@redhat.com>
787 * bus/selinux.c <HAVE_SELINUX>: Include utils.h to get
790 2004-07-31 Colin Walters <walters@redhat.com>
792 * configure.in: Use AC_TRY_COMPILE instead of AC_EGREP_HEADER
793 to correctly detect DBUS__ACQUIRE_SVC. Also add an
796 2004-07-24 Havoc Pennington <hp@redhat.com>
798 SELinux support from Matthew Rickard <mjricka@epoch.ncsc.mil>
800 * bus/selinux.c, bus/selinux.h: new file encapsulating selinux
803 * configure.in: add --enable-selinux
805 * bus/policy.c (bus_policy_merge): add FIXME to a comment
807 * bus/main.c (main): initialize and shut down selinux
809 * bus/connection.c: store SELinux ID on each connection, to avoid
810 repeated getting of the string context and converting it into
813 * bus/bus.c (bus_context_get_policy): new accessor, though it
815 (bus_context_check_security_policy): check whether the security
816 context of sender connection can send to the security context of
819 * bus/config-parser.c: add parsing for <selinux> and <associate>
821 * dbus/dbus-transport.c (_dbus_transport_get_unix_fd): to
822 implement dbus_connection_get_unix_fd()
824 * dbus/dbus-connection.c (dbus_connection_get_unix_fd): new
825 function, used by the selinux stuff
827 2004-07-29 Olivier Andrieu <oliv__a@users.sourceforge.net>
829 * bus/config-loader-libxml.c: complete the implementation of
830 libxml backend for config file loader. Doesn't work with full OOM
833 * configure.in: change error when selecting libxml into a warning.
835 * test/data/invalid-config-files: add two non-well-formed XML
838 * glib/Makefile.am: libdbus_gtool always uses expat, not libxml.
840 * dbus/dbus-transport-unix.c (unix_handle_watch): do not
841 disconnect in case of DBUS_WATCH_HANGUP, several do_reading() may
842 be necessary to read all the buffer. (bug #894)
844 * bus/activation.c (bus_activation_activate_service): fix a
845 potential assertion failure (bug #896). Small optimization in the
846 case of auto-activation messages.
848 * dbus/dbus-message.c (verify_test_message, _dbus_message_test):
849 add test case for byte-through-vararg bug (#901). patch by Kimmo
852 2004-07-28 Anders Carlsson <andersca@gnome.org>
855 * python/dbus_bindings.pyx.in:
856 Add dbus.init_gthreads (), allow emit_signal to pass
857 arguments to the signal.
859 2004-07-24 Havoc Pennington <hp@redhat.com>
861 * AUTHORS: add some people, not really comprehensively, let me
864 2004-07-24 Havoc Pennington <hp@redhat.com>
866 * Makefile.am (DIST_SUBDIRS): add DIST_SUBDIRS, problem solved by
869 * test/Makefile.am (DIST_SUBDIRS): here also
871 2004-07-22 Olivier Andrieu <oliv__a@users.sourceforge.net>
873 * dbus/dbus-sysdeps.c (fill_user_info): fix inexistent label name,
874 breaking build on Solaris, reported by Farhad Saberi on the ML.
876 * dbus/dbus-message.c (dbus_message_append_args_valist): fix the
877 va_arg invocation to account for integer promotion in the case of
878 DBUS_TYPE_BYTE (unsigned char is promoted to int). (bug #901)
880 * bus/services.c (bus_service_remove_owner): fix bug #902, use
881 _dbus_list_get_first_link, not _dbus_list_get_first.
883 * dbus/dbus-bus.c (dbus_bus_service_exists): plug a memory leak.
885 * dbus/dbus-object-tree.c (free_subtree_recurse): always null
886 handler functions so that the asserts in _dbus_object_subtree_unref
889 * dbus/dbus-transport-unix.c (do_reading):
890 _dbus_transport_queue_messages return value is of type
891 dbus_bool_t, not DBusDispatchStatus.
893 2004-07-19 David Zeuthen <david@fubar.dk>
895 * dbus/dbus-protocol.h: Add DBUS_ERROR_UNIX_PROCESS_ID_UNKNOWN
898 (check_get_connection_unix_user): Debug says GetProperty; but the
899 method is called GetConnectionUnixUser
900 (check_get_connection_unix_process_id): New function
901 (bus_dispatch_test): Actually call check_get_connection_unix_user();
902 also call check_get_connection_unix_process_id()
905 (bus_driver_handle_get_connection_unix_process_id): New function,
906 handles GetConnectionUnixProcessID on the org.freedesktop.DBus
910 (handle_server_data_external_mech): Set pid from the credentials
911 obtained from the socket
913 * dbus/dbus-connection.c:
914 (dbus_connection_get_unix_process_id): New function
916 * dbus/dbus-connection.h:
917 Add prototype for dbus_connection_get_unix_process_id
919 * dbus/dbus-transport.c:
920 (_dbus_transport_get_unix_process_id): New function
922 * dbus/dbus-transport.h:
923 Add prototype for _dbus_transport_get_unix_process_id
925 2004-07-19 Olivier Andrieu <oliv__a@users.sourceforge.net>
927 * dbus/dbus-message.c: Message counter fix, patch by Christian
928 Hammond <chipx86@gnupdate.org>
930 2004-07-18 Seth Nickell <seth@gnome.org>
933 * python/dbus_bindings.pyx.in:
934 * python/tests/test-client.py:
936 Add dbus.ByteArray and dbus_bindings.ByteArray
937 types so that byte streams can be passed back.
939 Give jdahlin the heaps of credit that are so
942 2004-07-12 Seth Nickell <seth@gnome.org>
946 Add message argument to the default object_method_handler
949 * python/dbus_bindings.pyx.in:
951 Automatically return NIL when passed an empty list
952 (we can't pass back a list since lists are typed
953 and we don't have any idea what type the the client
954 intended the list to be... :-( )
956 2004-07-10 Seth Nickell <seth@gnome.org>
958 * python/examples/Makefile.am:
960 Fix distcheck breakage caused by new examples.
962 2004-07-10 Seth Nickell <seth@gnome.org>
966 Add "message" argument to service-side dbus.Object
967 methods. This will break existing services written
968 using the python bindings, but will allow extraction
969 of all the message information (e.g. who its from).
971 Add improved "object oriented" signal handling/emission.
973 * python/examples/example-service.py:
977 * python/examples/example-signal-emitter.py:
978 * python/examples/example-signal-recipient.py:
980 Two new examples that show how to emit and receive
981 signals using the new APIs.
983 * python/examples/example-signals.py:
984 * python/examples/gconf-proxy-service.py:
985 * python/examples/gconf-proxy-service2.py:
987 Add "message" argument to service methods.
989 2004-06-28 Kay Sievers <kay.sievers@vrfy.org>
991 * bus/driver.c (bus_driver_handle_get_connection_unix_user)
992 * dbus/bus.c (dbus_bus_get_unix_user)
993 * doc/dbus-specification.xml: implement GetConnectionUnixUser
994 method of org.freedesktop.DBus interface.
996 * bus/dispatch.c: test case
998 2004-06-23 John (J5) Palmieri <johnp@redhat.com>
1000 * python/Makefile.am: switched include directory from glib/ to dbus/
1001 since dbus-glib.h moved
1003 2004-06-22 Olivier Andrieu <oliv__a@users.sourceforge.net>
1005 * configure.in: prevent building the gcj stuff and libxml loader
1006 since they are broken.
1008 2004-06-20 Havoc Pennington <hp@redhat.com>
1010 * dbus/dbus-glib-error-enum.h: autogenerate the GError enum
1011 codes from the dbus error names
1013 * glib/dbus-glib.h: move to subdir dbus/ since it's included
1014 as dbus/dbus-glib.h and that breakage is now visible due to
1015 including dbus/dbus-glib.h in dbus-glib-lowlevel.h
1017 * glib/dbus-glib.h: s/gproxy/g_proxy/
1019 * dbus/dbus-shared.h: new header to hold stuff shared with
1022 * dbus/dbus-protocol.h (DBUS_ERROR_*): move errors here rather
1025 * glib/dbus-glib.h (dbus_set_g_error): move to
1026 dbus-glib-lowlevel.h
1028 * glib/dbus-glib.h: remove dbus/dbus.h from here; change a bunch
1029 of stuff to enable this
1031 * dbus/dbus-glib-lowlevel.h: put dbus/dbus.h here
1033 * a bunch of other changes with the same basic "separate glib
1034 bindings from dbus.h" theme
1036 2004-06-10 Owen Fraser-Green <owen@discobabe.net>
1038 * dbus-sharp.pc.in: Removed glib-sharp inclusion in Libs.
1040 * python/examples/Makefile.am: Fixed typo in EXTRA_DIST.
1042 2004-06-09 Olivier Andrieu <oliv__a@users.sourceforge.net>
1044 * bus/driver.c, dbus/dbus-bus.c: use BOOLEAN instead of UINT32 for
1045 the reply value of the ServiceExists message.
1047 2004-06-07 John (J5) Palmieri <johnp@redhat.com>
1049 * python/dbus_bindings.pyx.in: No longer need to parse path
1050 elements and pass them as arrays of strings. The C API now
1051 accepts plain path strings.
1052 (_build_parsed_path): removed
1054 2004-06-07 Havoc Pennington <hp@redhat.com>
1056 * doc/TODO: remove auto-activation item since it's done; sort
1057 items by importance/milestone
1059 2004-06-07 Havoc Pennington <hp@redhat.com>
1061 * dbus/dbus-message-builder.c (_dbus_message_data_load): append
1062 random signature when using REQUIRED_FIELDS (this hack won't work
1065 * dbus/dbus-message.c: change the signature to be a header field,
1066 instead of message->signature special-case string. Incremental
1067 step forward. Then we can fix up code to send the signature in the
1068 message, then fix up code to validate said signature, then fix up
1069 code to not put the typecodes inline, etc.
1070 (load_one_message): don't make up the signature after the fact
1071 (decode_header_data): require signature field for the known
1074 * dbus/dbus-marshal.c (_dbus_marshal_string_len): new
1076 * dbus/dbus-protocol.h: add DBUS_HEADER_FIELD_SIGNATURE
1078 2004-06-07 Owen Fraser-Green <owen@discobabe.net>
1080 * mono/DBusType/ObjectPath.cs: Renamed PathName argument to Path
1082 * mono/Handler.cs: Updated to follow new path argument for
1083 (un-)registering objects.
1085 * mono/example/Makefile.am:
1087 * configure.in: Bumped required version for mono and use new -pkg
1090 2004-06-05 Olivier Andrieu <oliv__a@users.sourceforge.net>
1092 * dbus/dbus-connection.h, dbus/dbus-connection.c: have object path
1093 registration functions take the path argument as char* instead of
1096 * dbus/dbus-marshal.h, dbus/dbus-marshal.c (_dbus_decompose_path):
1097 split off the path decompostion part of
1098 _dbus_demarshal_object_path. Some misc. fixes to silence compiler
1101 * glib/dbus-gobject.c, test/test-service.c: update accordingly.
1103 2004-06-02 Kristian Høgsberg <krh@redhat.com>
1105 * dbus/dbus-auth.c: Rewrite auth protocol handling to use a state
1106 machine approach. A state is implemented as a function that
1107 handles incoming events as specified for that state.
1109 * doc/dbus-specification.xml: Update auth protocol state machine
1110 specification to match implementation. Remove some leftover
1113 2004-06-02 Kristian Høgsberg <krh@redhat.com>
1115 * glib/dbus-gproxy.c, glib/dbus-gmain.c, dbus/dbus-string.c,
1116 dbus/dbus-object-tree.c, dbus/dbus-message.c: add comments to
1119 * Doxyfile.in: remove deprecated options.
1121 * dbus/dbus-message-handler.c, dbus/dbus-message-handler.h,
1122 glib/test-thread.h, glib/test-thread-client.c,
1123 glib/test-thread-server.c, glib/test-profile.c,
1124 glib/test-dbus-glib.c: remove these unused files.
1126 2004-06-01 Olivier Andrieu <oliv__a@users.sourceforge.net>
1128 * dbus/dbus-object-tree.c
1129 (_dbus_object_tree_dispatch_and_unlock): fix dispatch for
1130 non-fallback handlers (bug #684).
1131 (_dbus_object_subtree_new): initialize invoke_as_fallback field.
1132 (find_subtree_recurse): report wether the returned subtree is an
1133 exact match or a "fallback" match higher up in the tree.
1134 (object_tree_test_iteration): update test case.
1136 2004-06-01 Seth Nickell <seth@gnome.org>
1138 * python/dbus_bindings.pyx.in:
1139 * python/tests/test-client.py:
1141 Round off basic type support. Add dicts (yay!), and
1142 remaining array types.
1144 Make MessageIter more general so it works for dicts too.
1146 Mark all loop variables as C integers.
1148 2004-05-31 Havoc Pennington <hp@redhat.com>
1150 * glib/dbus-gidl.c (method_info_add_arg): keep args sorted with
1153 * glib/dbus-gobject.c (dbus_type_to_string): move to dbus-gutils.c
1155 * glib/dbus-glib-tool.c (main): set up to have a --self-test
1156 option that runs the tests, and start filling in some code
1157 including for starters just dumping the interfaces to stdout
1159 * glib/Makefile.am (INCLUDES): define DBUS_LOCALEDIR
1161 * test/data/valid-introspection-files/lots-of-types.xml: test of
1162 an example introspection file
1164 * glib/dbus-gparser.c (parser_check_doctype): doctype should be
1167 2004-05-31 Seth Nickell <seth@gnome.org>
1169 * python/dbus_bindings.pyx.in:
1170 * python/tests/test-client.py:
1175 Fix string array memory trashing bug... oops...
1177 2004-05-30 Seth Nickell <seth@gnome.org>
1181 Add a nicer-but-less-flexible alternate API for handling
1182 calls to virtual objects in dbus.ObjectTree.
1184 Screw up the argument order to the dbus.Object constructor
1185 for consistency with dbus.ObjectTree (and to make dbus_methods
1186 optional for future extension)
1188 * python/examples/Makefile.am:
1189 * python/examples/gconf-proxy-service.py:
1190 * python/examples/gconf-proxy-service2.py:
1192 Alternate implementation of gconf-proxy-service using the
1193 nicer dbus.ObjectTree API.
1195 * python/examples/example-service.py:
1196 * python/tests/test-server.py
1198 Reverse the argument order to deal with dbus.Object constructor
1201 2004-05-30 Seth Nickell <seth@gnome.org>
1203 * python/examples/example-client.py:
1204 * python/examples/example-service.py:
1206 Take it back. Lists seem to work but they're broken
1207 in the test suite. Make the base examples use
1210 2004-05-30 Seth Nickell <seth@gnome.org>
1212 * python/dbus_bindings.pyx.in:
1213 * python/tests/test-client.py:
1215 Add some more tests and fix errors that crop up.
1216 Unfortunately, currently it seems like marshalling
1217 and unmarshalling of lists is completely broken :-(
1219 2004-05-30 Seth Nickell <seth@gnome.org>
1221 * python/dbus_bindings.pyx.in:
1223 Add support for ObjectPath type.
1227 Refactor message handling code to a common function.
1229 * python/tests/test-client.py:
1230 * python/tests/test-server.py:
1232 Add tests that check to make sure values of all types
1233 can be echoed from a service w/o mangling.
1235 2004-05-29 Seth Nickell <seth@gnome.org>
1239 Add ObjectTree class which allows implementation
1240 of trees of "virtual" objects. Basically the python
1241 wrapper for "register_fallback".
1243 * python/examples/Makefile.am
1244 * python/examples/gconf-proxy-client.py:
1245 * python/examples/gconf-proxy-service.py:
1247 Implement a simple GConf proxy service that supports
1248 get/set on string and int GConf keys using the ObjectTree.
1250 2004-05-29 Seth Nickell <seth@gnome.org>
1253 * python/examples/example-client.py:
1254 * python/examples/example-service.py:
1255 * python/examples/list-system-services.py:
1257 Add SessionBus, SystemBus and ActivationBus classes
1258 so you don't need to know the special little BUS_TYPE
1261 2004-05-29 Havoc Pennington <hp@redhat.com>
1263 * bus/config-parser.c (process_test_valid_subdir): temporarily
1264 stop testing config parser OOM handling, since expat has issues
1265 http://freedesktop.org/pipermail/dbus/2004-May/001153.html
1267 * bus/dbus-daemon-1.1.in: change requested_reply to
1268 send_requested_reply/receive_requested_reply so we can send the
1269 replies, not just receive them.
1271 * bus/config-parser.c: parse the new
1272 send_requested_reply/receive_requested_reply
1274 * bus/policy.c (bus_client_policy_check_can_send): add
1275 requested_reply argument and use it
1277 * bus/bus.c (bus_context_check_security_policy): pass through
1278 requested_reply status to message send check
1280 * bus/system.conf.in: adapt to requested_reply change
1282 2004-05-28 Havoc Pennington <hp@redhat.com>
1284 * test/glib/test-service-glib.c (main): remove unused variable
1286 * glib/dbus-gidl.c (base_info_ref): fix a silly compiler warning
1288 * dbus/dbus-auth.h (enum): remove AUTHENTICATED_WITH_UNUSED_BYTES
1289 from the enum, no longer in use.
1291 * dbus/dbus-sysdeps.h: include config.h so DBUS_VA_COPY actually
1294 * dbus/dbus-message.c: add various _dbus_return_val_if_fail for
1295 whether error_name passed in is a valid error name.
1297 2004-05-28 John (J5) Palmieri <johnp@redhat.com>
1299 * dbus/dbus-message.c (dbus_message_get_args): Added support for
1300 OBJECT_PATH and OBJECT_PATH_ARRAY
1302 2004-05-28 Seth Nickell <seth@gnome.org>
1304 * python/examples/Makefile.am:
1306 Forget to add Makefile.am. Do not pass go.
1308 2004-05-28 Michael Meeks <michael@ximian.com>
1310 * glib/dbus-gvalue.c (dbus_gvalue_marshal, dbus_gvalue_demarshal):
1313 * dbus/dbus-string.c (_dbus_string_parse_basic_type): impl.
1315 * dbus/dbus-message.c (_dbus_message_iter_get_basic_type),
1316 (_dbus_message_iter_get_basic_type_array): impl.
1317 drastically simplify ~all relevant _get methods to use these.
1318 (_dbus_message_iter_append_basic_array),
1319 (dbus_message_iter_append_basic): impl
1320 drastically simplify ~all relevant _append methods to use these.
1322 * dbus/dbus-message-builder.c (parse_basic_type)
1323 (parse_basic_array, lookup_basic_type): impl.
1324 (_dbus_message_data_load): prune scads of duplicate /
1327 * dbus/dbus-marshal.c (_dbus_demarshal_basic_type_array)
1328 (_dbus_demarshal_basic_type): implement,
1329 (demarshal_and_validate_len/arg): beef up debug.
1330 (_dbus_marshal_basic_type, _dbus_marshal_basic_type_array): impl.
1332 2004-05-27 Seth Nickell <seth@gnome.org>
1335 * python/Makefile.am:
1337 Include the example python apps in the tarball.
1339 * python/examples/list-system-services.py
1341 Add a python new example that fetches the list of services
1342 from the system bus.
1344 2004-05-27 Seth Nickell <seth@gnome.org>
1347 * python/dbus_bindings.pyx.in:
1349 Fix failure to notify that a signal was not handled,
1350 resulted in hung functions.
1352 2004-05-25 Colin Walters <walters@redhat.com>
1354 * tools/dbus-monitor.c (main): Monitor all types of messages.
1356 2004-05-23 Owen Fraser-Green <owen@discobabe.net>
1358 * mono/Handler.cs, mono/Service.cs: Added UnregisterObject method
1359 which unregisters the object path and disposes the handler.
1361 2004-05-23 Kristian Høgsberg <krh@redhat.com>
1363 Patch from Timo Teräs <ext-timo.teras@nokia.com> (#614):
1365 * dbus/dbus-message.c (dbus_message_iter_get_args_valist): Swap
1366 operands to && so we call dbus_message_iter_next () for the last
1369 2004-05-21 Olivier Andrieu <oliv__a@users.sourceforge.net>
1371 * dbus/dbus-object-tree.c
1372 (_dbus_object_tree_list_registered_unlock, lookup_subtree): return
1373 children even if the requested path isn't registered.
1374 (object_tree_test_iteration): test object_tree_list_registered.
1376 * configure.in: undefine HAVE_ABSTRACT_SOCKETS instead of defining
1379 2004-05-20 Kristian Høgsberg <krh@redhat.com>
1381 * doc/TODO: Remove resolved items.
1383 * bus/expirelist.h (struct BusExpireList): remove unused n_items
1386 * bus/connection.c (bus_connections_expect_reply): Enforce the
1387 per-connection limit on pending replies.
1389 Patch from Jon Trowbridge <trow@ximian.com>:
1391 * bus/main.c (setup_reload_pipe): Added. Creates a pipe and sets
1392 up a watch that triggers a config reload when one end of the pipe
1394 (signal_handler): Instead of doing the config reload in our SIGHUP
1395 handler, just write to the reload pipe and let the associated
1396 watch handle the reload when control returns to the main loop.
1398 * bus/driver.c (bus_driver_handle_reload_config): Added.
1399 Implements a ReloadConfig method for requesting a configuration
1400 file reload via the bus driver.
1402 2004-05-19 Owen Fraser-Green <owen@discobabe.net>
1404 * HACKING: Updated release instructions concerning the wiki page.
1406 2004-05-18 Kristian Høgsberg <krh@redhat.com>
1408 * dbus/dbus-auth.c (client_try_next_mechanism): Remove logic to
1409 filter against auth->allowed_mechs; we only add allowed mechs in
1410 record_mechanisms().
1412 * dbus/dbus-auth-script.c (_dbus_auth_script_run): Add an
1413 ALLOWED_MECHS to auth-script format so we can set the list of
1416 * data/auth/client-out-of-mechanisms.auth-script: New test to
1417 check client disconnects when it is out of mechanisms to try.
1419 * dbus/dbus-auth.c (process_command): Remove check for lines
1420 longer that 1 MB; we only buffer up maximum 16 kB.
1422 * dbus/dbus-transport.c, dbus/dbus-transport-unix.c,
1423 dbus/dbus-auth-script.c, dbus/dbus-auth.c, dbus/dbus-auth.h:
1424 Remove auth state AUTHENTICATED_WITH_UNUSED_BYTES, instead always
1425 assume there might be unused bytes.
1427 * dbus/dbus-auth.c (_dbus_auth_do_work): Remove check for
1428 client-out-of-mechs, it is handled in process_reject(). Move check
1429 for max failures to send_rejected(), as it's a server-only thing.
1431 * dbus/dbus-auth.c: Factor out protocol reply code into functions
1432 send_auth(), send_data(), send_rejected(), send_error(),
1433 send_ok(), send_begin() and send_cancel().
1435 2004-05-17 Kristian Høgsberg <krh@redhat.com>
1437 Remove base64 encoding, replace with hex encoding. Original patch
1438 from trow@ximian.com, added error handling.
1440 * dbus/dbus-string.c (_dbus_string_base64_encode)
1441 (_dbus_string_base64_decode): Remove.
1442 (_dbus_string_hex_decode): Add end_return argument so we can
1443 distinguish between OOM and invalid hex encoding.
1444 (_dbus_string_test): Remove base64 tests and add test case for
1447 * dbus/dbus-keyring.c, dbus/dbus-auth-script.c, dbus/dbus-auth.c:
1448 Replace base64 with hex.
1450 * test/data/auth/invalid-hex-encoding.auth-script: New test case
1451 for invalid hex encoded data in auth protocol.
1453 2004-05-17 Olivier Andrieu <oliv__a@users.sourceforge.net>
1455 * dbus/dbus-connection.c (check_for_reply_unlocked): plug a memory
1458 2004-05-15 Owen Fraser-Green <owen@discobabe.net>
1460 * mono/dbus-sharp.dll.config.in: Added for GAC
1461 * mono/dbus-sharp.snk: Added for GAC
1462 * mono/Assembly.cs.in: Added for GAC
1463 * mono/Makefile.am: Changes for GAC installation
1464 * configure.in: Added refs for dbus-sharp.dll.config.in and
1465 Assembly.cs.in. More fixes for mono testing
1466 * mono/example/Makefile.am: Changed var to CSC
1467 * Makefile.am: Changed flag name to DBUS_USE_CSC
1469 2004-05-15 Owen Fraser-Green <owen@discobabe.net>
1471 * mono/Makefile.am: Added SUBDIRS for docs. Changed SUBDIRS order
1472 * mono/doc/*: Added documentation framework
1473 * configure.in: Added monodoc check
1474 * README: Added description of mono configure flags
1476 2004-05-11 John (J5) Palmieri <johnp@redhat.com>:
1478 * doc/dbus-specification.xml: Added a "Required" column to the
1479 header fields table and changed the "zero or more" verbage in
1480 the above paragraph to read "The header must contain the required
1481 named header fields and zero or more of the optional named header
1483 * test/data/invalid-messages/*.message: Added the required PATH
1484 named header field to the tests so that they don't fail on
1485 'Missing path field'
1487 2004-05-07 John (J5) Palmieri <johnp@redhat.com>
1489 * python/dbus-bindings.pyx.in: Stopped the bindings from trashing
1490 the stack by implicitly defining variable and parameter types and
1491 removing the hack of defining C pointers as python objects and later
1494 2004-05-02 Owen Fraser-Green <owen@discobabe.net>
1496 * mono/Makefile.am: Removed test-dbus-sharp.exe from all target
1498 2004-05-01 Owen Fraser-Green <owen@discobabe.net>
1500 * mono/DBusType/Dict.cs: Handle empty dicts
1501 * mono/DBusType/Array.cs: Handle empty arrays
1502 * mono/Arguments.cs: Handle empty arguments
1504 2004-04-30 Owen Fraser-Green <owen@discobabe.net>
1506 * dbus-sharp.pc.in: Modified to include include Libs and Requires
1509 2004-04-25 Kristian Høgsberg <krh@redhat.com>
1511 * test/data/valid-messages/standard-*.message: Update message
1512 test scripts to new header field names.
1514 2004-04-22 John (J5) Palmieri <johnp@redhat.com>
1516 * test/break-loader.c (randomly_do_n_things): tracked down buffer
1517 overflow to times_we_did_each_thing array which would chop off the
1518 first character of the failure_dir string. Increased the size of
1519 the array to 7 to reflect the number of random mutation functions
1522 2004-04-21 Kristian Høgsberg <krh@redhat.com>
1524 * dbus/dbus-server-unix.c (unix_finalize): Don't unref
1525 unix_server->watch here, it is unreffed in disconnect.
1526 (_dbus_server_new_for_tcp_socket): convert NULL host to
1527 "localhost" here so we don't append NULL to address.
1529 * dbus/dbus-server.c (_dbus_server_test): Add test case for
1530 various addresses, including tcp with no explicit host.
1532 2004-04-21 Olivier Andrieu <oliv__a@users.sourceforge.net>
1534 * dbus/dbus-message.c (decode_header_data, decode_string_field):
1535 fix incorrect setting of .name_offset in the HeaderField (it was
1536 off by two bytes, positioned right after the name and typecode)
1538 * bus/bus.c (bus_context_new, bus_context_unref): test before
1539 calling dbus_server_free_data_slot and _dbus_user_database_unref
1540 in case of an error.
1542 * tools/Makefile.am: add $(DBUS_GLIB_TOOL_LIBS), xml libs needed
1545 2004-04-19 Kristian Høgsberg <krh@redhat.com>
1547 * dbus/dbus-transport-unix.c (unix_do_iteration): Rewrite to use
1548 _dbus_poll() instead of select().
1550 2004-04-15 Jon Trowbridge <trow@ximian.com>
1552 * bus/main.c (signal_handler): Reload the configuration files
1554 (main): Set up our SIGHUP handler.
1556 * bus/bus.c (struct BusContext): Store the config file, user and
1557 fork flag in the BusContext.
1558 (process_config_first_time_only): Added. Contains the code
1559 (previously in bus_context_new) for setting up the BusContext from
1560 the BusConfigParser that should only be run the first time the
1561 config files are read.
1562 (process_config_every_time): Added. Contains the code (previously
1563 in bus_context_new) for setting up the BusContext from the
1564 BusConfigParser that should be run every time the config files are
1566 (load_config): Added. Builds a BusConfigParser from the config
1567 files and passes the resulting structure off to
1568 process_config_first_time_only (assuming this is the first time)
1569 and process_config_every_time.
1570 (bus_context_new): All of the config-related code has been moved
1571 to process_config_first_time_only and process_config_every_time.
1572 Now this function just does the non-config-related initializations
1573 and calls load_config.
1574 (bus_context_reload_config): Added.
1576 2004-04-15 Olivier Andrieu <oliv__a@users.sourceforge.net>
1578 * bus/driver.c (bus_driver_handle_get_service_owner):
1579 implement a GetServiceOwner method.
1580 * doc/dbus-specification.xml: document it.
1581 * dbus/dbus-errors.h: add a 'ServiceHasNoOwner' error.
1583 * glib/dbus-gproxy.c (dbus_gproxy_new_for_service_owner):
1584 implement, using the bus GetServiceOwner method.
1586 * test/glib/test-dbus-glib.c:
1587 use dbus_gproxy_new_for_service_owner so that we can receive the
1590 2004-04-15 John (J5) Palmieri <johnp@redhat.com>
1592 * dbus/dbus-internals.c, dbus/dbus-message-builder.c,
1593 dbus/dbus-message.c, dbus/dbus-protocol.h
1594 (DBUS_HEADER_FIELD_SERVICE): renamed DBUS_HEADER_FIELD_DESTINATION
1596 * dbus/dbus-internals.c, dbus/dbus-message-builder.c,
1597 dbus/dbus-message.c, dbus/dbus-protocol.h
1598 (DBUS_HEADER_FIELD_SENDER_SERVICE): renamed DBUS_HEADER_FIELD_SENDER
1600 * dbus/dbus-internals.c (_dbus_header_field_to_string):
1601 DBUS_HEADER_FIELD_DESTINATION resolves to "destination"
1602 DBUS_HEADER_FIELD_SENDER resolves to "sender"
1604 * doc/dbus-specification.xml (Header Fields Table):
1605 s/SERVICE/DESTINATION
1606 s/SENDER_SERVICE/SENDER
1609 2004-04-14 Olivier Andrieu <oliv__a@users.sourceforge.net>
1611 * test/glib/test-dbus-glib.c (timed_exit): fail the test after
1614 2004-04-13 Michael Meeks <michael@ximian.com>
1616 * glib/dbus-gobject.c (handle_introspect): split out
1617 (introspect_properties): this.
1618 (handle_introspect): implement this.
1620 * test/glib/Makefile.am: use the absolute path so the bus
1621 daemon's chdir ("/") doesn't kill us dead.
1623 * configure.in: subst ABSOLUTE_TOP_BUILDDIR
1625 2004-04-12 Jon Trowbridge <trow@ximian.com>
1627 * bus/config-parser.c (struct BusConfigParser): Added
1628 included_files field.
1629 (seen_include): Added. Checks whether or not a file has already
1630 been included by any parent BusConfigParser.
1631 (bus_config_parser_new): Copy the parent's included_files.
1632 (include_file): Track which files have been included, and fail on
1633 circular inclusions.
1634 (process_test_valid_subdir): Changed printf to report if we are
1635 testing valid or invalid conf files.
1636 (all_are_equiv): Changed printf to be a bit clearer about
1637 what we are actually doing.
1638 (bus_config_parser_test): Test invalid configuration files.
1640 2004-04-09 Jon Trowbridge <trow@ximian.com>
1642 * bus/config-parser.c (bus_config_parser_new): Added a 'parent'
1643 argument. If non-null, the newly-constructed BusConfigParser will
1644 be initialized with the parent's BusLimits instead of the default
1646 (include_file): When including a config file, pass in
1647 the current parser as the parent and then copy the BusLimits
1648 from the included BusConfigParser pack to the current parser.
1649 (process_test_valid_subdir): Renamed from process_test_subdir.
1650 (process_test_equiv_subdir): Added. Walks through a directory,
1651 descending into each subdirectory and loading the config files
1652 it finds there. If any subdirectory contains two config files
1653 that don't produce identical BusConfigParser structs, fail.
1654 For now, the BusConfigParser's BusPolicies are not compared.
1655 (bus_config_parser_test): Call both process_test_valid_subdir and
1656 process_test_equiv_subdir.
1658 * bus/config-loader-libxml.c (bus_config_load): Take a parent
1659 argument and pass it along to the call to bus_config_parser_new.
1660 Also made a few small changes to allow this code to compile.
1662 * bus/config-loader-expat.c (bus_config_load): Take a parent
1663 argument and pass it along to the call to bus_config_parser_new.
1665 * bus/bus.c (bus_context_new): Load the config file
1666 with a NULL parent argument.
1668 2004-03-29 Michael Meeks <michael@ximian.com>
1670 * glib/dbus-gobject.c (introspect_properties): split
1671 out, fix mangled 'while' flow control.
1672 (introspect_signals): implement.
1673 (handle_introspect): update.
1675 2004-03-29 Michael Meeks <michael@ximian.com>
1677 * glib/dbus-gobject.c (set_object_property): split out /
1678 re-work, use the property type, and not the message type(!)
1679 (get_object_property): ditto.
1681 * glib/dbus-gvalue.c (dbus_gvalue_demarshal),
1682 (dbus_gvalue_marshal): make this code re-usable, needed
1683 for signals too, also on both proxy and server side.
1684 Re-write for more efficiency / readability.
1686 2004-03-29 Michael Meeks <michael@ximian.com>
1688 * dbus/dbus-message.c
1689 (dbus_message_new_error_printf): impl.
1691 * dbus/dbus-connection.c
1692 (dbus_connection_unregister_object_path): fix warning.
1694 * configure.in: fix no-mono-installed situation.
1696 2004-03-27 Havoc Pennington <hp@redhat.com>
1698 Patch from Timo Teräs:
1700 * tools/dbus-send.c (main): if --print-reply, assume type is
1701 method call; support boolean type args
1703 * dbus/dbus-connection.c (dbus_connection_send_with_reply): fix a
1704 bunch of memleak and logic bugs
1706 2004-03-23 Owen Fraser-Green <owen@discobabe.net>
1708 * mono/Arguments.cs:
1709 * mono/Introspector.cs:
1711 * mono/InterfaceProxy.cs:
1713 * mono/ProxyBuilder.cs:
1715 Added InterfaceProxy class to avoid building proxies for every
1719 * dbus-message.c (dbus_message_append_args_valist)
1720 (dbus_message_iter_get_object_path)
1721 (dbus_message_iter_get_object_path_array)
1722 (dbus_message_iter_append_object_path)
1723 (dbus_message_iter_append_object_path_array):
1724 Added object_path iter functions to handle OBJECT_PATH arguments
1726 2004-03-23 Owen Fraser-Green <owen@discobabe.net>
1728 First checkin of mono bindings.
1731 Build stuff for the bindings
1732 * dbus-sharp.pc.in: Added for pkgconfig
1734 2004-03-21 Havoc Pennington <hp@redhat.com>
1736 * test/test-service.c (main): remove debug spew
1738 2004-03-21 Olivier Andrieu <oliv__a@users.sourceforge.net>
1740 * dbus/dbus-marshal.c (_dbus_marshal_validate_arg): accept empty
1743 * dbus/dbus-message.h, bus/dbus-message.c (dbus_message_iter_init)
1744 (dbus_message_iter_init_array_iterator)
1745 (dbus_message_iter_init_dict_iterator): return a dbus_bool_t to
1746 indicate whether the iterator is empty
1748 * dbus/dbus-pending-call.c, dbus/dbus-server.c: silence compiler
1751 2004-03-19 Havoc Pennington <hp@redhat.com>
1753 * NEWS: 0.21 updates
1755 * configure.in: 0.21
1757 * doc/Makefile.am: add all XMLTO usage to DBUS_XML_DOCS_ENABLED
1759 * python/Makefile.am: change to avoid dist of dbus_bindings.c so
1760 you don't need pyrex to make dist
1762 * qt/Makefile.am (libdbus_qt_1_la_SOURCES): add integrator.h to
1765 2004-03-18 Richard Hult <richard@imendio.com>
1767 * dbus/dbus-message.c (dbus_message_get_auto_activation)
1768 (dbus_message_set_auto_activation): Add doxygen docs.
1770 2004-03-16 Richard Hult <richard@imendio.com>
1772 * bus/activation.c: (bus_activation_service_created),
1773 (bus_activation_send_pending_auto_activation_messages),
1774 (bus_activation_activate_service):
1776 * bus/dispatch.c: (bus_dispatch),
1777 (check_nonexistent_service_auto_activation),
1778 (check_service_auto_activated),
1779 (check_segfault_service_auto_activation),
1780 (check_existent_service_auto_activation), (bus_dispatch_test):
1781 * bus/driver.c: (bus_driver_handle_activate_service):
1782 * bus/services.c: (bus_registry_acquire_service):
1783 * dbus/dbus-message.c: (dbus_message_set_auto_activation),
1784 (dbus_message_get_auto_activation):
1785 * dbus/dbus-message.h:
1786 * dbus/dbus-protocol.h: Implement auto-activation.
1788 * doc/dbus-specification.xml: Add auto-activation to the spec.
1790 2004-03-12 Olivier Andrieu <oliv__a@users.sourceforge.net>
1792 * dbus/dbus-marshal.c (_dbus_marshal_get_arg_end_pos):
1793 fix a bug with CUSTOM types.
1795 * dbus/dbus-message.c (message_iter_test, _dbus_message_test): add
1796 a unit test for this bug (used to fail).
1798 2004-03-12 Mikael Hallendal <micke@imendio.com>
1801 (babysitter_watch_callback): notify all pending activations waiting for
1802 the same exec that the activation failed.
1803 (bus_activation_activate_service): shortcut the activation if we
1804 already waiting for the same executable to start up.
1806 2004-03-12 Mikael Hallendal <micke@imendio.com>
1809 - Added service file reloading.
1810 Each service files directory is kept in an hash table in
1811 BusActivation and each BusActivationEntry knows what .service-file it
1812 was read from. So when you try to activate a service the bus will
1813 check if it's been updated, removed or if new .service-files has
1815 - Test code at the bottom for the service file reloading.
1816 * bus/test-main.c: (main):
1818 - added service reloading test.
1819 * dbus/dbus-sysdeps.c:
1820 * dbus/dbus-sysdeps.h: (_dbus_delete_directory): Added.
1822 2004-03-08 Michael Meeks <michael@ximian.com>
1824 * dbus/dbus-connection.c (_dbus_connection_block_for_reply):
1825 bail immediately if disconnected, to avoid busy loop.
1827 * dbus/dbus-message.c (dbus_message_iter_get_args_valist):
1828 cleanup cut/paste/inefficiency.
1830 2004-03-01 David Zeuthen <david@fubar.dk>
1832 * dbus/dbus-string.c (_dbus_string_append_printf_valist): Fix a
1833 bug where args were used twice. This bug resulted in a segfault
1834 on a Debian/PPC system when starting the messagebus daemon. Include
1835 dbus-sysdeps.h for DBUS_VA_COPY
1837 * dbus/dbus-sysdeps.h: Define DBUS_VA_COPY if neccessary. From GLib
1839 * configure.in: Check for va_copy; define DBUS_VA_COPY to the
1840 appropriate va_copy implementation. From GLib
1842 2004-02-24 Joe Shaw <joe@ximian.com>
1844 * bus/services.c (bus_registry_acquire_service): We need to pass
1845 in the service name to dbus_set_error() to prevent a crash.
1847 2003-12-26 Anders Carlsson <andersca@gnome.org>
1849 * AUTHORS: Reveal my True identity.
1851 2003-12-17 Mikael Hallendal <micke@imendio.com>
1853 * dbus/dbus-message.c: (dbus_message_append_args_valist):
1854 - Added case for DBUS_TYPE_BYTE, patch from Johan Hedberg.
1856 2003-12-13 Mikael Hallendal <micke@imendio.com>
1858 * doc/TODO: Added not about better error check of configuration files.
1860 2003-12-02 Richard Hult <richard@imendio.com>
1862 * Update AFL version to 2.0 throughout the source files to reflect
1863 the update that was done a while ago.
1865 2003-12-02 Richard Hult <richard@imendio.com>
1867 * dbus/dbus-message.c (dbus_message_iter_append_dict): Set
1868 wrote_dict_key to FALSE on the iter that the dict is appended to,
1869 just like when appending other types. Fixes a bug where a dict
1870 couldn't be put inside a dict.
1871 (dbus_message_iter_append_dict_key): Fix typo in warning message.
1872 (message_iter_test, _dbus_message_test): Add test case for dict
1875 2003-12-01 David Zeuthen <david@fubar.dk>
1877 * python/dbus.py: Add the actual message when calling the reciever
1878 of a signal such that parameters can be inspected. Add the method
1879 remove_signal_receiver
1881 2003-11-26 Mikael Hallendal <micke@imendio.com>
1885 * glib/*.[ch]: Made ref functions return the pointer
1887 2003-11-25 Zack Rusin <zack@kde.org>
1889 * qt/integrator.h, qt/integrator.cpp: Adding handling of DBusServer,
1891 * qt/server.h, qt/server.cpp, qt/Makefile.am: Adding DBusServer
1894 * qt/connection.h, qt/connection.cpp: Adjusting to changes in
1895 the Integrator and to better fit with the server,
1897 2003-11-24 Zack Rusin <zack@kde.org>
1899 * qt/connection.h, qt/connection.cpp: removing initDbus method since
1900 the integrator handles it now
1902 * qt/integrator.h, qt/integrator.cpp: reworking handling of timeouts,
1903 since QTimer wasn't really meant to be used the way DBusTimeout is
1905 2003-11-24 Zack Rusin <zack@kde.org>
1907 * qt/integrator.h, qt/integrator.cpp, Makefile.am: Adding
1908 Integrator class which integrates D-BUS with the Qt event loop,
1910 * qt/connection.h, qt/connection.cpp: Move all the code which
1911 was dealing with D-BUS integration to the Integrator class,
1912 and start using Integrator,
1914 2003-11-23 Zack Rusin <zack@kde.org>
1916 * qt/connection.h, qt/connection.cpp: Adding the DBusConnection
1919 * qt/message.h, qt/message.cpp: updating to the current D-BUS api,
1920 switching namespaces to DBusQt, reworking the class,
1922 * Makefile.cvs: switching dependencies so that it matches KDE
1925 * qt/Makefile.am: adding connection.{h,cpp} and message.{h,cpp} to
1928 2003-11-19 Havoc Pennington <hp@redhat.com>
1932 * configure.in: bump version to 0.20
1934 * configure.in (have_qt): add yet another place to look for qt
1935 (someone hand trolltech a .pc file...)
1937 2003-11-01 Havoc Pennington <hp@redhat.com>
1939 * doc/dbus-specification.xml: add state machine docs on the auth
1940 protocol; just a first draft, I'm sure it's wrong.
1942 2003-10-28 David Zeuthen <david@fubar.dk>
1944 * python/dbus_bindings.pyx.in: add get_dict to handle dictionaries
1945 return types. Fixup TYPE_* to reflect changes in dbus/dbus-protocol.h
1947 2003-10-28 Havoc Pennington <hp@redhat.com>
1949 * dbus/dbus-message.c (get_next_field): delete unused function
1951 2003-10-28 Havoc Pennington <hp@redhat.com>
1953 * bus/expirelist.c (do_expiration_with_current_time): detect
1954 failure of the expire_func due to OOM
1956 * bus/connection.c (bus_pending_reply_expired): return FALSE on OOM
1958 * bus/dispatch.c (check_send_exit_to_service): fix to handle the
1959 NoReply error that's now created by the bus when the service exits
1961 2003-10-28 Havoc Pennington <hp@redhat.com>
1963 * dbus/dbus-message.c (_dbus_message_test): enable and fix the
1964 tests for set_path, set_interface, set_member, etc.
1966 * dbus/dbus-string.c (_dbus_string_insert_bytes): allow 0 bytes
1968 * dbus/dbus-message.c (set_string_field): always just delete and
1969 re-append the field; accept NULL for deletion
1970 (re_align_fields_recurse): reimplement
1972 2003-10-26 Havoc Pennington <hp@redhat.com>
1974 * dbus/dbus-connection.c: fix docs to properly describe the
1975 disconnected message
1976 (_dbus_connection_notify_disconnected): remove this function;
1977 we can't synchronously add the disconnected message, we have to
1978 do it after we've queued any remaining real messages
1979 (_dbus_connection_get_dispatch_status_unlocked): queue the
1980 disconnect message only if the transport has finished queueing all
1981 its real messages and is disconnected.
1982 (dbus_connection_disconnect): update the dispatch status here
1984 2003-10-22 Havoc Pennington <hp@redhat.com>
1986 * bus/bus.c (bus_context_check_security_policy): fix up assertion
1988 * bus/connection.c (bus_transaction_send_from_driver): set the
1989 destination to the connection's base service
1991 2003-10-20 Havoc Pennington <hp@redhat.com>
1993 hmm, make check is currently not passing.
1995 * doc/dbus-specification.xml: add requirement that custom type
1996 names follow the same rules as interface names.
1998 * dbus/dbus-protocol.h: change some of the byte codes, to avoid
1999 duplication and allow 'c' to be 'custom'; dict is now 'm' for
2002 * doc/dbus-specification.xml: update type codes to match
2003 dbus-protocol.h, using the ASCII byte values. Rename type NAMED to
2004 CUSTOM. Add type OBJECT_PATH to the spec.
2006 2003-10-17 Havoc Pennington <hp@redhat.com>
2008 * bus/driver.c (create_unique_client_name): use "." as separator
2009 in base service names instead of '-'
2011 * dbus/dbus-string.c (_dbus_string_get_byte): allow getting nul
2012 byte at the end of the string
2014 * dbus/dbus-internals.h (_DBUS_LIKELY, _DBUS_UNLIKELY): add
2015 optimization macros since string validation seems to be a slow
2018 * doc/dbus-specification.xml: restrict valid
2019 service/interface/member/error names. Add test suite code for the
2022 * dbus/dbus-string.c: limit service/interface/member/error names
2025 * dbus/dbus-connection.c (dbus_connection_dispatch): add missing
2026 format arg to verbose spew
2028 * glib/dbus-gproxy.c (dbus_gproxy_call_no_reply): if not out of
2029 memory, return instead of g_error
2031 * test/test-service.c (path_message_func): support emitting a
2034 * dbus/dbus-bus.c (init_connections_unlocked): only fill in
2035 activation bus type if DBUS_BUS_ACTIVATION was set; default to
2036 assuming the activation bus was the session bus so that services
2037 started manually will still register.
2038 (init_connections_unlocked): fix so that in OOM situation we get
2039 the same semantics when retrying the function
2041 * test/test-service.c (main): change to use path registration, to
2042 test those codepaths; register with DBUS_BUS_ACTIVATION rather
2043 than DBUS_BUS_SESSION
2045 2003-10-16 Havoc Pennington <hp@redhat.com>
2047 * glib/dbus-gtest-main.c: bracket with #ifdef DBUS_BUILD_TESTS
2049 * Makefile.am (GCOV_DIRS): remove "test", we don't care about test
2050 coverage of the tests
2051 (coverage-report.txt): don't move the .da and .bbg files around
2053 2003-10-16 Havoc Pennington <hp@redhat.com>
2055 * bus/bus.c (struct BusContext): remove struct field I didn't mean
2058 2003-10-16 Havoc Pennington <hp@redhat.com>
2060 * bus/connection.c (bus_pending_reply_expired): either cancel or
2062 (bus_connections_check_reply): use unlink, not remove_link, as we
2063 don't want to free the link; fixes double free mess
2065 * dbus/dbus-pending-call.c (dbus_pending_call_block): fix in case
2066 where no reply was received
2068 * dbus/dbus-connection.c (_dbus_pending_call_complete_and_unlock):
2071 * bus/signals.c (match_rule_matches): add special cases for the
2072 bus driver, so you can match on sender/destination for it.
2074 * dbus/dbus-sysdeps.c (_dbus_abort): print backtrace if
2075 DBUS_PRINT_BACKTRACE is set
2077 * dbus/dbus-internals.c: add pid to assertion failure messages
2079 * dbus/dbus-connection.c: add message type code to the debug spew
2081 * glib/dbus-gproxy.c (gproxy_get_match_rule): match rules want
2082 sender=foo not service=foo
2084 * dbus/dbus-bus.c (dbus_bus_get): if the activation bus is the
2085 session bus but DBUS_SESSION_BUS_ADDRESS isn't set, use
2086 DBUS_ACTIVATION_ADDRESS instead
2088 * bus/activation.c: set DBUS_SESSION_BUS_ADDRESS,
2089 DBUS_SYSTEM_BUS_ADDRESS if appropriate
2091 * bus/bus.c (bus_context_new): handle OOM copying bus type into
2094 * dbus/dbus-message.c (dbus_message_iter_get_object_path): new function
2095 (dbus_message_iter_get_object_path_array): new function (half
2096 finished, disabled for the moment)
2098 * glib/dbus-gproxy.c (dbus_gproxy_end_call): properly handle
2099 DBUS_MESSAGE_TYPE_ERROR
2101 * tools/dbus-launch.c (babysit): support DBUS_DEBUG_OUTPUT to
2102 avoid redirecting stderr to /dev/null
2103 (babysit): close stdin if not doing the "exit_with_session" thing
2105 * dbus/dbus-sysdeps.c (_dbus_become_daemon): delete some leftover
2106 debug code; change DBUS_DEBUG_OUTPUT to only enable stderr, not
2107 stdout/stdin, so things don't get confused
2109 * bus/system.conf.in: fix to allow replies, I modified .conf
2110 instead of .conf.in again.
2112 2003-10-14 David Zeuthen <david@fubar.dk>
2114 * python/dbus_bindings.pyx.in (MessageIter.get): fixed typo in
2115 argtype to arg_type when raising unknown arg type exception.
2116 Changed type list to reflect the changes in dbus-protocol.h so
2117 the bindings actually work.
2119 2003-10-14 Havoc Pennington <hp@redhat.com>
2121 * test/decode-gcov.c: support gcc 3.3 also, though gcc 3.3 seems
2122 to have a bug keeping it from outputting the .da files sometimes
2123 (string_get_string): don't append garbage nul bytes to the string.
2125 2003-10-15 Seth Nickell <seth@gnome.org>
2127 * python/Makefile.am:
2129 Include dbus_h_wrapper.h in the dist tarball.
2131 2003-10-14 Havoc Pennington <hp@redhat.com>
2133 * bus/bus.c (bus_context_check_security_policy): revamp this to
2134 work more sanely with new policy-based requested reply setup
2136 * bus/connection.c (bus_transaction_send_from_driver): set bus
2137 driver messages as no reply
2139 * bus/policy.c (bus_client_policy_check_can_receive): handle a
2140 requested_reply attribute on allow/deny rules
2142 * bus/system.conf: add <allow requested_reply="true"/>
2144 * bus/driver.c (bus_driver_handle_message): fix check for replies
2145 sent to the bus driver, which was backward. How did this ever work
2146 at all though? I think I'm missing something.
2148 * dbus/dbus-message.c (decode_header_data): require error and
2149 method return messages to have a reply serial field to be valid
2150 (_dbus_message_loader_queue_messages): break up this function;
2151 validate that reply serial and plain serial are nonzero;
2152 clean up the OOM/error handling.
2153 (get_uint_field): don't return -1 from this
2154 (dbus_message_create_header): fix signed/unsigned bug
2156 * bus/connection.c (bus_connections_expect_reply): save serial of
2157 the incoming message, not reply serial
2159 2003-10-14 Havoc Pennington <hp@redhat.com>
2161 * bus/connection.c: implement pending reply tracking using
2164 * bus/bus.c (bus_context_check_security_policy): verify that a
2165 reply is pending in order to allow a reply to be sent. Deny
2166 messages of unknown type.
2168 * bus/dbus-daemon-1.1.in: update to mention new resource limits
2170 * bus/bus.c (bus_context_get_max_replies_per_connection): new
2171 (bus_context_get_reply_timeout): new
2173 2003-10-13 Seth Nickell <seth@gnome.org>
2175 * python/Makefile.am:
2177 Pass "make distcheck": remove a couple files from DIST_FILES
2178 that weren't included in the final version.
2180 2003-10-12 Havoc Pennington <hp@pobox.com>
2182 Added test code that 1) starts an actual bus daemon and 2) uses
2183 DBusGProxy; fixed bugs that were revealed by the test. Lots
2184 more testing possible, but this is the basic framework.
2186 * glib/dbus-gproxy.c (dbus_gproxy_manager_unregister): remove
2187 empty proxy lists from the proxy list hash
2189 * dbus/dbus-message.c (dbus_message_iter_get_args_valist): add a
2190 couple of return_if_fail checks
2192 * dbus/dbus-pending-call.c (_dbus_pending_call_new): use dbus_new0
2193 to allocate, so everything is cleared to NULL as it should be.
2195 * glib/dbus-gmain.c (dbus_connection_setup_with_g_main): pass
2196 source as data to dbus_connection_set_timeout_functions() as the
2197 timeout functions expected
2199 * test/glib/run-test.sh: add a little script to start up a message
2200 bus and run tests using it
2202 * tools/dbus-launch.1: updates
2204 * tools/dbus-launch.c (main): add --config-file option
2206 * tools/dbus-launch.c (main): remove confusing else if (runprog)
2207 that could never be reached.
2209 * dbus/dbus-message.c (dbus_message_new_method_return)
2210 (dbus_message_new_error, dbus_message_new_signal): set the
2211 no-reply-expected flag on all these. Redundant, but may
2212 as well be consistent.
2214 2003-10-11 Havoc Pennington <hp@pobox.com>
2216 * test/decode-gcov.c (function_solve_graph): make broken block
2217 graph a nonfatal error since it seems to be broken. Need to debug
2220 * dbus/dbus-marshal.c (_dbus_type_is_valid): new function since we
2221 can't just check type > INVALID < LAST anymore
2223 * dbus/dbus-message.c (dbus_message_get_signature): new function
2224 (dbus_message_has_signature): new function
2225 (struct DBusMessage): add signature field (right now it isn't sent
2226 over the wire, just generated on the fly)
2227 (dbus_message_copy): copy the signature, and init strings to
2228 proper length to avoid some reallocs
2229 (dbus_message_iter_init_array_iterator): return void, since it
2231 (dbus_message_iter_init_dict_iterator): return void since it can't fail
2232 (_dbus_message_loader_queue_messages): add silly temporary hack to
2233 fill in message->signature on load
2235 * dbus/dbus-protocol.h: change DBUS_TYPE_* values to be ASCII
2236 characters, so they are relatively human-readable.
2238 2003-10-11 Havoc Pennington <hp@pobox.com>
2240 * dbus/dbus-message.c (_dbus_message_test): add more test
2241 coverage, but #if 0 for now since they uncover a bug
2242 not fixed yet; I think in re_align_field_recurse()
2243 (re_align_field_recurse): add FIXME about broken assertion
2245 * dbus/dbus-sysdeps.c (_dbus_sysdeps_test): add more test coverage
2247 * bus/connection.c: share a couple code bits with expirelist.c
2249 * bus/expirelist.h, bus/expirelist.c: implement a generic
2250 expire-items-after-N-seconds facility, was going to share between
2251 expiring connections and replies, decided not to use for expiring
2252 connections for now.
2254 * COPYING: include AFL 2.0 (still need to change all the file headers)
2256 2003-10-09 Havoc Pennington <hp@redhat.com>
2258 * configure.in: define DBUS_HAVE_GCC33_GCOV if we have
2259 gcc 3.3. Not that we do anything about it yet.
2261 * bus/signals.c (bus_match_rule_parse): impose max length on the
2264 * dbus/dbus-protocol.h: add DBUS_MAXIMUM_MATCH_RULE_LENGTH
2266 2003-10-09 Havoc Pennington <hp@redhat.com>
2268 Make matching rules theoretically work (add parser).
2270 * bus/bus.c (bus_context_check_security_policy): fix up to handle
2271 the case where destination is explicitly specified as bus driver
2272 and someone else is eavesdropping.
2274 * bus/policy.c (bus_client_policy_check_can_receive): fix up
2275 definition of eavesdropping and assertion
2277 * tools/dbus-send.c (main): use dbus_message_type_from_string
2279 * bus/signals.c (bus_match_rule_parse): implement
2281 * dbus/dbus-message.c (dbus_message_type_from_string): new
2283 * dbus/dbus-errors.h (DBUS_ERROR_MATCH_RULE_INVALID): add
2285 2003-10-02 Havoc Pennington <hp@pobox.com>
2287 * glib/dbus-gproxy.c (dbus_gproxy_call_no_reply): rename from
2288 dbus_gproxy_oneway_call
2290 * glib/dbus-gmain.c (dbus_connection_setup_with_g_main)
2291 (dbus_server_setup_with_g_main): fix to allow calling them more
2292 than once on the same args
2293 (dbus_bus_get_with_g_main): new function
2295 2003-10-02 Havoc Pennington <hp@redhat.com>
2297 * doc/dbus-tutorial.xml: write some stuff
2299 2003-09-29 Havoc Pennington <hp@pobox.com>
2301 * configure.in: split checks for Doxygen from XML docs, check for
2304 * doc/Makefile.am: XML-ify all the docs, and add a blank
2307 2003-09-29 Havoc Pennington <hp@pobox.com>
2309 * Merge dbus-object-names branch. To see the entire patch
2310 do cvs diff -r DBUS_OBJECT_NAMES_BRANCHPOINT -r dbus-object-names,
2311 it's huuuuge though.
2312 To revert, I tagged DBUS_BEFORE_OBJECT_NAMES_MERGE.
2314 2003-09-28 Havoc Pennington <hp@pobox.com>
2316 * HACKING: update to reflect new server
2318 2003-09-26 Seth Nickell <seth@gnome.org>
2321 * python/examples/example-signals.py:
2323 Start implementing some notions of signals. The API
2324 is really terrible, but they sort of work (with the
2325 exception of being able to filter by service, and to
2326 transmit signals *as* a particular service). Need to
2327 figure out how to make messages come from the service
2330 * python/dbus_bindings.pyx.in:
2332 Removed duplicate message_handler callbacks.
2334 2003-09-25 Havoc Pennington <hp@redhat.com>
2336 * bus/session.conf.in: fix my mess
2338 2003-09-25 Havoc Pennington <hp@pobox.com>
2340 * bus/session.conf.in: fix security policy, reported by Seth Nickell
2342 2003-09-25 Seth Nickell <seth@gnome.org>
2344 * python/examples/example-service.py:
2346 Johan notices complete wrong code in example-service, but
2347 completely wrong in a way that works exactly the same (!).
2348 Johan is confused, how could this possibly work? Example
2349 code fails to serve purpose of making things clear.
2352 2003-09-25 Mark McLoughlin <mark@skynet.ie>
2354 * doc/dbus-specification.sgml: don't require header fields
2355 to be 4-byte aligned and specify that fields should be
2356 distinguished from padding by the fact that zero is not
2359 * doc/TODO: remove re-alignment item and add item to doc
2360 the OBJECT_PATH type.
2362 * dbus/dbus-message.c:
2363 (HeaderField): rename the original member to value_offset
2364 and introduce a name_offset member to keep track of where
2365 the field actually begins.
2366 (adjust_field_offsets): remove.
2367 (append_int_field), (append_uint_field),
2368 (append_string_field): don't align the start of the header
2369 field to a 4-byte boundary.
2370 (get_next_field): impl finding the next marhsalled field
2371 after a given field.
2372 (re_align_field_recurse): impl re-aligning a number of
2373 already marshalled fields.
2374 (delete_field): impl deleting a field of any type and
2375 re-aligning any following fields.
2376 (delete_int_or_uint_field), (delete_string_field): remove.
2377 (set_int_field), (set_uint_field): no need to re-check
2378 that we have the correct type for the field.
2379 (set_string_field): ditto and impl re-aligning any
2381 (decode_header_data): update to take into account that
2382 the fields aren't 4-byte aligned any more and the new
2383 way to distinguish padding from header fields. Also,
2384 don't exit when there is too much header padding.
2385 (process_test_subdir): print the directory.
2386 (_dbus_message_test): add test to make sure a following
2387 field is re-aligned correctly after field deletion.
2389 * dbus/dbus-string.[ch]:
2390 (_dbus_string_insert_bytes): rename from insert_byte and
2391 allow the insert of multiple bytes.
2392 (_dbus_string_test): test inserting multiple bytes.
2394 * dbus/dbus-marshal.c: (_dbus_marshal_set_string): add
2395 warning note to docs about having to re-align any
2396 marshalled values following the string.
2398 * dbus/dbus-message-builder.c:
2399 (append_string_field), (_dbus_message_data_load):
2400 don't align the header field.
2402 * dbus/dbus-auth.c: (process_test_subdir): print the
2405 * test/break-loader.c: (randomly_add_one_byte): upd. for
2408 * test/data/invalid-messages/bad-header-field-alignment.message:
2411 * test/data/valid-messages/unknown-header-field.message: shove
2412 a dict in the unknown field.
2414 2003-09-25 Seth Nickell <seth@gnome.org>
2417 * python/dbus_bindings.pyx.in:
2419 Handle return values.
2421 * python/examples/example-client.py:
2422 * python/examples/example-service.py:
2424 Pass back return values from the service to the client.
2426 2003-09-24 Seth Nickell <seth@gnome.org>
2430 Connect Object methods (when you are sharing an object) up... pass
2431 in a list of methods to be shared. Sharing all the methods just
2432 worked out too weird. You can now create nice Services over the
2435 * python/dbus_bindings.pyx.in:
2437 Keep references to user_data tuples passed into C functions so
2438 Python doesn't garbage collect on us.
2440 Implement MethodReturn and Error subclasses of Message for creating
2441 DBusMessage's of those types.
2443 * python/examples/example-client.py:
2444 * python/examples/example-service.py:
2446 Simple example code showing both how create DBus services and objects,
2447 and how to use them.
2449 2003-09-23 Havoc Pennington <hp@pobox.com>
2451 * glib/dbus-gproxy.c (dbus_gproxy_manager_filter): implement
2453 2003-09-23 Havoc Pennington <hp@redhat.com>
2455 * glib/dbus-gproxy.c (dbus_gproxy_connect_signal): implement
2456 (dbus_gproxy_disconnect_signal): implement
2457 (dbus_gproxy_manager_remove_signal_match): implement
2458 (dbus_gproxy_manager_add_signal_match): implement
2459 (dbus_gproxy_oneway_call): implement
2461 2003-09-23 Havoc Pennington <hp@pobox.com>
2463 * glib/dbus-gproxy.c (struct DBusGProxy): convert to a GObject
2464 subclass. This means dropping the transparent thread safety of the
2465 proxy; you now need a separate proxy per-thread, or your own
2466 locking on the proxy. Probably right anyway.
2467 (dbus_gproxy_ref, dbus_gproxy_unref): nuke, just use g_object_ref
2469 2003-09-22 Havoc Pennington <hp@redhat.com>
2471 * glib/dbus-gproxy.c (dbus_gproxy_manager_get): implement
2473 2003-09-21 Seth Nickell <seth@gnome.org>
2475 First checkin of the Python bindings.
2477 * python/.cvsignore:
2478 * python/Makefile.am:
2479 * python/dbus_bindings.pyx.in:
2480 * python/dbus_h_wrapper.h:
2482 Pieces for Pyrex to operate on, building a dbus_bindings.so
2483 python module for low-level access to the DBus APIs.
2487 High-level Python module for accessing DBus objects.
2492 Build stuff for the python bindings.
2496 Extra macro needed for finding the Python C header files.
2498 2003-09-21 Havoc Pennington <hp@pobox.com>
2500 * glib/dbus-gproxy.c (dbus_gproxy_manager_new): start
2501 implementing the proxy manager, didn't get very far.
2503 * dbus/dbus-bus.c (dbus_bus_add_match): new
2504 (dbus_bus_remove_match): new
2506 * glib/dbus-gproxy.c (dbus_gproxy_new_for_service): add a
2507 path_name argument; adjust the other not-yet-implemented
2508 gproxy constructors to be what I think they should be.
2510 2003-09-21 Havoc Pennington <hp@pobox.com>
2512 * dbus/dbus-bus.c (dbus_bus_get): set exit_on_disconnect to TRUE
2513 by default for message bus connections.
2515 * dbus/dbus-connection.c (dbus_connection_dispatch): exit if
2516 exit_on_disconnect flag is set and we process the disconnected
2518 (dbus_connection_set_exit_on_disconnect): new function
2520 2003-09-21 Havoc Pennington <hp@pobox.com>
2522 Get matching rules mostly working in the bus; only actually
2523 parsing the rule text remains. However, the client side of
2524 "signal connections" hasn't been started, this patch is only the
2527 * dbus/dispatch.c: fix for the matching rules changes
2529 * bus/driver.c (bus_driver_handle_remove_match)
2530 (bus_driver_handle_add_match): send an ack reply from these
2533 * glib/dbus-gproxy.c (dbus_gproxy_begin_call): fix order of
2534 arguments, reported by Seth Nickell
2536 * bus/config-parser.c (append_rule_from_element): support
2537 eavesdrop=true|false attribute on policies so match rules
2538 can be prevented from snooping on the system bus.
2540 * bus/dbus-daemon-1.1.in: consistently use terminology "sender"
2541 and "destination" in attribute names; fix some docs bugs;
2542 add eavesdrop=true|false attribute
2544 * bus/driver.c (bus_driver_handle_add_match)
2545 (bus_driver_handle_remove_match): handle AddMatch, RemoveMatch
2548 * dbus/dbus-protocol.h (DBUS_SERVICE_ORG_FREEDESKTOP_BROADCAST): get
2549 rid of broadcast service concept, signals are just always broadcast
2551 * bus/signals.c, bus/dispatch.c, bus/connection.c, bus/bus.c:
2552 mostly implement matching rules stuff (currently only exposed as signal
2555 2003-09-21 Mark McLoughlin <mark@skynet.ie>
2557 * doc/dbus-specification.sgml: Change the header field name
2558 to be an enum and update the rest of the spec to reference
2559 the fields using the conventinal name.
2561 * dbus/dbus-protocol.h: update to reflect the spec.
2563 * doc/TODO: add item to remove the 4 byte alignment requirement.
2565 * dbus/dbus-message.c: Remove the code to generalise the
2566 header/body length and serial number header fields as named
2567 header fields so we can reference field names using the
2569 (append_int_field), (append_uint_field), (append_string_field):
2570 Append the field name as a byte rather than four chars.
2571 (delete_int_or_uint_field), (delete_string_field): reflect the
2572 fact that the field name and typecode now occupy 4 bytes instead
2574 (decode_string_field), (decode_header_data): update to reflect
2575 protocol changes and move the field specific encoding from
2576 decode_string_field() back into decode_header_data().
2578 * dbus/dbus-internals.[ch]: (_dbus_header_field_to_string):
2579 Add utility to aid debugging.
2581 * dbus/dbus-message-builder.c:
2582 (append_string_field), (_dbus_message_data_load): Update to
2583 reflect protocol changes; Change the FIELD_NAME directive
2584 to HEADER_FIELD and allow it to take the field's conventional
2585 name rather than the actual value.
2587 * test/data/*/*.message: Update to use HEADER_FIELD instead
2588 of FIELD_NAME; Always align the header on an 8 byte boundary
2589 *before* updating the header length.
2591 2003-09-15 Havoc Pennington <hp@pobox.com>
2593 * dbus/dbus-pending-call.c: add the get/set object data
2594 boilerplate as for DBusConnection, etc. Use generic object data
2595 for the notify callback.
2597 * glib/dbus-gparser.c (parse_node): parse child nodes
2599 * tools/dbus-viewer.c: more hacking on the dbus-viewer
2601 * glib/dbus-gutils.c (_dbus_gutils_split_path): add a file to
2602 contain functions shared between the convenience lib and the
2605 * glib/Makefile.am (libdbus_glib_1_la_LDFLAGS): add
2606 -export-symbols-regex to the GLib library
2608 * dbus/dbus-object-tree.c (_dbus_object_tree_dispatch_and_unlock):
2609 fix the locking in here, and add a default handler for
2610 Introspect() that just returns sub-nodes.
2612 2003-09-14 Havoc Pennington <hp@pobox.com>
2614 * glib/dbus-gthread.c (dbus_g_thread_init): rename to make g_foo
2615 rather than gfoo consistent
2617 * glib/dbus-gproxy.h: delete for now, move contents to
2618 dbus-glib.h, because the include files don't work right since we
2619 aren't in the dbus/ subdir.
2621 * glib/dbus-gproxy.c (dbus_gproxy_send): finish implementing
2622 (dbus_gproxy_end_call): finish
2623 (dbus_gproxy_begin_call): finish
2625 * glib/dbus-gmain.c (dbus_set_g_error): new
2627 * glib/dbus-gobject.c (handle_introspect): include information
2628 about child nodes in the introspection
2630 * dbus/dbus-connection.c (dbus_connection_list_registered): new
2631 function to help in implementation of introspection
2633 * dbus/dbus-object-tree.c
2634 (_dbus_object_tree_list_registered_and_unlock): new function
2636 2003-09-12 Havoc Pennington <hp@pobox.com>
2638 * glib/dbus-gidl.h: add common base class for all the foo_info
2641 * tools/dbus-viewer.c: add GTK-based introspection UI thingy
2644 * test/Makefile.am: try test srcdir -ef . in addition to test
2645 srcdir = ., one of them should work (yeah lame)
2647 * glib/Makefile.am: build the "idl" parser stuff as a convenience
2650 * glib/dbus-gparser.h: make description_load routines return
2651 NodeInfo* not Parser*
2653 * Makefile.am (SUBDIRS): build test dir after all library dirs
2655 * configure.in: add GTK+ detection
2657 2003-09-07 Havoc Pennington <hp@pobox.com>
2659 * Make Doxygen contented.
2661 2003-09-07 Havoc Pennington <hp@pobox.com>
2663 * doc/dbus-specification.sgml: more updates
2665 2003-09-06 Havoc Pennington <hp@pobox.com>
2667 * doc/dbus-specification.sgml: partial updates
2669 * bus/dbus-daemon-1.1.in: fix the config file docs for the
2670 zillionth time; hopefully I edited the right file this time.
2672 * bus/config-parser.c (append_rule_from_element): support
2673 send_type, send_path, receive_type, receive_path
2675 * bus/policy.c: add message type and path to the list of things
2676 that can be "firewalled"
2678 2003-09-06 Havoc Pennington <hp@pobox.com>
2680 * dbus/dbus-connection.c (dbus_connection_register_fallback): add this
2681 (dbus_connection_register_object_path): make this not handle
2682 messages to paths below the given path
2684 2003-09-03 Havoc Pennington <hp@pobox.com>
2686 * test/glib/Makefile.am: add this with random glib-linked test
2689 * glib/Makefile.am: remove the random test programs from here,
2690 leave only the unit tests
2692 * glib/dbus-gobject.c (_dbus_gobject_test): add test for
2693 uscore/javacaps conversion, and fix
2694 (get_object_property, set_object_property): change to .NET
2695 convention for mapping props to methods, set_FooBar/get_FooBar,
2696 since one language has such a convention we may as well copy it.
2697 Plus real methods in either getFooBar or get_foo_bar style won't
2698 collide with this convention.
2700 2003-09-01 Havoc Pennington <hp@pobox.com>
2702 * glib/dbus-gparser.c: implement
2704 * glib/dbus-gobject.c: start implementing skeletons support
2706 * configure.in: when disabling checks/assert, also define
2707 G_DISABLE_ASSERT and G_DISABLE_CHECKS
2709 2003-09-01 Havoc Pennington <hp@pobox.com>
2711 * glib/Makefile.am: rearrange a bunch of files and get "make
2712 check" framework set up
2714 2003-08-31 Havoc Pennington <hp@pobox.com>
2716 * fix build with --disable-tests
2718 2003-08-30 Havoc Pennington <hp@pobox.com>
2720 * dbus/dbus-connection.c: purge DBusMessageHandler
2722 * dbus/dbus-message-handler.c: remove DBusMessageHandler, just
2723 use callbacks everywhere
2725 2003-08-30 Havoc Pennington <hp@pobox.com>
2727 * test/data/valid-config-files/system.d/test.conf: change to
2728 root for the user so warnings don't get printed
2730 * dbus/dbus-message.c: add dbus_message_get_path,
2731 dbus_message_set_path
2733 * dbus/dbus-object-tree.c (do_test_dispatch): add test of
2734 dispatching to a path
2736 * dbus/dbus-string.c (_dbus_string_validate_path): add
2738 * dbus/dbus-marshal.c (_dbus_demarshal_object_path): implement
2739 (_dbus_marshal_object_path): implement
2741 * dbus/dbus-protocol.h (DBUS_HEADER_FIELD_PATH): new header field
2742 to contain the path to the target object
2743 (DBUS_HEADER_FIELD_SENDER_SERVICE): rename
2744 DBUS_HEADER_FIELD_SENDER to explicitly say it's the sender service
2746 2003-08-30 Havoc Pennington <hp@pobox.com>
2748 * dbus/dbus-object-tree.c: write tests and fix the discovered bugs
2750 2003-08-29 Havoc Pennington <hp@pobox.com>
2752 * dbus/dbus-object-tree.c: modify to allow overlapping paths to be
2754 (struct DBusObjectSubtree): shrink this
2755 a lot, since we may have a lot of them
2756 (_dbus_object_tree_free_all_unlocked): implement
2757 (_dbus_object_tree_dispatch_and_unlock): implement
2759 2003-08-29 Havoc Pennington <hp@pobox.com>
2761 * dbus/dbus-internals.h: fix _DBUS_N_GLOBAL_LOCKS
2763 2003-08-28 Havoc Pennington <hp@pobox.com>
2767 * dbus/dbus-connection.c: port to no ObjectID, create a
2768 DBusObjectTree, rename ObjectTree to ObjectPath in public API
2770 * dbus/dbus-connection.h (struct DBusObjectTreeVTable): delete
2771 everything except UnregisterFunction and MessageFunction
2773 * dbus/dbus-marshal.c: port away from DBusObjectID,
2774 add DBUS_TYPE_OBJECT_PATH
2776 * dbus/dbus-object-registry.[hc], dbus/dbus-object.[hc],
2777 dbus/dbus-objectid.[hc]: remove these, we are moving to
2778 path-based object IDs
2780 2003-08-25 Havoc Pennington <hp@pobox.com>
2782 Just noticed that dbus_message_test is hosed, I wonder when I
2783 broke that. I thought make check was passing earlier...
2785 * dbus/dbus-object-tree.c: add new "object tree" to match DCOP
2786 container tree, will replace most of dbus-object-registry
2788 * dbus/dbus-string.c (_dbus_string_append_printf_valist): fix C99
2791 2003-08-19 Havoc Pennington <hp@pobox.com>
2793 * dbus/dbus-message.c (decode_string_field): support FIELD_SENDER
2794 (dbus_message_is_error): fix this function
2796 * bus/dbus-daemon-1.1: clarify logic on when <deny>/<allow> rules
2799 * bus/policy.c (bus_client_policy_check_can_receive): fix code to
2800 reflect clarified man page
2801 (bus_client_policy_check_can_send): ditto
2803 * bus/session.conf.in: fixup
2805 * bus/system.conf.in: fixup
2807 2003-08-18 Havoc Pennington <hp@redhat.com>
2809 * dbus/dbus-hash.c (_dbus_hash_table_insert_two_strings): fix
2811 * dbus/dbus-message.c (_dbus_message_loader_queue_messages): fix
2812 dumb bug created earlier (wrong order of args to
2813 decode_header_data())
2815 * tools/dbus-send.c: port
2817 * tools/dbus-print-message.c (print_message): port
2819 * test/data/*messages: port all messages over
2821 * dbus/dbus-message-builder.c: support including
2824 * bus/driver.c: port over
2826 * bus/dispatch.c: port over to new stuff
2828 * dbus/dbus-connection.c (_dbus_connection_new_for_transport):
2829 rename disconnect signal to "Disconnected"
2831 2003-08-17 Havoc Pennington <hp@pobox.com>
2833 This doesn't compile yet, but syncing up so I can hack on it from
2834 work. What are branches for if not broken code? ;-)
2836 * dbus/dbus-protocol.h: remove DBUS_HEADER_FIELD_NAME, add
2837 DBUS_HEADER_FIELD_INTERFACE, DBUS_HEADER_FIELD_MEMBER,
2838 DBUS_HEADER_FIELD_ERROR_NAME
2840 * dbus/dbus-hash.c: Introduce DBUS_HASH_TWO_STRINGS as hack to use
2841 for the interface+member pairs
2842 (string_hash): change to use g_str_hash algorithm
2843 (find_direct_function, find_string_function): refactor these to
2846 * dbus/dbus-message.c: port all of this over to support
2847 interface/member fields instead of name field
2849 * dbus/dbus-object-registry.c: port over
2851 * dbus/dbus-string.c (_dbus_string_validate_interface): rename
2852 from _dbus_string_validate_name
2854 * bus/dbus-daemon-1.1: change file format for the
2855 <deny>/<allow> stuff to match new message naming scheme
2857 * bus/policy.c: port over
2859 * bus/config-parser.c: parse new format
2861 2003-08-16 Havoc Pennington <hp@pobox.com>
2863 * dbus/dbus-object-registry.c (add_and_remove_objects): remove
2866 * glib/dbus-gproxy.c: some hacking
2868 2003-08-15 Havoc Pennington <hp@redhat.com>
2870 * dbus/dbus-pending-call.c (dbus_pending_call_block): implement
2872 * dbus/dbus-connection.c
2873 (dbus_connection_send_with_reply_and_block): factor out internals;
2874 change to convert any error replies to DBusError instead of
2875 returning them as a message
2877 2003-08-15 Havoc Pennington <hp@pobox.com>
2879 * dbus/dbus-connection.c,
2880 dbus/dbus-pending-call.c: Finish the pending call stuff
2882 2003-08-14 Havoc Pennington <hp@redhat.com>
2884 * dbus/dbus-pending-call.c: start on new object that will replace
2885 DBusMessageHandler and ReplyHandlerData for tracking outstanding
2888 * dbus/dbus-gproxy.c: start on proxy object used to communicate
2889 with remote interfaces
2891 * dbus/dbus-gidl.c: do the boring boilerplate in here
2893 2003-08-12 Havoc Pennington <hp@pobox.com>
2895 * bus/dispatch.c (bus_dispatch): make this return proper
2896 DBusHandlerResult to avoid DBUS_ERROR_UNKNOWN_METHOD
2898 * dbus/dbus-errors.c (dbus_set_error): use
2899 _dbus_string_append_printf_valist
2901 * dbus/dbus-string.c (_dbus_string_append_printf_valist)
2902 (_dbus_string_append_printf): new
2904 * dbus/dbus-errors.h (DBUS_ERROR_UNKNOWN_MESSAGE): change to
2907 * dbus/dbus-connection.c (dbus_connection_dispatch): handle
2908 DBUS_HANDLER_RESULT_NEED_MEMORY; send default error reply if a
2909 message is unhandled.
2911 2003-08-11 Havoc Pennington <hp@pobox.com>
2913 * bus/test.c (client_disconnect_handler): change to return
2914 HANDLED (would have been REMOVE_MESSAGE)
2916 * dbus/dbus-object.h (enum DBusHandlerResult): rename to
2917 HANDLED/NOT_YET_HANDLED instead of
2918 REMOVE_MESSAGE/ALLOW_MORE_HANDLERS to make it clearer how it
2921 2003-08-10 Havoc Pennington <hp@pobox.com>
2923 * tools/dbus-send.c (main): add --type argument, for now
2924 supporting only method_call and signal types.
2926 * tools/dbus-print-message.c: print message type
2928 * dbus/dbus-connection.c (_dbus_connection_new_for_transport):
2929 init connection->objects
2931 * doc/dbus-specification.sgml: fix sgml
2933 * bus/*.c: port over to object-instance API changes
2935 * test/test-service.c: ditto
2937 * dbus/dbus-message.c (dbus_message_create_header): allow #NULL
2938 name, we will have to fix up the rest of the code to also handle
2940 (dbus_message_new): generic message-creation call
2941 (set_string_field): allow appending name field
2943 2003-08-06 Havoc Pennington <hp@pobox.com>
2945 * dbus/dbus-object-registry.c: implement signal connection
2948 * dbus/dbus-connection.c (_dbus_connection_unref_unlocked): new
2950 * dbus/dbus-internals.c (_dbus_memdup): new function
2952 2003-08-02 Havoc Pennington <hp@pobox.com>
2954 * dbus/dbus-message.c (dbus_message_get_no_reply)
2955 (dbus_message_set_no_reply): add these and remove
2956 set_is_error/get_is_error
2958 * dbus/dbus-protocol.h, doc/dbus-specification.sgml:
2959 remove the ERROR flag, since there's now an ERROR type
2961 2003-08-01 Havoc Pennington <hp@pobox.com>
2963 * dbus/dbus-object-registry.c (_dbus_object_registry_handle_and_unlock):
2966 * dbus/dbus-message.c (dbus_message_get_type): new function
2968 * doc/dbus-specification.sgml: add "type" byte to messages
2970 2003-08-01 Havoc Pennington <hp@pobox.com>
2972 * dbus/dbus-protocol.h (DBUS_MESSAGE_TYPE_*): introduce
2973 a message type enum to distinguish kinds of message
2974 (DBUS_HEADER_FLAG_NO_REPLY_EXPECTED): flag for a message
2975 that need not be replied to
2977 2003-08-01 Havoc Pennington <hp@pobox.com>
2979 * dbus/dbus-marshal.c: adapt to DBusObjectID changes
2980 (unpack_8_octets): fix no-64-bit-int bug
2982 * dbus/dbus-object-registry.c (validate_id): validate the
2983 connection ID bits, not just the instance ID.
2985 * dbus/dbus-connection.c (_dbus_connection_init_id): initialize
2986 the connection-global 33 bits of the object ID
2988 * dbus/dbus-object-registry.c (info_from_entry): fill in
2989 object ID in the new way
2991 * dbus/dbus-objectid.h: rather than high/low bits, specifically
2992 define server/client/instance bits.
2994 2003-07-30 Havoc Pennington <hp@pobox.com>
2996 * dbus/dbus-connection.c (dbus_connection_register_object): fix
2999 2003-07-13 Havoc Pennington <hp@pobox.com>
3001 * dbus/dbus-object.h (struct DBusObjectVTable): add padding
3002 fields to DBusObjectVTable and DBusObjectInfo
3004 2003-07-12 Havoc Pennington <hp@pobox.com>
3006 * dbus/dbus-object-registry.c: implement unit test,
3007 fix bugs discovered in process
3009 * dbus/dbus-connection.c: remove handler_table and
3010 register_handler(), add DBusObjectRegistry usage
3012 * dbus/dbus-objectid.c (dbus_object_id_is_null)
3013 (dbus_object_id_set_null): new functions
3015 2003-07-08 Havoc Pennington <hp@pobox.com>
3017 * dbus/dbus-object.c: implement some of this
3019 * dbus/dbus-object-registry.c
3020 (_dbus_object_registry_add_and_unlock): fill in the object_id out
3022 (_dbus_object_registry_new): handle OOM
3024 2003-07-08 Havoc Pennington <hp@pobox.com>
3026 * dbus/dbus-object.h: sketch out an API for registering objects
3027 with a connection, that allows us to use as little as 24 bytes
3028 per object and lets application code represent an object in
3029 any conceivable way.
3031 * dbus/dbus-object-registry.c: implement the hard bits of the
3032 DBusConnection aspect of object API. Not yet wired up.
3034 2003-07-06 Havoc Pennington <hp@pobox.com>
3036 * dbus/dbus-marshal.c (_dbus_marshal_set_object_id): new function
3037 (_dbus_marshal_object_id): new
3038 (_dbus_demarshal_object_id): new
3039 (_dbus_marshal_get_arg_end_pos): support object ID type, and
3040 consolidate identical switch cases. Don't conditionalize handling
3041 of DBUS_TYPE_UINT64, need to handle the type always.
3042 (_dbus_marshal_validate_arg): consolidate identical cases, and
3043 handle DBUS_TYPE_OBJECT_ID
3045 * dbus/dbus-objectid.c: new file with DBusObjectID data type.
3047 * dbus/dbus-protocol.h: add DBUS_TYPE_OBJECT_ID
3049 2003-09-28 Havoc Pennington <hp@pobox.com>
3053 2003-09-28 Havoc Pennington <hp@pobox.com>
3055 * doc/Makefile.am (dbus-specification.html): testing a funky hack
3056 to work with Debian db2html
3058 2003-09-28 Havoc Pennington <hp@pobox.com>
3060 * configure.in: 0.13
3062 * doc/Makefile.am (dbus-test-plan.html): accept nonexistence of
3063 stylesheet-images for benefit of Debian
3065 Change back to using filesystem-linked sockets for the system
3066 bus, so only root can create the default system bus address.
3068 * bus/system.conf.in: change to use
3069 DBUS_SYSTEM_BUS_DEFAULT_ADDRESS
3071 * dbus/Makefile.am (INCLUDES): remove DBUS_SYSTEM_BUS_PATH define
3074 * configure.in: define DBUS_SYSTEM_BUS_DEFAULT_ADDRESS
3075 here, and AC_DEFINE DBUS_SYSTEM_PATH
3077 2003-08-09 Anders Carlsson <andersca@codefactory.se>
3080 * doc/busconfig.dtd:
3083 2003-08-09 Anders Carlsson <andersca@codefactory.se>
3085 * doc/dbus-specification.sgml:
3086 Add activation reply values.
3088 2003-08-05 Havoc Pennington <hp@redhat.com>
3090 * configure.in: 0.12
3092 2003-08-05 Anders Carlsson <andersca@codefactory.se>
3094 * glib/dbus-gmain.c: (watch_fd_new), (watch_fd_ref),
3095 (watch_fd_unref), (dbus_gsource_check), (dbus_gsource_dispatch),
3096 (add_watch), (remove_watch), (create_source):
3097 Refcount fds, fixes some reentrancy issues.
3099 2003-07-30 Havoc Pennington <hp@redhat.com>
3101 * dbus/dbus-bus.c (init_connections_unlocked): fix default system
3102 bus address to be abstract if we have abstract sockets
3106 2003-07-28 Havoc Pennington <hp@redhat.com>
3108 * bus/messagebus.in: fix to avoid processname/servicename
3109 confusion, from Michael Kearey
3110 https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=100965
3112 2003-07-23 Havoc Pennington <hp@pobox.com>
3114 * dbus/dbus-message.c (dbus_message_iter_get_named):
3115 fix from Andy Hanton to remove broken "+1"
3117 2003-07-16 Havoc Pennington <hp@pobox.com>
3119 * tools/dbus-launch.c (babysit): close stdout/stderr in the
3120 babysitter process, as suggested by Thomas Leonard, so
3121 an "eval `dbus-launch --exit-with-session`" will actually
3124 2003-07-16 Havoc Pennington <hp@pobox.com>
3126 * configure.in: print out EXPANDED_* variables in the summary at
3127 the end; clean up the code that computes EXPANDED_ variables and
3128 get the ones using exec_prefix right. Should make things work
3129 when you build without --prefix
3131 2003-06-29 Havoc Pennington <hp@pobox.com>
3133 * mono/Test.cs (class Test): fire up a main loop and run it
3135 * mono/DBus.cs (DBus): don't g_thread_init since it can only be
3136 done once, the app has to do it
3138 2003-06-26 Havoc Pennington <hp@pobox.com>
3140 * mono/Connection.cs: set up connection with the glib main loop
3142 2003-07-01 Havoc Pennington <hp@redhat.com>
3144 * doc/dbus-specification.sgml: clarify the format of a type code,
3145 change suggested by Jim Blandy
3147 2003-06-29 Miloslav Trmac <mitr@volny.cz>
3150 * tools/Makefile.am: Don't assume srcdir == builddir.
3152 * dbus/dbus-memory.c (dbus_realloc): Don't check guards after shrinking
3153 the allocated block.
3154 (_dbus_memory_test): New function.
3155 * dbus/dbus-test.h: Add _dbus_memory_test ().
3156 * dbus/dbus-test.c (dbus_internal_do_not_use_run_tests): Call it.
3158 * dbus/dbus-message.c (decode_header_data): Use %.4s instead
3160 (dbus_message_new): Remove obsolete @todo.
3162 * dbus/dbus-marshal.c (_dbus_marshal_set_int64)
3163 (_dbus_marshal_set_uint64): Fix comment.
3165 * dbus/dbus-message.c (append_int_field, append_uint_field): Don't
3166 hardcode FIELD_REPLY_SERIAL.
3168 * dbus/dbus-mainloop.c (_dbus_loop_remove_watch)
3169 (_dbus_loop_remove_timeout): Cast function pointers to (void *) for %p
3171 * configure.in: Add -D_POSIX_C_SOURCE=199309L -DBSD_SOURCE to CFLAGS
3172 and disable DBUS_USE_ATOMIC_INT_486 when --enable-ansi is used
3174 2003-06-24 Havoc Pennington <hp@pobox.com>
3176 * mono/*.cs: Use IntPtr.Zero instead of ((IntPtr) 0)
3178 2003-06-23 Anders Carlsson <andersca@codefactory.se>
3184 * gcj/TestMessage.java: (TestMessage), (TestMessage.main):
3185 * gcj/org/.cvsignore:
3186 * gcj/org/Makefile.am:
3187 * gcj/org/freedesktop/.cvsignore:
3188 * gcj/org/freedesktop/Makefile.am:
3189 * gcj/org/freedesktop/dbus/.cvsignore:
3190 * gcj/org/freedesktop/dbus/Makefile.am:
3191 * gcj/org/freedesktop/dbus/Message.java: (Message),
3193 * gcj/org/freedesktop/dbus/natMessage.cc:
3194 Fix the build system.
3196 2003-06-22 Havoc Pennington <hp@pobox.com>
3198 * mono/Connection.cs: add more bindings
3200 * dbus/dbus-threads.c (dbus_threads_init): allow calling this
3203 2003-06-22 Havoc Pennington <hp@pobox.com>
3205 * mono/Connection.cs, mono/DBus.cs, mono/Error.cs:
3206 Start wrapping more stuff.
3208 2003-06-22 Havoc Pennington <hp@pobox.com>
3210 * mono/Message.cs: implement Message.Wrap() that ensures we only
3211 have a single C# wrapper per DBusMessage, assuming it works which
3212 it probably doesn't.
3214 * dbus/dbus-message.c (dbus_message_allocate_data_slot): new
3215 (dbus_message_free_data_slot): new
3216 (dbus_message_set_data): new
3217 (dbus_message_get_data): new
3219 2003-06-22 Havoc Pennington <hp@pobox.com>
3221 * dbus/dbus-dataslot.c (_dbus_data_slot_allocator_unref)
3222 (_dbus_data_slot_allocator_alloc): rework these to keep a
3223 reference count on each slot and automatically manage a global
3224 slot ID variable passed in by address
3226 * bus/bus.c: convert to new dataslot API
3228 * dbus/dbus-bus.c: convert to new dataslot API
3230 * dbus/dbus-connection.c: convert to new dataslot API
3232 * dbus/dbus-server.c: convert to new dataslot API
3234 * glib/dbus-gmain.c: ditto
3238 * bus/connection.c: ditto
3240 2003-06-22 Anders Carlsson <andersca@codefactory.se>
3242 * configure.in: Add AM_PROG_GCJ and move AM_PROG_LIBTOOL
3243 after the gcj checks so that the correct configuration tags
3244 will be added to libtool.
3246 * dbus-glib-1.pc.in: No need to specify any includes since
3247 dbus-1.pc.in has those.
3249 2003-06-22 Havoc Pennington <hp@pobox.com>
3251 * mono/*, gcj/*, configure.in, Makefile.am:
3252 Check in makefiles and subdirs for mono and gcj bindings.
3253 Neither binding actually exists, just trying to get through
3254 all the build and other boring bits.
3256 2003-06-21 Philip Blundell <philb@gnu.org>
3258 * tools/dbus-monitor.1: Updated.
3260 * tools/dbus-send.1: Likewise.
3262 2003-06-20 Anders Carlsson <andersca@codefactory.se>
3264 * dbus/dbus-transport-unix.c (unix_handle_watch): Check
3265 for hangup and error after checking read so we won't discard
3266 pending data if both hangup and read are set.
3268 2003-06-19 Philip Blundell <philb@gnu.org>
3270 * tools/dbus-print-message.c (print_message): Handle BOOLEAN.
3272 * tools/dbus-send.c: Accept both --system and --session.
3274 * tools/dbus-monitor.c: Same here.
3276 2003-06-19 Anders Carlsson <andersca@codefactory.se>
3278 * glib/dbus-glib.h: Fix so that dbus-glib.h can be used
3279 from C++ (Patch by Miloslav Trmac).
3281 2003-06-15 Joe Shaw <joe@assbarn.com>
3283 * configure.in: Check for socklen_t.
3285 * dbus/dbus-sysdeps.c: Define socklen_t if it's not defined.
3287 * test/test-segfault.c: Add #include <sys/time.h>
3289 * tools/Makefile.am: Add DBUS_X_CFLAGS to the INCLUDES since
3290 dbus-launch needs it.
3292 2003-06-09 Havoc Pennington <hp@redhat.com>
3294 * dbus/dbus-sysdeps.c (_dbus_listen_unix_socket): don't use
3295 SUN_LEN, it breaks abstract socket usage
3297 * dbus/dbus-internals.c (_dbus_verbose_real): only print PID at
3300 2003-06-04 Havoc Pennington <hp@pobox.com>
3302 * dbus/dbus-server.c (dbus_server_listen): allow abstract sockets
3303 using unix:abstract=/foo, and when listening in a tmpdir
3304 i.e. unix:tmpdir=/tmp, always use abstract sockets if we can.
3306 * dbus/dbus-transport.c (_dbus_transport_open): support
3309 * dbus/dbus-server-unix.c (_dbus_server_new_for_domain_socket):
3310 support abstract sockets
3312 * dbus/dbus-transport-unix.c
3313 (_dbus_transport_new_for_domain_socket): support abstract sockets
3315 * dbus/dbus-sysdeps.c (_dbus_connect_unix_socket): add "abstract"
3316 toggle as an argument, implement abstract namespace support
3317 (_dbus_listen_unix_socket): ditto
3319 * configure.in: add --enable-abstract-sockets and implement
3320 a configure check for autodetection of the right value.
3322 2003-06-01 Havoc Pennington <hp@pobox.com>
3324 * tools/dbus-cleanup-sockets.c: add utility to clean up sockets
3325 in /tmp (though on Linux this will end up being useless,
3326 when we add abstract namespace support)
3328 * configure.in: define DBUS_SESSION_SOCKET_DIR in addition to
3331 2003-05-28 Colin Walters <walters@verbum.org>
3333 * tools/dbus-monitor.c (main): Fix silly typo (s/--session/--system/).
3335 2003-05-18 Anders Carlsson <andersca@codefactory.se>
3337 * dbus/dbus-message.c (dbus_message_new): Remove @todo.
3339 2003-05-17 Colin Walters <walters@gnu.org>
3341 * tools/dbus-send.c: Don't exit with an error code if --help was
3342 passed. Default to using the session bus instead of the system
3345 * tools/dbus-launch.c: Ditto.
3347 * tools/dbus-monitor.c: Ditto.
3349 * tools/dbus-send.1: Update with new arguments.
3351 * tools/dbus-launch.c: Emit code to export variables. New
3352 arguments -s and -c to specify shell syntax, and a bit of code to
3353 autodetect syntax. Also, allow specifying a program to run.
3355 * tools/dbus-launch.1: Update with new arguments.
3357 * tools/dbus-send.1: Ditto.
3359 * tools/dbus-monitor.1: Ditto.
3361 2003-05-17 Havoc Pennington <hp@pobox.com>
3363 * bus/config-parser.c (merge_included): merge in policies from
3364 child configuration file.
3366 * bus/policy.c (bus_policy_merge): function to merge two policies
3369 2003-05-16 Havoc Pennington <hp@redhat.com>
3371 * dbus/dbus-connection.c: disable verbose lock spew
3373 * tools/dbus-send.c: add --print-reply command line option
3375 * tools/dbus-print-message.h (print_message): new util function
3376 shared by dbus-send and dbus-monitor
3378 * tools/dbus-monitor.c (handler_func): exit on disconnect
3380 * dbus/dbus-transport-unix.c (do_reading): if the transport is
3381 disconnected, don't try to use the read_watch
3383 * dbus/dbus-watch.c (dbus_watch_get_enabled): assert watch != NULL
3384 so we can find this bug more easily
3386 2003-05-16 Havoc Pennington <hp@redhat.com>
3388 * bus/policy.c (free_rule_list_func): avoid a crash when passed
3389 NULL as DBusHashTable is annoyingly likely to do.
3391 2003-05-16 Colin Walters <walters@verbum.org>
3393 * tools/dbus-monitor.c: Add --session argument and usage()
3396 * tools/dbus-monitor.1: Update with new --session arg.
3398 * bus/Makefile.am (install-data-hook): Create
3399 $(libdir)/dbus-1.0/services so that the session bus is happy.
3401 2003-05-15 Havoc Pennington <hp@redhat.com>
3403 * dbus/dbus-sysdeps.c (_dbus_atomic_dec, _dbus_atomic_inc): work
3404 on non-x86. ifdef's are evil.
3406 2003-05-15 Havoc Pennington <hp@redhat.com>
3408 * configure.in: 0.11
3412 * bus/Makefile.am (initddir): apparently we are supposed to put
3413 init scripts in /etc/rc.d/init.d not /etc/init.d
3415 * bus/Makefile.am: remove the "you must --enable-tests to make
3416 check" as it broke distcheck
3418 * bus/Makefile.am (install-data-hook): create /etc/dbus-1/system.d
3420 2003-05-13 James Willcox <jwillcox@gnome.org>
3423 * bus/activation.c: (bus_activation_service_created),
3424 (bus_activation_activate_service):
3425 * bus/driver.c: (bus_driver_send_service_deleted),
3426 (bus_driver_send_service_created), (bus_driver_send_service_lost),
3427 (bus_driver_send_service_acquired),
3428 (bus_driver_send_welcome_message),
3429 (bus_driver_handle_list_services):
3430 * bus/session.conf.in:
3431 * dbus/dbus-bus.c: (dbus_bus_acquire_service),
3432 (dbus_bus_service_exists), (dbus_bus_activate_service):
3435 Add some convenience API which lets you activate a service, and did a
3436 bunch of s/0/DBUS_TYPE_INVALID/ in calls to dbus_message_append_args()
3437 and dbus_message_get_args()
3439 2003-05-11 Havoc Pennington <hp@pobox.com>
3441 * dbus/dbus-marshal.c (_dbus_marshal_validate_arg): fix to avoid
3442 calling _dbus_marshal_validate_arg() for every byte in a byte
3445 * dbus/dbus-message-handler.c: use atomic reference counting to
3446 reduce number of locks slightly; the global lock in here sucks
3448 * dbus/dbus-connection.c
3449 (_dbus_connection_update_dispatch_status_and_unlock): variant of
3450 update_dispatch_status that can be called with lock held; then use
3451 in a couple places to reduce locking/unlocking
3452 (dbus_connection_send): hold the lock over the whole function
3453 instead of acquiring it twice.
3455 * dbus/dbus-timeout.c (_dbus_timeout_new): handle OOM
3457 * bus/connection.c (bus_connections_setup_connection): fix access
3458 to already-freed memory.
3460 * dbus/dbus-connection.c: keep a little cache of linked list
3461 nodes, to avoid using the global linked list alloc lock in the
3462 normal send-message case. Instead we just use the connection lock
3463 that we already have to take.
3465 * dbus/dbus-list.c (_dbus_list_find_last): new function
3467 * dbus/dbus-sysdeps.c (_dbus_atomic_inc, _dbus_atomic_dec):
3468 change to use a struct for the atomic type; fix docs,
3469 they return value before increment, not after increment.
3471 * dbus/dbus-string.c (_dbus_string_append_4_aligned)
3472 (_dbus_string_append_8_aligned): new functions to try to
3473 microoptimize this operation.
3474 (reallocate_for_length): break this out of set_length(), to
3475 improve profile info, and also so we can consider inlining the
3478 * dbus/dbus-message.c (dbus_message_new_empty_header): init data
3479 strings with some preallocation, cuts down on our calls to realloc
3480 a fair bit. Though if we can get the "move entire string to empty
3481 string" optimization below to kick in here, it would be better.
3483 * dbus/dbus-string.c (_dbus_string_move): just call
3484 _dbus_string_move_len
3485 (_dbus_string_move_len): add a special case for moving
3486 an entire string into an empty string; we can just
3487 swap the string data instead of doing any reallocs.
3488 (_dbus_string_init_preallocated): new function
3490 2003-05-11 Havoc Pennington <hp@pobox.com>
3492 Write a "test-profile" that does echo client-server with threads;
3493 profile reveals lock contention, memcpy/realloc of buffers, and
3494 UTF-8 validation as hot spots. 20% of lock contention eliminated
3495 with dbus_atomic_inc/dec implementation on x86. Much remaining
3496 contention is global mempool locks for GList and DBusList.
3498 * dbus/dbus-sysdeps.c (_dbus_atomic_inc, _dbus_atomic_dec): add
3501 * dbus/dbus-connection.c (struct DBusConnection): use
3502 dbus_atomic_t for the reference count
3504 * dbus/dbus-message.c (struct DBusMessage): declare
3505 dbus_atomic_t values as volatile
3507 * configure.in: code to detect ability to use atomic integer
3508 operations in assembly, from GLib patch
3510 * dbus/dbus-internals.c (_dbus_verbose_real): call getpid every
3511 time, tired of it being wrong in threads and forked processes
3513 * glib/test-profile.c: a little program to bounce messages back
3514 and forth between threads and eat CPU
3516 * dbus/dbus-connection.c: add debug spew macros for debugging
3517 thread locks; include config.h at top; fix deadlock in
3518 dbus_connection_flush()
3520 2003-05-08 Havoc Pennington <hp@pobox.com>
3522 * dbus/dbus-spawn.c: s/_exit/exit/ because it was keeping gcov
3523 data from getting written, and there wasn't a good reason to
3526 * test/decode-gcov.c (mark_inside_dbus_build_tests): don't count
3527 dbus_verbose lines in test coverage
3528 (main): add list of functions sorted by # of untested blocks
3529 to the coverage report
3531 * dbus/dbus-mempool.c: put some test-only code in DBUS_BUILD_TESTS
3533 * dbus/dbus-marshal.c (_dbus_marshal_test): extend test coverage
3535 * dbus/dbus-message-handler.c (_dbus_message_handler_test):
3536 extend test coverage
3538 * test/data/auth/cancel.auth-script: test canceling an
3541 * dbus/Makefile.am: remove dbus-server-debug.[hc] for now, as they
3542 aren't used. in CVS history if we end up needing them.
3544 2003-05-04 Havoc Pennington <hp@pobox.com>
3546 * dbus/dbus-message-handler.c (_dbus_message_handler_test): add
3549 * dbus/dbus-marshal.c (_dbus_demarshal_string_array): fix this
3550 function, which assumed length was in # of strings, not bytes
3552 * dbus/dbus-message.c (_dbus_message_test): add tests for some
3555 * dbus/dbus-connection.c
3556 (_dbus_connection_queue_received_message): disable function for
3557 now, we are only using it in test mode
3559 * dbus/dbus-message.c (_dbus_message_loader_queue_messages):
3560 remove a mistaken FIXME
3562 2003-05-04 Havoc Pennington <hp@pobox.com>
3564 * dbus/dbus-connection.c (dbus_connection_preallocate_send):
3565 unlock mutex on successful return, patch from Anders Gustafsson
3567 2003-05-04 Havoc Pennington <hp@pobox.com>
3569 * dbus-glib-1.pc.in (Requires): fix dependencies, from
3572 2003-05-04 Havoc Pennington <hp@pobox.com>
3574 * tools/dbus-launch.c: implement
3576 * bus/main.c (main), bus/bus.c (bus_context_new):
3577 implement --print-pid and --fork
3579 2003-05-03 Havoc Pennington <hp@redhat.com>
3581 * dbus/dbus-address.c (dbus_parse_address): fix bug when a key in
3582 the address had no value, and add to test suite. Fix and
3583 regression test from Miloslav Trmac
3585 2003-05-03 Havoc Pennington <hp@pobox.com>
3587 * dbus/dbus-watch.c (dbus_watch_handle): warn and return if a
3588 watch is invalid when handled
3590 * tools/Makefile.am, tools/dbus-launch.c, tools/dbus-launch.1: add
3591 dbus-launch utility to launch the bus from a shell script. Didn't
3592 actually implement dbus-launch yet, it's just a placeholder still.
3594 2003-05-03 Havoc Pennington <hp@pobox.com>
3596 * bus/Makefile.am, bus/dbus-daemon-1.1.in: man page for the
3597 daemon; also documents daemon config file, so replaces
3598 doc/config-file.txt. Corrected some stuff from config-file.txt in
3599 the process of moving it.
3601 2003-05-03 Havoc Pennington <hp@pobox.com>
3603 * tools/Makefile.am, tools/dbus-send.1, tools/dbus-monitor.1:
3606 2003-05-03 Colin Walters <walters@verbum.org>
3608 * dbus/dbus-sysdeps.c (fill_user_info): Test against
3609 DBUS_UID_UNSET to determine whether to do a uid lookup or not.
3611 * Makefile.am: Update to use new .pc versioning scheme.
3613 2003-05-02 Havoc Pennington <hp@redhat.com>
3615 * bus/system.conf.in: allow send/receive to/from message bus
3618 2003-04-30 Havoc Pennington <hp@redhat.com>
3620 * configure.in: print a note when building with unit tests and
3623 2003-04-30 Havoc Pennington <hp@redhat.com>
3625 * Makefile.am: add a check-local that complains if you didn't
3626 configure with --enable-tests
3628 2003-04-29 Havoc Pennington <hp@redhat.com>
3630 * glib/dbus-gmain.c: docs cleanups
3632 * dbus/dbus-types.h: add docs on int64 types
3634 * dbus/dbus-memory.c: fix docs to avoid putting private API in
3635 public API docs section
3637 2003-04-29 Havoc Pennington <hp@redhat.com>
3639 * dbus-1.pc.in, dbus-glib-1.pc.in: rename these from
3640 dbus-1.0.pc.in, dbus-glib-1.0.pc.in. As these change with the
3641 parallel install API version, not with the D-BUS package version.
3643 * HACKING: move some of README over here
3645 * README: updates, and document API/ABI policy
3647 * configure.in: reindentation
3649 2003-04-29 Havoc Pennington <hp@redhat.com>
3651 * dbus/dbus.h: add "you have to define DBUS_API_SUBJECT_TO_CHANGE
3652 to use this library" to be sure people have the right
3655 2003-04-28 Havoc Pennington <hp@redhat.com>
3657 * configure.in: add --enable-docs which by default is auto yes if
3658 doxygen and db2html found, no otherwise; but can be forced on/off
3660 * doc/Makefile.am: conditionalize whether to build docs on
3663 2003-04-28 Havoc Pennington <hp@redhat.com>
3665 * configure.in: 0.10
3669 * bus/system.conf.in: add <includedir>system.d</includedir>
3671 * dbus/dbus-userdb.c (_dbus_user_database_lookup): fix bug when
3672 username was provided but not uid
3674 * bus/config-parser.c (struct BusConfigParser): keep track of
3675 whether the parser is toplevel or was included; change some
3676 of the error handling if it's included.
3678 2003-04-27 Havoc Pennington <hp@pobox.com>
3682 * dbus/dbus-transport.c (_dbus_transport_get_dispatch_status):
3683 report correct status if we finish processing authentication
3684 inside this function.
3686 * bus/activation.c (try_send_activation_failure): use
3687 bus_transaction_send_error_reply
3689 * bus/connection.c (bus_connection_get_groups): return an error
3690 explaining the problem
3692 * bus/bus.c (bus_context_check_security_policy): implement
3693 restriction here that inactive connections can only send the
3694 hello message. Also, allow bus driver to send anything to
3697 * bus/connection.c (bus_connection_complete): create the
3698 BusClientPolicy here instead of on-demand.
3699 (bus_connection_get_policy): don't return an error
3701 * dbus/dbus-message.c (dbus_message_new_error_reply): allow NULL
3702 sender field in message being replied to
3704 * bus/bus.c (bus_context_check_security_policy): fix silly typo
3705 causing it to return FALSE always
3707 * bus/policy.c (bus_client_policy_check_can_send): fix bug where
3708 we checked sender rather than destination
3710 2003-04-25 Havoc Pennington <hp@redhat.com>
3712 test suite is slightly hosed at the moment, will fix soon
3714 * bus/connection.c (bus_connections_expire_incomplete): fix to
3715 properly disable the timeout when required
3716 (bus_connection_set_name): check whether we can remove incomplete
3717 connections timeout after we complete each connection.
3719 * dbus/dbus-mainloop.c (check_timeout): fix this up a bit,
3720 probably still broken.
3722 * bus/services.c (bus_registry_acquire_service): implement max
3723 number of services owned, and honor allow/deny rules on which
3724 services a connection can own.
3726 * bus/connection.c (bus_connection_get_policy): report errors here
3728 * bus/activation.c: implement limit on number of pending
3731 2003-04-25 Havoc Pennington <hp@redhat.com>
3733 * dbus/dbus-transport.c (_dbus_transport_get_unix_user): fix bug
3734 where we used >= 0 instead of != DBUS_UID_UNSET.
3736 2003-04-25 Havoc Pennington <hp@redhat.com>
3738 * glib/dbus-gmain.c (remove_watch): fix for a crash when watches
3739 were toggled without add/remove, fix from Anders Gustafsson
3741 2003-04-24 Havoc Pennington <hp@redhat.com>
3743 * test/data/valid-config-files/basic.conf: add <limit> tags to
3746 * bus/config-parser.h, bus/config-parser.c, bus/bus.c: Implement
3747 <limit> tag in configuration file.
3749 2003-04-24 Havoc Pennington <hp@redhat.com>
3751 * bus/dispatch.c: somehow missed some name_is
3753 * dbus/dbus-timeout.c (_dbus_timeout_set_enabled)
3754 (_dbus_timeout_set_interval): new
3756 * bus/connection.c (bus_connections_setup_connection): record time
3757 when each connection is first set up, and expire them after the
3758 auth timeout passes.
3760 2003-04-24 Havoc Pennington <hp@redhat.com>
3762 * dbus/dbus-message.c (dbus_message_name_is): rename
3763 (dbus_message_service_is): rename
3764 (dbus_message_sender_is): rename
3765 (dbus_message_get_service): rename
3767 2003-04-24 Havoc Pennington <hp@redhat.com>
3769 * configure.in: add --enable-checks
3771 * dbus/dbus-message.c (dbus_message_new): reverse name/service arguments
3773 * dbus/dbus-connection.c (dbus_connection_preallocate_send): fix
3774 to use thread locks.
3775 (_dbus_connection_handler_destroyed_locked): move some private
3776 functions into proper docs group
3778 * dbus/dbus-internals.h: add _dbus_return_if_fail,
3779 _dbus_return_val_if_fail
3781 Throughout: use dbus_return_if_fail
3783 2003-04-23 James Willcox <jwillcox@gnome.org>
3786 * glib/dbus-gmain.c: (add_timeout), (wakeup_main), (create_source),
3787 (dbus_connection_setup_with_g_main),
3788 (dbus_server_setup_with_g_main):
3789 * glib/test-dbus-glib.c: (main):
3790 * glib/test-thread-client.c: (main):
3791 * glib/test-thread-server.c: (new_connection_callback), (main):
3792 * tools/dbus-monitor.c: (main):
3794 Added a GMainContext argument to dbus_connection_setup_with_g_main()
3795 and dbus_server_setup_with_g_main().
3797 2003-04-20 Havoc Pennington <hp@pobox.com>
3799 * doc/dbus-specification.sgml: document the restrictions on
3800 message and service names
3802 2003-04-22 Havoc Pennington <hp@redhat.com>
3804 * dbus/dbus-message.c, dbus/dbus-marshal.c: add 64-bit integer
3805 support, and do some code cleanups to share more code and
3806 speed up array marshal/demarshal.
3808 * dbus-1.0.pc.in (Cflags): put libdir include file in cflags
3810 * configure.in: generate dbus-arch-deps.h
3812 * dbus/dbus-protocol.h (DBUS_TYPE_INT64, DBUS_TYPE_UINT64): add
3815 2003-04-22 Havoc Pennington <hp@redhat.com>
3817 * test/data/valid-messages/opposite-endian.message: fix test
3818 to use proper type for rply field
3820 * test/data/invalid-messages: add tests for below validation
3822 * dbus/dbus-message.c (decode_header_data): validate field types,
3823 and validate that named fields are valid names
3824 (decode_name_field): consider messages in the
3825 org.freedesktop.Local. namespace to be invalid.
3827 * dbus/dbus-string.c (_dbus_string_validate_name): new
3829 2003-04-19 Havoc Pennington <hp@pobox.com>
3831 * bus/driver.c (bus_driver_handle_hello): check limits and
3832 return an error if they are exceeded.
3834 * bus/connection.c: maintain separate lists of active and inactive
3835 connections, and a count of each. Maintain count of completed
3836 connections per user. Implement code to check connection limits.
3838 * dbus/dbus-list.c (_dbus_list_unlink): export
3840 * bus/bus.c (bus_context_check_security_policy): enforce a maximum
3841 number of bytes in the message queue for a connection
3843 2003-04-18 Havoc Pennington <hp@pobox.com>
3845 * dbus/dbus-auth.c (record_mechanisms): memleak fixes
3847 * dbus/dbus-sysdeps.c (_dbus_string_save_to_file): fix some
3850 * dbus/dbus-keyring.c (add_new_key): fix a memleak, and
3851 on realloc be sure to update the pointer in the keyring
3853 * dbus/dbus-string.c (_dbus_string_zero): compensate for align
3854 offset to avoid writing to unallocated memory
3856 * dbus/dbus-auth.c (process_rejected): return FALSE if we fail to
3857 try the next mechanism, so we properly handle OOM
3859 * dbus/dbus-keyring.c (_dbus_keyring_new_homedir): fix double-free
3861 (_dbus_keyring_new): fix OOM bug
3862 (_dbus_keyring_new_homedir): always set error; impose a maximum
3863 number of keys we'll load from the file, mostly to speed up the
3864 test suite and make its OOM checks more useful, but also for
3867 * dbus/dbus-auth.c (process_error_server): reject authentication
3868 if we get an error from the client
3869 (process_cancel): on cancel, send REJECTED, per the spec
3870 (process_error_client): send CANCEL if we get an error from the
3873 2003-04-18 Havoc Pennington <hp@pobox.com>
3875 * dbus/dbus-mainloop.c (_dbus_loop_iterate): fix UMR in verbose
3878 * dbus/dbus-auth.c (handle_client_data_cookie_sha1_mech): fix OOM
3881 * dbus/dbus-keyring.c (_dbus_keyring_new_homedir): only whine
3882 about DBUS_TEST_HOMEDIR once
3884 * bus/Makefile.am (TESTS_ENVIRONMENT): put DBUS_TEST_HOMEDIR in
3887 * bus/dispatch.c (bus_dispatch_sha1_test): actually load sha1
3888 config file so we test the right thing
3890 Throughout: assorted docs improvements
3892 2003-04-18 Havoc Pennington <hp@pobox.com>
3894 * glib/dbus-gmain.c: adapt to watch changes
3896 * bus/bus.c, bus/activation.c, etc.: adjust to watch changes
3898 * dbus/dbus-server.h: remove dbus_server_handle_watch
3900 * dbus/dbus-connection.h: remove dbus_connection_handle_watch
3902 * dbus/dbus-watch.c (dbus_watch_handle): change DBusWatch to work
3903 like DBusTimeout, so we don't need dbus_connection_handle_watch
3906 2003-04-17 Havoc Pennington <hp@redhat.com>
3908 * dbus/dbus-userdb.c, dbus/dbus-sysdeps.c: redo all the passwd
3909 database usage so it all goes via the DBusUserDatabase cache.
3911 2003-04-17 Havoc Pennington <hp@redhat.com>
3913 * dbus/dbus-mainloop.c (_dbus_loop_iterate): fix logic so that if
3914 there was an OOM watch we skipped, we always return TRUE so we
3915 iterate again to have a look at it again. Fixes test suite hang.
3916 Code rearrangement also lets us lose some memset and only iterate
3917 over callbacks once.
3919 * bus/driver.c (bus_driver_handle_message): sense of test for
3922 2003-04-16 Havoc Pennington <hp@pobox.com>
3924 * doc/dbus-specification.sgml: make spec say serials are unsigned
3926 * dbus/dbus-message.h: change message serials to unsigned
3928 * dbus/dbus-connection.c: adapt to message serials being unsigned
3930 2003-04-15 Havoc Pennington <hp@pobox.com>
3932 * bus/bus.c: create and keep around a shared DBusUserDatabase
3935 * bus/connection.c (bus_connection_get_groups): don't cache
3936 groups for user in the connection object, since user database
3937 object now does that.
3939 2003-04-16 Havoc Pennington <hp@redhat.com>
3941 * dbus/dbus-message.c (_dbus_message_add_size_counter): keep a
3942 list of size counters
3943 (_dbus_message_loader_putback_message_link): put back a popped link
3945 * dbus/dbus-connection.c
3946 (dbus_connection_set_max_live_messages_size): rename
3948 (dbus_connection_get_outgoing_size): get size of outgoing
3950 (_dbus_connection_set_connection_counter): remove this cruft
3952 2003-04-14 Havoc Pennington <hp@redhat.com>
3954 * dbus/dbus-userdb.c: user database abstraction, mostly to get
3955 caching, but at some point we might want to be able to use a
3958 * bus/dispatch.c (bus_dispatch_sha1_test): add a test that uses
3959 SHA1 conf file to test the sha1 auth mechanism, since the regular
3960 test always uses EXTERNAL when available.
3963 test/data/valid-config-files/debug-allow-all-sha1.conf.in:
3964 add conf file that requires use of sha1 auth
3966 2003-04-13 Havoc Pennington <hp@pobox.com>
3968 * tools/dbus-send.c, tools/dbus-monitor.c: two utility programs
3969 from Philip Blundell to send messages and monitor them.
3971 2003-04-13 Havoc Pennington <hp@pobox.com>
3973 * dbus/dbus-mainloop.c: fix some reentrancy issues by refcounting
3976 * test/data/valid-config-files/debug-allow-all.conf.in: allow all
3979 * dbus/dbus-transport.c (_dbus_transport_get_dispatch_status):
3980 fix to only recover unused bytes if we're already authenticated
3981 (_dbus_transport_get_is_authenticated): fix to still mark us
3982 authenticated if there are unused bytes.
3984 * bus/dispatch.c: implement security policy checking
3986 * bus/connection.c (bus_transaction_send_from_driver): new
3988 * bus/bus.c (bus_context_check_security_policy): new
3990 * bus/dispatch.c (send_service_nonexistent_error): delete this,
3991 now we just set the DBusError and it gets converted to an error
3994 * bus/connection.c (allow_user_function): enable code using actual
3995 data from the config file
3997 * bus/policy.c (list_allows_user): handle wildcard rules for
3998 user/group connection perms
4000 2003-04-13 Havoc Pennington <hp@pobox.com>
4002 * bus/config-parser.c: Load up the BusPolicy and BusPolicyRules
4004 * dbus/dbus-sysdeps.c (_dbus_get_user_id): new function
4006 * bus/policy.c (bus_policy_append_mandatory_rule)
4007 (bus_policy_append_default_rule, bus_policy_append_user_rule)
4008 (bus_policy_append_group_rule): new functions
4010 2003-04-12 Havoc Pennington <hp@pobox.com>
4012 * bus/config-parser.c (bus_config_parser_new): fix a memleak
4014 * dbus/dbus-sysdeps.c: change DBusCredentials to use longs for
4015 the pid/gid/uid, just for paranoia.
4017 * test/break-loader.c (randomly_do_n_things): find a byte
4018 containing a type code, and randomly change it to a different
4021 2003-04-12 Havoc Pennington <hp@pobox.com>
4023 * bus/policy.h: change BusPolicy to be the thing from the config
4024 file, and rename old BusPolicy to BusClientPolicy
4026 * bus/bus.c, bus/connection.c, bus/config-parser.c: change to
4027 match change in how policy works
4029 * dbus/dbus-internals.h: mark assert_not_reached as
4030 __attribute((noreturn))__
4032 2003-04-11 Havoc Pennington <hp@redhat.com>
4034 * doc/dbus-specification.sgml: fix a spot with the wrong name for
4035 the broadcast service. Use boolean return for ServiceExists.
4037 2003-04-11 Havoc Pennington <hp@redhat.com>
4039 * configure.in: add another directory to look for qt in.
4041 2003-04-11 Havoc Pennington <hp@redhat.com>
4043 * AUTHORS: add Colin Walters
4045 2003-04-11 Havoc Pennington <hp@redhat.com>
4051 2003-04-11 Havoc Pennington <hp@redhat.com>
4053 * bus/messagebus.in: remove pid file when stopping the
4054 message bus, since the bus won't have privileges to remove it
4057 2003-04-11 Havoc Pennington <hp@redhat.com>
4059 * bus/bus.c (bus_context_new): move credentials change after
4062 2003-04-11 Havoc Pennington <hp@pobox.com>
4064 * test/decode-gcov.c: add "below average functions" to the
4065 coverage report, and change how some of the code works.
4067 * bus/test-main.c: bracket some stuff in DBUS_BUILD_TESTS so it's
4068 not in the coverage stats.
4070 * test/test-service.c (main): use _dbus_verbose not fprintf in a
4071 couple places so running the test suite doesn't result in megaspam.
4073 2003-04-11 Havoc Pennington <hp@pobox.com>
4075 * bus/dispatch.c (check_existent_service_activation): accept a no
4076 memory error in a place we didn't before
4078 * bus/test.c (bus_test_run_everything): remove hacky "do it twice
4079 in case the first one failed," since the test suite is less
4082 2003-04-10 Havoc Pennington <hp@pobox.com>
4084 * bus/dispatch.c (check_segfault_service_activation): add test
4085 for launching an executable that just crashes.
4087 * test/test-segfault.c (main): try setting coredumpsize to 0 so we
4088 don't leave a million cores. We'll see how portable this is.
4090 2003-04-10 Havoc Pennington <hp@pobox.com>
4092 * dbus/dbus-spawn.c (_dbus_spawn_async_with_babysitter): move all
4093 the possible parent failures before we fork, so that we don't
4094 fail to create a babysitter after creating the child.
4096 * bus/activation.c (bus_activation_activate_service): kill child
4097 if we don't successfully complete the activation.
4099 2003-04-10 Havoc Pennington <hp@redhat.com>
4101 * dbus/dbus-connection.c (dbus_connection_flush): don't spin on
4102 the connection if it's disconnected
4104 * bus/activation.c (bus_activation_service_created): use new
4105 transaction features to roll back removal of pending activation if
4106 we don't successfully create the service after all. Don't remove
4107 pending activation if the function fails.
4109 * dbus/dbus-list.c (_dbus_list_insert_before_link)
4110 (_dbus_list_insert_after_link): new code to facilitate
4113 * dbus/dbus-hash.c (_dbus_hash_table_insert_string_preallocated):
4114 new functionality, so we can preallocate the ability to insert
4117 * bus/connection.c (bus_transaction_add_cancel_hook): new function
4118 allowing us to put custom hooks in a transaction to be used for
4119 cancelling said transaction
4121 * doc/dbus-specification.sgml: add some discussion of secondary
4122 service owners, and disallow zero-length service names
4124 * bus/services.c (bus_registry_acquire_service): new function,
4125 splits out part of bus_driver_handle_acquire_service() and fixes
4126 a bug where we didn't remove the service doing the acquiring
4127 from the secondary queue if we failed to remove the current owner
4128 from the front of the queue.
4130 2003-04-10 Alexander Larsson <alexl@redhat.com>
4132 * doc/dbus-specification.sgml:
4133 s/org.freedesktop.Broadcast/org.freedesktop.DBus.Broadcast/
4135 2003-04-10 Alexander Larsson <alexl@redhat.com>
4140 Added files to cvsignore
4142 * dbus/dbus-message.h:
4143 * dbus/dbus-message.c: (dbus_message_iter_get_named):
4144 Make get_named() take two out argument and return a boolean.
4145 (dbus_message_iter_get_args_valist):
4146 Update usage of get_named().
4147 (dbus_message_iter_append_byte):
4149 (dbus_message_iter_append_named)
4151 (message_iter_test), (check_message_handling_type), (_dbus_message_test):
4154 2003-04-10 Alexander Larsson <alexl@redhat.com>
4156 * dbus/dbus-marshal.[ch]:
4157 Add array_type_pos argument to _dbus_marshal_validate_arg.
4158 Let you pass a NULL end_pos to _dbus_marshal_validate_type.
4160 * dbus/dbus-message.[ch]:
4161 Multi-dimensional arrays have full type specification in the
4162 outermost array. Iter code re-arranged to handle this.
4163 Added some more iter tests.
4165 * doc/dbus-specification.sgml:
4168 Update new array encoding description.
4169 Correct DBUS_SERVICE_FLAGS_REPLACE_EXISTING description.
4171 * test/data/invalid-messages/array-with-mixed-types.message:
4172 * test/data/valid-messages/array-of-array-of-uint32.message:
4173 Change to the new array format.
4175 * test/data/invalid-messages/too-short-dict.message:
4178 * test/data/valid-messages/recursive-types.message:
4179 Fix up and extend test.
4181 2003-04-10 Havoc Pennington <hp@pobox.com>
4183 * bus/dispatch.c: lots of fixes
4185 * dbus/dbus-mainloop.c (_dbus_loop_dispatch): export
4186 (_dbus_loop_iterate): remove old "quit if no callbacks" code,
4187 that was crack, broke the test service.
4189 * dbus/dbus-transport.c (_dbus_transport_open): fix error
4190 handling to avoid piling up errors if we get a failure on the
4193 * dbus/dbus-internals.c (_dbus_real_assert_not_reached): include
4194 pid in assertion failures.
4196 * dbus/dbus-mainloop.c (_dbus_loop_iterate): use static arrays up
4197 to some fixed size of file descriptor array. Don't return TRUE
4198 anytime a timeout exists, that led to lots of busy loop silliness
4201 2003-04-09 Havoc Pennington <hp@redhat.com>
4203 * dbus/dbus-mainloop.c (check_timeout): fix timeouts, I thought
4204 I'd checked this in earlier but hadn't.
4206 2003-04-09 Havoc Pennington <hp@redhat.com>
4208 * bus/dispatch.c (bus_dispatch_test): get a bit further through
4209 the activation test (man this is getting old!)
4211 2003-04-09 Havoc Pennington <hp@redhat.com>
4213 * test/test-utils.c: use dispatch status function to fix this up
4215 * bus/connection.c (connection_watch_callback): don't dispatch
4217 (connection_timeout_callback): don't dispatch from here
4218 (bus_connections_setup_connection): set the dispatch status function
4219 (bus_connection_disconnected): unset it
4221 * dbus/dbus-mainloop.c (_dbus_loop_queue_dispatch): new function
4222 used to add a connection to be dispatched
4223 (_dbus_loop_iterate): do the dispatching at the end of each
4226 * dbus/dbus-connection.c
4227 (dbus_connection_set_dispatch_status_function): new function
4228 allowing us to fix up main loop usage
4229 (_dbus_connection_last_unref): free all the various function
4231 (dbus_connection_dispatch): call the DispatchStatusFunction
4232 whenever this function returns
4233 (dbus_connection_handle_watch): call DispatchStatusFunction
4234 (dbus_connection_send_with_reply_and_block): call DispatchStatusFunction
4235 (reply_handler_timeout): call DispatchStatusFunction
4236 (dbus_connection_flush): call DispatchStatusFunction
4238 2003-04-09 Havoc Pennington <hp@redhat.com>
4240 * dbus/dbus-bus.c (dbus_bus_register): fix up error handling and
4243 * bus/dispatch.c (check_service_activated): fix bug in test
4245 * dbus/dbus-mainloop.c (check_timeout): fix this up
4247 * dbus/dbus-internals.c (_dbus_verbose_real): include PID in
4248 verbose output so we can sort out output from different processes,
4249 e.g. in the activation case.
4251 2003-04-08 Colin Walters <walters@gnu.org>
4253 * bus/bus.c (struct BusContext) [pidfile]: New member, to store
4255 (bus_context_new): Set it.
4256 (bus_context_unref): Use it to delete the pid file.
4258 2003-04-08 Havoc Pennington <hp@redhat.com>
4260 * test/data/invalid-messages/array-with-mixed-types.message:
4261 regression test that fails for the moment
4263 * dbus/dbus-test.c (dbus_internal_do_not_use_run_tests): reorder
4264 tests for convenience
4266 * dbus/dbus-marshal.c (_dbus_marshal_validate_arg): don't allow
4267 array of nil, it broke things.
4269 * test/data/invalid-messages/array-of-nil.message: regression test
4271 * test/data/valid-messages/array-of-array-of-uint32.message:
4272 happened to write this so added it to suite
4274 2003-04-08 Havoc Pennington <hp@redhat.com>
4276 * bus/driver.c (bus_driver_handle_acquire_service): init
4277 retval/reply before checking name
4279 * dbus/dbus-marshal.c (_dbus_marshal_validate_arg): add a
4280 recursion depth argument
4282 * dbus/dbus-message.h (struct DBusMessageIter): put some padding
4283 in the public struct for future extension
4285 * dbus/dbus-message-builder.c (_dbus_message_data_load): fix
4288 * dbus/dbus-marshal.c (_dbus_marshal_validate_arg): fix a verbose
4291 * doc/dbus-specification.sgml: fix typo
4293 2003-04-08 Alexander Larsson <alexl@redhat.com>
4295 Implemented recursive types, named types and new-style iters
4298 * glib/test-thread-client.c: (thread_func):
4299 * glib/test-thread-server.c: (handle_test_message):
4300 * test/test-service.c: (handle_echo):
4309 * dbus/dbus-internals.c: (_dbus_type_to_string):
4310 Update for new types.
4312 * dbus/dbus-marshal.[ch]:
4313 Implement recursive types and the new marshalling format.
4314 Remove hardcoded dict marshalling.
4315 Marshal named types.
4317 * dbus/dbus-message-builder.c:
4319 Remove references to old types
4321 * dbus/dbus-message.[ch]:
4322 New non-refcounted iter API that supports recursive iters.
4323 Use iters for appending, including support for recursive
4325 Add byte and named type support.
4326 Update everything to new marshalling formats.
4327 Add tests for new API.
4329 * dbus/dbus-protocol.h:
4330 Remove old array types.
4331 Add types: BYTE, ARRAY, DICT, NAMED
4333 * dbus/dbus-string.c:
4334 * dbus/dbus-sysdeps.c:
4335 Make parse_double locale safe.
4337 * dbus/dbus-test-main.c:
4343 * doc/dbus-specification.sgml:
4346 * test/data/incomplete-messages/missing-body.message:
4347 * test/data/invalid-messages/bad-boolean.message:
4348 * test/data/invalid-messages/bad-boolean-array.message:
4349 * test/data/invalid-messages/boolean-array-length-too-long.message-raw:
4350 * test/data/invalid-messages/boolean-has-no-value.message-raw:
4351 * test/data/invalid-messages/too-short-dict.message:
4352 * test/data/valid-messages/dict-simple.message:
4353 * test/data/valid-messages/dict.message:
4354 * test/data/valid-messages/emptiness.message:
4355 * test/data/valid-messages/lots-of-arguments.message:
4356 * test/data/valid-messages/no-padding.message:
4357 * test/data/valid-messages/recursive-types.message:
4358 Add missing NAME fields
4359 Fix up dicts & arrays
4361 * test/data/invalid-messages/dict-with-nil-value.message:
4362 Removed, this is not invalid anymore.
4364 * test/data/valid-messages/recursive-types.message:
4365 Add new test for deeply recursive types.
4367 2003-04-07 Havoc Pennington <hp@pobox.com>
4369 * bus/driver.c (bus_driver_handle_acquire_service): return an
4370 error if you try to acquire a service that starts with ':'
4372 2003-04-07 Havoc Pennington <hp@redhat.com>
4374 * doc/dbus-specification.sgml: require that base service names
4375 start with ':' and that the base service is created/deleted
4376 as first and last things a connection does on the bus
4378 * bus/dispatch.c (check_existent_service_activation): lots more
4379 work on the activation test; it doesn't fully pass yet...
4381 * test/test-service.c (main): fix so we don't memleak the
4382 connection to the message bus
4383 (filter_func): accept a message asking us to exit
4385 2003-04-06 Havoc Pennington <hp@pobox.com>
4387 * qt/Makefile.am (dbusinclude_HEADERS): install dbus-qt.h,
4390 * configure.in: fixes to Qt detection from Colin Walters
4392 * doc/Makefile.am: Only remove generated docbook dirs if they
4393 exist, from Colin Walters
4395 * dbus/dbus-bus.c: change how we set well-known connections to
4396 NULL, so that it works if a single connection is stored in
4397 two well-known array slots.
4399 * test/Makefile.am: remove a lot of stuff that isn't immediately
4400 useful, it's in CVS history if we want it.
4402 * test/test-service.c: use dbus-mainloop instead of that
4405 2003-04-06 Havoc Pennington <hp@pobox.com>
4407 * dbus/Makefile.am: split lists of sources into stuff that goes in
4408 the library, util functions that go in the lib and are also used
4409 elsewhere, and util functions that are used in tests/daemon but
4410 don't go in the lib.
4412 * dbus/dbus-mainloop.h, dbus/dbus-mainloop.c: move bus/loop.[hc]
4413 here so it can be used in test binaries also
4415 2003-04-06 Havoc Pennington <hp@pobox.com>
4417 * dbus/dbus-sysdeps.c (_dbus_become_daemon): write the pidfile
4418 here in the parent process, so we can return an error if it
4419 fails. Also, move some of the code into the child so the parent
4420 is less hosed if we fail midway through.
4422 * bus/bus.c (bus_context_new): move pidfile detection further up
4423 in the function, before we start overwriting sockets and such.
4425 * bus/messagebus.in: adjust this a bit, not sure if it will work.
4427 * configure.in: add --with-system-pid-file and --with-system-socket
4429 2003-04-06 Colin Walters <walters@verbum.org>
4431 * configure.in (DBUS_SYSTEM_PID_FILE): New variable.
4433 * bus/system.conf.in: Declare a pidfile.
4435 * bus/bus.c (bus_context_new): Test for an existing pid file, and
4436 create one (if appropriate).
4438 * bus/config-parser.c (enum ElementType) [ELEMENT_PIDFILE]: New.
4439 (struct BusConfigParser) [pidfile]: New.
4440 (element_type_to_name, merge_included, start_busconfig_child)
4441 (bus_config_parser_end_element, bus_config_parser_content): Handle it.
4442 (bus_config_parser_unref): Free it.
4443 (bus_config_parser_get_pidfile): New function.
4445 * bus/config-parser.h (_dbus_write_pid_file): Prototype.
4447 * dbus/dbus-errors.h (DBUS_ERROR_PIDFILE_EXISTS): New error.
4449 * dbus/dbus-sysdeps.c (_dbus_write_pid_file): New function.
4451 * dbus/dbus-sysdeps.h: Prototype it.
4453 2003-04-06 Havoc Pennington <hp@pobox.com>
4455 * bus/bus.c (bus_context_new): print the address in here, rather
4456 than in main(), because we need to do it before forking the daemon
4458 * bus/dispatch.c (send_service_nonexistent_error): set the sender
4459 on the service nonexistent error
4461 * bus/driver.c (bus_driver_handle_acquire_service): set the
4462 sender on the AcquireService reply
4464 * test/data/valid-config-files/debug-allow-all.conf.in: Make test
4465 server also listen on a UNIX socket so services can connect to it.
4467 2003-04-06 Havoc Pennington <hp@pobox.com>
4469 * dbus/dbus-threads.c: Redo how the fake debug mutexes are done
4470 so it detects deadlocks and also we actually init threads when
4473 2003-04-06 Havoc Pennington <hp@pobox.com>
4475 * dbus/dbus-server-unix.c (_dbus_server_new_for_domain_socket):
4476 save the domain socket name, and unlink it when we disconnect the
4477 server. Means that at least when we exit normally, we won't leave
4478 a bunch of junk in /tmp
4480 * dbus/dbus-transport-unix.c
4481 (_dbus_transport_new_for_domain_socket): code cleanup (nicer
4482 memory management). (I was making a real change here but then
4485 2003-04-06 Havoc Pennington <hp@pobox.com>
4487 * bus/bus.c (bus_context_new): fix wrong handling of
4488 server_data_slot_unref() in the error case.
4490 * dbus/dbus-internals.h (_dbus_assert): change so it passes
4491 "(condition) != 0" to _dbus_real_assert so that
4492 "_dbus_assert (pointer)" doesn't cause a warning
4494 * bus/main.c (main): accept --print-address option to print out
4495 the message bus address
4497 * dbus/dbus-sysdeps.c (_dbus_generate_random_ascii): export this
4499 * dbus/dbus-transport.c (_dbus_transport_open): special error for
4500 "tmpdir" option to unix: address on client side
4502 * dbus/dbus-server.c (dbus_server_listen): handle "tmpdir" option
4505 * configure.in (TEST_SOCKET_DIR): locate a temporary directory
4506 we can use to create sockets in the test suite.
4508 * bus/main.c (signal_handler): on SIGTERM, exit the daemon
4509 cleanly. To be used for testing.
4511 * dbus/dbus-spawn.c (babysit): use _dbus_set_signal_handler()
4513 * dbus/dbus-sysdeps.c (_dbus_set_signal_handler): new
4515 * dbus/dbus-server-debug-pipe.c (_dbus_transport_debug_pipe_new):
4516 handle trying to call this when there's no servers active
4518 2003-04-05 Havoc Pennington <hp@pobox.com>
4524 2003-04-05 Havoc Pennington <hp@pobox.com>
4526 * bus/bus.c (setup_server): fix this so dbus-daemon-1 doesn't
4527 crash on startup. Need to get "try starting the daemon"
4528 in the test suite I guess. ;-)
4530 * dbus/dbus-server.h, dbus/dbus-server.c: remove the stuff that
4531 tracked the number of open connections; it's better done in
4532 application-specific code as you want it to span all servers etc.
4534 2003-04-05 Havoc Pennington <hp@pobox.com>
4536 * bus/Makefile.am (install-data-hook): add missing DESTDIR,
4537 patch from Colin Walters
4539 2003-04-05 Havoc Pennington <hp@pobox.com>
4541 * doc/config-file.txt (Elements): fix docs of <auth> to reflect
4542 reality; in fact multiple mechanisms are allowed.
4544 * dbus/dbus-internals.c (_dbus_real_assert)
4545 (_dbus_real_assert_not_reached): move guts of _dbus_assert() and
4546 _dbus_assert_not_reached() into functions, so that they don't show
4547 up in basic block counts for test coverage, and don't use up as
4548 much disk space. Does mean slower execution speed though, so
4549 assumes --disable-asserts is the normal production case.
4551 2003-04-05 Havoc Pennington <hp@pobox.com>
4553 * test/Makefile.am (dist-hook): also dist *.in files
4559 2003-04-05 Havoc Pennington <hp@pobox.com>
4561 * dbus/dbus-string.c: docs warning
4563 * dbus/dbus-spawn.c: missing docs
4565 * dbus/dbus-memory.c (struct ShutdownClosure): missing docs
4567 2003-04-05 Havoc Pennington <hp@pobox.com>
4569 * bus/loop.c (bus_loop_iterate): fix the timeout code, using
4572 * dbus/dbus-spawn.c (_dbus_babysitter_unref): set sitter_pid
4573 to -1 once we've reaped the babysitter
4574 (_dbus_babysitter_handle_watch): do as much work as we can, not
4577 * bus/activation.c: add code using DBusBabysitter so that we
4578 handle it when a service fails to start up properly.
4579 (bus_activation_service_created): don't remove the activation
4580 entries as we go, just let them get removed when we free the pending
4581 activation. Unref reply messages after sending them.
4583 2003-04-05 Havoc Pennington <hp@pobox.com>
4585 * test/decode-gcov.c (main): print per-directory stats in the report
4587 * Makefile.am (coverage-report.txt): don't include test/* in gcov stats
4589 2003-04-05 Havoc Pennington <hp@pobox.com>
4591 * Makefile.am (coverage-report.txt): add target "coverage-report.txt"
4593 * test/decode-gcov.c: hack up a little program to suck data
4594 out of gcov files. Yes this is sort of silly.
4596 * configure.in: define something in config.h and do an
4597 AM_CONDITIONAL when gcov is enabled
4599 2003-04-04 Havoc Pennington <hp@redhat.com>
4601 * dbus/dbus-spawn.c, dbus/dbus-spawn.h: Change dbus_spawn to
4602 return a "babysitter" object that is used to monitor the status of
4603 the spawned process and reap it when required.
4605 * test/test-segfault.c, test/test-exit.c,
4606 test/test-sleep-forever.c: binaries that do various lame things,
4607 used in the test suite.
4609 * dbus/dbus-sysdeps.c: kill _dbus_errno_to_string()
4611 2003-04-03 Havoc Pennington <hp@pobox.com>
4613 * dbus/dbus-spawn.c: Move dbus-spawn into a separate file
4614 in preparation for modifying it, dbus-sysdeps is getting
4617 2003-04-03 Havoc Pennington <hp@redhat.com>
4619 * bus/loop.h, bus/loop.c: make the mainloop an object so we can
4622 * bus/*.[hc]: adapt to mainloop change
4624 2003-04-03 Havoc Pennington <hp@redhat.com>
4626 * bus/activation.c (load_directory): fix up memleaks
4627 (bus_activation_entry_free): free the entry
4629 * dbus/dbus-bus.c (dbus_bus_acquire_service): return an error if
4630 we get one from the message bus; fix memleaks.
4632 * dbus/dbus-message.c (dbus_set_error_from_message): new function
4634 2003-04-03 Havoc Pennington <hp@pobox.com>
4636 * bus/config-parser.c (bus_config_parser_unref): free
4637 list of mechanisms, bug discovered by test suite enhancements
4638 (putting system.conf and session.conf into suite)
4640 * test/Makefile.am, test/test-service.c: add placeholder for a
4641 test service that we'll activate as part of test suite. Doesn't
4644 * dbus/dbus-sysdeps.c (_dbus_setenv): support unsetenv by
4645 setting NULL value, and use system malloc not dbus_malloc()
4646 when we have unavoidable memleakage.
4648 * dbus/dbus-bus.c (dbus_bus_get): fix bug where bus type of 0
4649 didn't work, and support DBUS_BUS_ACTIVATION.
4651 * bus/activation.c (child_setup): pass our well-known bus type to
4654 * bus/config-parser.c: support <type> to specify well-known type
4656 * doc/dbus-specification.sgml: document the env variables to
4657 locate well-known buses and find service activator
4659 2003-04-02 Havoc Pennington <hp@redhat.com>
4661 * test/Makefile.am (all-local): add a rule to copy tests to
4662 builddir, so we can have generated tests. Use this to remove the
4663 silly hack for testing system.conf and session.conf. Will use this
4664 shortly to generate .service files pointing to test binaries.
4666 2003-04-02 Havoc Pennington <hp@redhat.com>
4668 * dbus/dbus-string.c (set_length): fix a bug - we allocated max of
4669 current alloc and needed new length, not max of the doubled
4670 allocation and needed new length. Also, when building tests,
4671 don't do the double-allocation stuff, just realloc every time.
4673 2003-04-02 Havoc Pennington <hp@redhat.com>
4675 * dbus/dbus-sysdeps.c (_dbus_file_get_contents): include filenames
4677 (_dbus_string_get_dirname): new
4678 (_dbus_sysdeps_test): new
4679 (_dbus_directory_open): include dirnames in error messages
4681 * bus/config-parser.c: interpret <include> and <includedir> and
4682 <servicedir> relative to config file location if the given
4683 filename is not absolute.
4685 * dbus/dbus-string.c (_dbus_string_find_byte_backward): new
4687 2003-04-02 Havoc Pennington <hp@redhat.com>
4689 * bus/connection.c (bus_transaction_send_error_reply): set sender
4690 service for the error, and unref the reply on success
4692 * bus/activation.c: convert to use BusTransaction so OOM can be
4694 (bus_activation_service_created): set sender of the message
4696 2003-04-01 Havoc Pennington <hp@redhat.com>
4698 * bus/config-parser.c, bus/bus.c: implement <servicedir> and
4699 <includedir> (at least mostly)
4701 * dbus/dbus-sysdeps.c (_dbus_change_identity): set the group ID
4702 first, then the user ID
4704 2003-04-01 Havoc Pennington <hp@pobox.com>
4706 * dbus/dbus-server.c (dbus_server_set_auth_mechanisms): new
4709 * dbus/dbus-auth.c (_dbus_auth_set_mechanisms): new
4711 * dbus/dbus-internals.c (_dbus_dup_string_array): new function
4713 * dbus/dbus-sysdeps.c (_dbus_listen_unix_socket): chmod the
4714 socket 0777, and unlink any existing socket.
4716 * bus/bus.c (bus_context_new): change our UID/GID and fork if
4717 the configuration file so specifies; set up auth mechanism
4720 * bus/config-parser.c (bus_config_parser_content): add support
4721 for <fork> option and fill in code for <auth>
4723 * bus/system.conf.in: add <fork/> to default configuration,
4724 and limit auth mechanisms to EXTERNAL
4726 * doc/config-file.txt (Elements): add <fork>
4728 * dbus/dbus-sysdeps.c (_dbus_become_daemon): new function
4729 (_dbus_change_identity): new function
4731 2003-03-31 Havoc Pennington <hp@redhat.com>
4733 * dbus/dbus-sysdeps.c (_dbus_connect_unix_socket)
4734 (_dbus_listen_unix_socket): fix off-by-one error in null
4735 termination spotted by Nalin
4737 2003-03-31 Havoc Pennington <hp@redhat.com>
4739 * dbus/dbus-keyring.c (_dbus_keyring_new_homedir): allow setting
4740 DBUS_TEST_HOMEDIR when tests are enabled, so we can test without
4741 having a real home directory available.
4743 2003-03-31 Havoc Pennington <hp@redhat.com>
4745 * bus/Makefile.am (install-data-hook): create /var/run/dbus
4747 * bus/messagebus.in: add init script for Red Hat /etc/init.d
4749 * configure.in: add support for specifying a style of init script
4752 2003-03-31 Havoc Pennington <hp@redhat.com>
4754 Fix some annoying DBusString API and fix all affected code.
4756 * dbus/dbus-string.c (_dbus_string_init): get rid of annoying
4758 (_dbus_string_get_data): change to return string instead of using
4760 (_dbus_string_get_const_data): ditto
4761 (_dbus_string_get_data_len): ditto
4762 (_dbus_string_get_const_data_len): ditto
4764 2003-03-31 Havoc Pennington <hp@redhat.com>
4766 * bus/main.c (main): fix up the command line arguments to be nicer
4768 2003-03-31 Havoc Pennington <hp@redhat.com>
4770 * dbus/Makefile.am (INCLUDES): use EXPANDED_LOCALSTATEDIR to
4771 define DBUS_SYSTEM_BUS_PATH as we want to compile in the same
4772 final location that lands in the config file
4774 * bus/config-loader-expat.c (bus_config_load): fix type of
4777 * doc/TODO: remove TODO item for dbus_bus_get()
4779 * dbus/dbus-bus.c (bus_data_free): add missing lock/unlock
4781 2003-03-31 Havoc Pennington <hp@pobox.com>
4783 * dbus/dbus-transport-unix.c (_dbus_transport_new_for_domain_socket)
4784 (_dbus_transport_new_for_tcp_socket): these didn't need the "server"
4785 argument since they are always client side
4787 * dbus/dbus-server.c (dbus_server_get_address): new function
4789 * bus/main.c (main): take the configuration file as an argument.
4791 * test/data/valid-config-files/debug-allow-all.conf: new file to
4792 use with dispatch.c tests for example
4794 * bus/test-main.c (main): require test data dir
4796 * bus/bus.c (bus_context_new): change this to take a
4797 configuration file name as argument
4799 * doc/config-file.txt (Elements): add <servicedir>
4801 * bus/system.conf, bus/session.conf: new files
4803 * dbus/dbus-bus.c (dbus_bus_get): look for system bus on
4804 well-known socket if none set
4806 * configure.in: create system.conf and session.conf
4808 2003-03-30 Havoc Pennington <hp@pobox.com>
4810 * bus/config-parser.c: hacking
4812 * dbus/dbus-memory.c: don't use DBusList for the list of stuff
4813 to shut down, since it could cause weirdness with the DBusList
4816 * dbus/dbus-list.c (_dbus_list_test): add tests for the
4817 link-oriented stack routines
4818 (alloc_link): free the mempool if the first alloc from it fails
4820 * dbus/dbus-mempool.c (struct DBusMemBlock): fix alignment issue
4822 * dbus/dbus-string.c (UNICODE_VALID): sync new version of this
4824 (_dbus_string_skip_white): new
4826 * doc/config-file.txt (Elements): add <includedir>
4828 2003-03-28 Havoc Pennington <hp@pobox.com>
4830 * dbus/dbus-string.c (_dbus_string_copy_data_len)
4831 (_dbus_string_copy_data): new functions
4833 2003-03-28 Anders Carlsson <andersca@codefactory.se>
4835 * dbus/dbus-bus.c: (bus_data_free), (dbus_bus_get):
4839 * dbus/dbus-memory.c:
4842 2003-03-28 Havoc Pennington <hp@pobox.com>
4844 * bus/test.c (bus_test_flush_bus): remove the sleep from here,
4845 I think it may have just been superstition. Not sure.
4847 * dbus/dbus-string.c (_dbus_string_base64_decode): catch some OOM
4848 failures that were not being handled.
4850 * dbus/dbus-auth.c (process_auth): fix a memleak in OOM handling
4852 * dbus/dbus-memory.c: add ability to set number of mallocs in a
4853 row that will fail on out-of-memory.
4855 * dbus/dbus-internals.c (_dbus_test_oom_handling): convenience
4856 function for testing out-of-memory handling.
4858 * bus/config-loader-expat.c (memsuite): don't wrap the dbus
4859 allocation functions, they do map exactly to the expat ones.
4861 2003-03-27 Havoc Pennington <hp@redhat.com>
4863 * bus/config-loader-libxml.c (bus_config_load): add another error
4866 2003-03-26 Anders Carlsson <andersca@codefactory.se>
4869 Add note about automatic service activation.
4871 * doc/dbus-specification.sgml:
4872 Rename the specification and clarify a few things.
4874 2003-03-26 Anders Carlsson <andersca@codefactory.se>
4877 * dbus/dbus-address.c:
4879 * dbus/dbus-marshal.c:
4880 * dbus/dbus-server-debug-pipe.c:
4881 * dbus/dbus-transport-unix.c:
4882 Fix documentation warnings.
4884 2003-03-26 Havoc Pennington <hp@pobox.com>
4886 * bus/test-main.c, dbus/dbus-test.c (main): check memleaks
4887 after every test so it's quick and easy to see which leaked, and
4888 so we test multiple dbus_shutdown() calls
4890 * configure.in: change configure.in XML stuff to also support
4893 * config-loader-libxml.c: some hacking
4895 * config-loader-expat.c: some hacking
4897 * config-parser.c: some hacking, plus tests
4899 2003-03-25 Havoc Pennington <hp@redhat.com>
4901 * throughout - add more _DBUS_ASSERT_ERROR_IS_CLEAR
4903 * configure.in: add --with-xml option to specify XML library,
4904 right now only libxml is supported.
4906 * bus/config-loader-libxml.c, config-parser.c: sync some minor
4907 nonworking code between home and work, still just stubs
4909 2003-03-24 Havoc Pennington <hp@redhat.com>
4911 * dbus/dbus-sysdeps.c (_dbus_set_fd_nonblocking): move to this
4914 * dbus/dbus-errors.c (dbus_set_error, dbus_set_error_const): allow
4915 NULL argument for "message" if the error is a well-known one,
4916 fill in a generic message in this case.
4918 * dbus/dbus-errors.h (DBusResultCode): Kill DBusResultCode in
4921 * bus/test.c (bus_test_flush_bus): add
4923 * bus/policy.c (bus_policy_test): test code stub
4925 2003-03-24 Havoc Pennington <hp@pobox.com>
4927 * bus/connection.c (bus_connections_setup_connection): set up
4928 the "can this user connect" function, but it always returns
4929 TRUE until we have a config file parser so we can have a config
4930 file that allows connections.
4932 2003-03-23 Havoc Pennington <hp@pobox.com>
4934 * dbus/dbus-threads.c (dbus_mutex_new, dbus_condvar_new): with
4935 DBUS_BUILD_TESTS, actually alloc/free a block of memory for
4936 the mutex, so we can check for proper memory management
4939 * dbus/dbus-dataslot.c: remove the mutex from
4940 DBusDataSlotAllocator and lock it manually when using it,
4941 to simplify fitting it into the global slots framework.
4943 * dbus/dbus-threads.c (init_static_locks): rework how we're
4944 handling global locks so they are easily shut down.
4946 * bus/policy.c (bus_policy_append_rule): fix
4948 * bus/test-main.c (main): check for memleaks
4950 * dbus/dbus-test.c (dbus_internal_do_not_use_run_tests): make
4951 test suite check for memleaks
4953 * dbus/dbus-memory.c: add support in test mode for tracking
4954 number of outstanding blocks
4956 2003-03-23 Havoc Pennington <hp@pobox.com>
4958 * bus/policy.c, bus/bus.c, bus/connection.c: implement allow/deny
4961 * dbus/dbus-hash.h: add ULONG hash keys
4963 * dbus/dbus-sysdeps.c (_dbus_get_groups): new
4964 (_dbus_get_group_id): new function
4966 2003-03-20 Havoc Pennington <hp@redhat.com>
4968 * dbus/dbus-connection.c (dbus_connection_set_unix_user_function):
4970 (dbus_connection_get_unix_user): new function
4972 2003-03-20 Havoc Pennington <hp@pobox.com>
4974 * bus/connection.c (bus_connection_send_oom_error): assert that
4975 message has a sender
4976 (connection_execute_transaction): ditto
4977 (bus_connection_preallocate_oom_error): fix to set the sender, and
4978 set recipient to the destination service, not the bus driver
4980 * bus/policy.c: hacking
4982 * dbus/dbus-message.c (dbus_message_service_is): new function
4983 (dbus_message_sender_is): new
4985 2003-03-19 Havoc Pennington <hp@redhat.com>
4987 * bus/policy.c: start sketching code for policy restrictions on
4988 what connections can do.
4990 2003-03-18 Havoc Pennington <hp@redhat.com>
4992 * doc/TODO: some notes on high-level todo items. Little nitpick
4993 stuff is all in @todo, so no need to add it here.
4995 * doc/config-file.txt: some notes on how config file might look
4997 2003-03-18 Anders Carlsson <andersca@codefactory.se>
5003 2003-03-17 Havoc Pennington <hp@redhat.com>
5005 * dbus/dbus-internals.h: add gcc attributes so that
5006 our printf-style functions warn on bad arguments to
5009 * dbus/dbus-sysdeps.c (_dbus_connect_tcp_socket): fix printf
5012 * dbus/dbus-message.c (_dbus_message_loader_queue_messages): fix
5015 2003-03-17 Havoc Pennington <hp@redhat.com>
5017 * bus/test-main.c (main): make it print something as it runs
5018 so make check doesn't look stuck
5020 * doc/negotiation.txt, doc/dbus-sasl-profile.txt: remove
5021 from CVS, now obsolete
5023 2003-03-17 Anders Carlsson <andersca@codefactory.se>
5025 * bus/dispatch.c: (bus_dispatch):
5026 Refetch the service name since it may have been reallocated
5027 when dbus_message_set_sender was called.
5029 * dbus/dbus-sysdeps.c: (_dbus_accept):
5030 Add address and address length variables and use them to stop
5031 valgrind from complaining.
5033 2003-03-17 Havoc Pennington <hp@pobox.com>
5035 All tests pass, no memleaks, no valgrind complaints.
5037 * bus/test.c: refcount handler_slot
5039 * bus/connection.c (bus_connections_new): refcount
5040 connection_data_slot
5042 * dbus/dbus-auth-script.c (_dbus_auth_script_run): delete unused
5043 bytes so that auth scripts pass.
5045 * bus/dispatch.c: init message_handler_slot so it gets allocated
5048 * bus/dispatch.c (message_handler_slot_ref): fix memleak
5050 * dbus/dbus-server-debug-pipe.c (_dbus_server_debug_pipe_new):
5051 dealloc server_pipe_hash when no longer used for benefit of
5054 * dbus/dbus-auth.c (process_command): memleak fix
5056 * bus/dispatch.c (check_hello_message): memleak fix
5058 2003-03-16 Havoc Pennington <hp@pobox.com>
5060 * dbus/dbus-bus.c (ensure_bus_data): fix double-unref of the data slot
5062 2003-03-17 Anders Carlsson <andersca@codefactory.se>
5064 * bus/activation.c (bus_activation_activate_service): Append
5065 the pending activation entry to the list of pending activations.
5067 2003-03-16 Havoc Pennington <hp@pobox.com>
5069 * bus/dispatch.c (bus_dispatch_test): remove double-unrefs of
5072 * dbus/dbus-address.c (create_entry): fix OOM handling when
5073 failing to alloc entry->method
5075 2003-03-16 Havoc Pennington <hp@pobox.com>
5077 * dbus/dbus-watch.c (_dbus_watch_new): handle failure to malloc
5080 * dbus/dbus-server-debug-pipe.c (_dbus_transport_debug_pipe_new):
5081 add some missing dbus_set_result
5083 * bus/dispatch.c (bus_dispatch_add_connection): handle failure to
5084 alloc the DBusMessageHandler
5086 * dbus/dbus-transport.c (_dbus_transport_disconnect): don't ref
5087 the transport here, since we call this from the finalizer; it
5088 resulted in a double-finalize.
5090 * dbus/dbus-transport.c (_dbus_transport_disconnect): fix a bug
5091 where we tried to use transport->connection that was NULL,
5092 happened when transport was disconnected early on due to OOM
5094 * bus/*.c: adapt to handle OOM for watches/timeouts
5096 * dbus/dbus-transport-unix.c: port to handle OOM during
5099 * dbus/dbus-auth.c (_dbus_auth_get_unused_bytes): return a
5100 reference to unused bytes instead of a copy
5102 * dbus/dbus-server.c (dbus_server_handle_watch): return FALSE for
5105 * dbus/dbus-connection.c (dbus_connection_handle_watch): return
5108 * dbus/dbus-timeout.c (dbus_timeout_handle): return FALSE for out
5111 2003-03-16 Anders Carlsson <andersca@codefactory.se>
5113 * doc/dbus-specification.sgml:
5114 Document reply message for ActivateService.
5116 2003-03-16 Anders Carlsson <andersca@codefactory.se>
5118 * bus/activation.c: (bus_pending_activation_entry_free),
5119 (bus_pending_activation_free), (bus_activation_new),
5120 (bus_activation_unref), (bus_activation_service_created),
5121 (bus_activation_activate_service):
5123 * bus/bus.c: (bus_context_new):
5124 * bus/desktop-file.c: (new_section):
5125 * bus/driver.c: (bus_driver_send_service_deleted),
5126 (bus_driver_handle_activate_service):
5127 * bus/services.c: (bus_registry_new), (bus_registry_ensure):
5129 * dbus/dbus-connection.c:
5130 (dbus_connection_send_with_reply_and_block):
5131 * dbus/dbus-message.c: (dbus_message_append_args_valist):
5132 * dbus/dbus-protocol.h:
5133 Make activation work better. Now pending activations will be queued
5134 and the daemon won't try to activate services that are already registered.
5136 2003-03-16 Havoc Pennington <hp@pobox.com>
5138 * dbus/dbus-bus.c (ensure_bus_data): handle failure to set
5141 * dbus/dbus-memory.c (_dbus_initialize_malloc_debug): support
5142 DBUS_MALLOC_BACKTRACES to print trace when failing an alloc
5144 2003-03-16 Havoc Pennington <hp@pobox.com>
5146 * dbus/dbus-string.c (_dbus_string_validate_utf8): oops, unbreak
5147 this. always run the test suite before commit...
5149 * bus/*: adapt to DBusConnection API changes
5151 * glib/dbus-gmain.c: adapt to DBusConnection API changes,
5152 requires renaming stuff to avoid dbus_connection_dispatch name
5155 * dbus/dbus-transport.c (_dbus_transport_queue_messages): new
5158 * dbus/dbus-message.c (_dbus_message_loader_queue_messages):
5159 separate from _dbus_message_loader_return_buffer()
5161 * dbus/dbus-connection.c (dbus_connection_get_n_messages): remove
5162 this, because it's now always broken to use; the number of
5163 messages in queue vs. the number still buffered by the message
5164 loader is undefined/meaningless. Should use
5165 dbus_connection_get_dispatch_state().
5166 (dbus_connection_dispatch): rename from
5167 dbus_connection_dispatch_message
5169 2003-03-16 Havoc Pennington <hp@pobox.com>
5171 * dbus/dbus-string.c (_dbus_string_validate_utf8): copy in a real
5174 2003-03-16 Anders Carlsson <andersca@codefactory.se>
5176 * dbus/dbus-connection.c:
5177 (dbus_connection_send_with_reply_and_block):
5178 Decrease connection->n_incoming when removing an entry
5180 * dbus/dbus-dict.c: (dbus_dict_entry_free),
5181 (dbus_dict_set_boolean_array), (dbus_dict_set_int32_array),
5182 (dbus_dict_set_uint32_array), (dbus_dict_set_double_array),
5183 (dbus_dict_set_byte_array), (dbus_dict_set_string_array),
5184 (dbus_dict_get_boolean_array), (dbus_dict_get_double_array),
5185 (dbus_dict_get_byte_array):
5186 Handle NULL arrays and strings. Also add support for byte arrays.
5188 * dbus/dbus-marshal.c: (_dbus_marshal_byte_array),
5189 (_dbus_marshal_dict), (_dbus_demarshal_byte_array),
5190 (_dbus_demarshal_int32_array), (_dbus_demarshal_uint32_array),
5191 (_dbus_demarshal_double_array), (_dbus_demarshal_string_array),
5192 (_dbus_demarshal_dict), (demarshal_and_validate_len),
5193 (_dbus_marshal_validate_arg), (_dbus_marshal_test):
5194 * dbus/dbus-marshal.h:
5195 Add support for marshalling and demarshalling empty arrays and strings.
5197 * dbus/dbus-message.c: (dbus_message_append_args_valist),
5198 (dbus_message_append_string_array),
5199 (dbus_message_iter_get_boolean),
5200 (dbus_message_iter_get_boolean_array),
5201 (dbus_message_iter_get_int32_array),
5202 (dbus_message_iter_get_uint32_array),
5203 (dbus_message_iter_get_double_array),
5204 (dbus_message_iter_get_byte_array),
5205 (dbus_message_iter_get_string_array), (dbus_message_iter_get_dict),
5206 (check_message_handling):
5207 Add support for getting empty arrays and dicts.
5209 * dbus/dbus-string.c: (_dbus_string_validate_utf8):
5210 Don't do any validation at all for now, that's better than just checking
5213 * test/data/valid-messages/emptiness.message:
5214 New test message with lots of empty arrays.
5216 2003-03-16 Havoc Pennington <hp@pobox.com>
5218 * dbus/dbus-connection.c
5219 (_dbus_connection_queue_received_message_link): new function that
5220 can't fail due to OOM
5222 * dbus/dbus-message.c (_dbus_message_loader_pop_message_link):
5223 new function pops a message together with a list link
5226 * dbus/dbus-transport-unix.c (queue_messages): use new link-based
5227 message queuing functions to avoid needing to alloc memory
5229 2003-03-16 Havoc Pennington <hp@pobox.com>
5231 Oops - test code was only testing failure of around 30 of the
5232 mallocs in the test path, but it turns out there are 500+
5233 mallocs. I believe this was due to misguided linking setup such
5234 that there was one copy of dbus_malloc etc. in the daemon and one
5235 in the shared lib, and only daemon mallocs were tested. In any
5236 case, the test case now tests all 500+ mallocs, and doesn't pass
5237 yet, though there are lots of fixes in this patch.
5239 * dbus/dbus-connection.c (dbus_connection_dispatch_message): fix
5240 this so that it doesn't need to allocate memory, since it
5241 has no way of indicating failure due to OOM (and would be
5242 annoying if it did).
5244 * dbus/dbus-list.c (_dbus_list_pop_first_link): new function
5246 * bus/Makefile.am: rearrange to create two self-contained
5247 libraries, to avoid having libraries with overlapping symbols.
5248 that was resulting in weirdness, e.g. I'm pretty sure there
5249 were two copies of global static variables.
5251 * dbus/dbus-internals.c: move the malloc debug stuff to
5254 * dbus/dbus-list.c (free_link): free list mempool if it becomes
5257 * dbus/dbus-memory.c (_dbus_disable_mem_pools): new function
5259 * dbus/dbus-address.c (dbus_parse_address): free list nodes
5262 * bus/dispatch.c (bus_dispatch_add_connection): free
5263 message_handler_slot when no longer using it, so
5264 memory leak checkers are happy for the test suite.
5266 * dbus/dbus-server-debug-pipe.c (debug_finalize): free server name
5268 * bus/bus.c (new_connection_callback): disconnect in here if
5269 bus_connections_setup_connection fails.
5271 * bus/connection.c (bus_connections_unref): fix to free the
5273 (bus_connections_setup_connection): if this fails, don't
5274 disconnect the connection, just be sure there are no side
5277 * dbus/dbus-string.c (undo_alignment): unbreak this
5279 * dbus/dbus-auth.c (_dbus_auth_unref): free some stuff we were
5281 (_dbus_auth_new): fix the order in which we free strings
5284 * bus/connection.c (bus_connection_disconnected): fix to
5285 not send ServiceDeleted multiple times in case of memory
5288 * dbus/dbus-bus.c (dbus_bus_get_base_service): new function to
5289 get the base service name
5290 (dbus_bus_register_client): don't return base service name,
5291 instead store it on the DBusConnection and have an accessor
5293 (dbus_bus_register_client): rename dbus_bus_register()
5295 * bus/dispatch.c (check_hello_message): verify that other
5296 connections on the bus also got the correct results, not
5297 just the one sending hello
5299 2003-03-15 Havoc Pennington <hp@pobox.com>
5301 Make it pass the Hello handling test including all OOM codepaths.
5302 Now to do other messages...
5304 * bus/services.c (bus_service_remove_owner): fix crash when
5305 removing owner from an empty list of owners
5306 (bus_registry_ensure): don't leave service in the list of
5307 a connection's owned services if we fail to put the service
5310 * bus/connection.c (bus_connection_preallocate_oom_error): set
5311 error flag on the OOM error.
5313 * dbus/dbus-connection.c (_dbus_connection_new_for_transport):
5314 handle _dbus_transport_set_connection failure
5316 * dbus/dbus-transport-unix.c (_dbus_transport_new_for_fd): modify
5317 to create watches up front and simply enable/disable them as
5319 (unix_connection_set): this can now fail on OOM
5321 * dbus/dbus-timeout.c, dbus/dbus-watch.c: add concept
5322 of enabling/disabling a watch or timeout.
5324 * bus/loop.c (bus_loop_iterate): don't touch disabled
5327 * glib/dbus-gmain.c: adapt to enable/disable watches and timeouts
5329 2003-03-15 Havoc Pennington <hp@pobox.com>
5331 * bus/dispatch.c (bus_dispatch_test): OK, now finally actually
5332 write useful test code, after all that futzing around ;-)
5334 Test does not yet pass because we can't handle OOM in
5335 _dbus_transport_messages_pending (basically,
5336 dbus_connection_preallocate_send() does not prealloc the write
5337 watch). To fix this, I think we need to add new stuff to
5338 set_watch_functions, namely a SetEnabled function so we can alloc
5339 the watch earlier, then enable it later.
5341 * dbus/Makefile.am (libdbus_convenience_la_SOURCES): move
5342 dbus-memory.c to the convenience lib
5344 * bus/test.c: rename some static functions to keep them clearly
5345 distinct from stuff in connection.c. Handle client disconnection.
5347 2003-03-14 Havoc Pennington <hp@pobox.com>
5349 * bus/dispatch.c (bus_dispatch_test): do test using debug-pipe
5350 transport, tests more of the real codepath. Set up clients
5351 with bus_setup_debug_client.
5353 * bus/test.c (bus_setup_debug_client): function to set up debug
5354 "clients" on the main loop
5356 * dbus/dbus-transport.c (_dbus_transport_open): add debug-pipe
5359 * dbus/dbus-server.c (dbus_server_listen): add debug-pipe
5362 * dbus/dbus-server-debug.c: support a debug server based on pipes
5364 * dbus/dbus-sysdeps.c (_dbus_full_duplex_pipe): new function
5365 (_dbus_close): new function
5367 * configure.in: check for socketpair
5369 2003-03-14 Havoc Pennington <hp@redhat.com>
5371 * dbus/dbus-memory.c: add a "detect buffer overwrites on free"
5374 * dbus/dbus-transport-debug.c: rework this a good bit to be
5375 less complicated. hopefully still works.
5377 * dbus/dbus-server-debug.c (handle_new_client): remove timeout
5380 * glib/dbus-gmain.c (timeout_handler): don't remove timeout
5383 * dbus/dbus-message.c (dbus_message_copy): rename from
5384 dbus_message_new_from_message, fix it up to copy
5385 all the message fields, add test case
5387 * bus/dispatch.c (bus_dispatch_test): add some more test code,
5388 not quite passing yet
5390 2003-03-14 Havoc Pennington <hp@pobox.com>
5392 * bus/loop.c (bus_loop_iterate): add this so we can "run loop
5393 until no work remains" in test code. (the large diff here
5394 is just code movement, no actual changes)
5396 * dbus/dbus-server-debug.c (DEFAULT_INTERVAL): change interval to
5397 1, no point waiting around for test code.
5398 (_dbus_server_debug_accept_transport): unref the timeout
5399 after adding it (right?)
5401 * dbus/dbus-transport-debug.c (DEFAULT_INTERVAL): ditto
5403 2003-03-13 Havoc Pennington <hp@redhat.com>
5405 * dbus/dbus-timeout.c (_dbus_timeout_list_set_functions): handle
5408 * dbus/dbus-watch.c (_dbus_watch_list_set_functions): handle out
5411 * dbus/dbus-connection.h: Make AddWatchFunction and
5412 AddTimeoutFunction return a bool so they can fail on out-of-memory
5414 * bus/bus.c (bus_context_new): set up timeout handlers
5416 * bus/connection.c (bus_connections_setup_connection): set up
5419 * glib/dbus-gmain.c: adapt to the fact that set_functions stuff
5422 * bus/bus.c (bus_context_new): adapt to changes
5424 * bus/connection.c: adapt to changes
5426 * test/watch.c: adapt to DBusWatch changes
5428 * bus/dispatch.c (bus_dispatch_test): started adding this but
5431 2003-03-14 Anders Carlsson <andersca@codefactory.se>
5433 * bus/dispatch.c (send_service_nonexistent_error): Fix typo.
5435 2003-03-13 Havoc Pennington <hp@pobox.com>
5437 * bus/test.c, bus/test.h, bus/Makefile.am, bus/test-main.c:
5438 set up a test framework as for the library
5440 2003-03-12 Havoc Pennington <hp@pobox.com>
5442 Throughout: purge global variables, introduce BusActivation,
5443 BusConnections, BusRegistry, etc. objects instead.
5445 * bus/bus.h, bus/bus.c: introduce BusContext as a global
5448 * test/Makefile.am (TEST_BINARIES): disable bus-test for now,
5449 going to redo this a bit differently I think
5451 2003-03-12 Havoc Pennington <hp@redhat.com>
5453 Mega-patch that gets the message bus daemon initially handling
5454 out-of-memory. Work still needed. Also lots of random
5455 moving stuff to DBusError instead of ResultCode.
5457 * dbus/dbus-list.c (_dbus_list_length_is_one): new function
5459 * dbus/dbus-connection.c
5460 (dbus_connection_send_with_reply_and_block): use DBusError
5462 * dbus/dbus-bus.c: adapt to API changes, make it use DBusError not
5465 * dbus/dbus-connection.c (dbus_connection_send): drop the result
5466 code here, as the only failure possible is OOM.
5468 * bus/connection.c (bus_connection_disconnect):
5469 rename bus_connection_disconnected as it's a notification only
5471 * bus/driver.c (bus_driver_handle_acquire_service): don't free
5472 "name" on get_args failure, should be done by get_args;
5473 don't disconnect client for bad args, just return an error.
5474 (bus_driver_handle_service_exists): ditto
5476 * bus/services.c (bus_services_list): NULL-terminate returned array
5478 * bus/driver.c (bus_driver_send_service_lost)
5479 (bus_driver_send_service_acquired): send messages from driver to a
5480 specific client to the client's unique name, not to the broadcast
5483 * dbus/dbus-message.c (decode_header_data): reject messages that
5484 contain no name field
5485 (_dbus_message_get_client_serial): rename to
5486 dbus_message_get_serial and make public
5487 (_dbus_message_set_serial): rename from set_client_serial
5488 (_dbus_message_set_reply_serial): make public
5489 (_dbus_message_get_reply_serial): make public
5491 * bus/connection.c (bus_connection_foreach): allow stopping
5492 iteration by returning FALSE from foreach function.
5494 * dbus/dbus-connection.c (dbus_connection_send_preallocated)
5495 (dbus_connection_free_preallocated_send)
5496 (dbus_connection_preallocate_send): new API for sending a message
5497 without possibility of malloc failure.
5498 (dbus_connection_send_message): rename to just
5499 dbus_connection_send (and same for whole function family)
5501 * dbus/dbus-errors.c (dbus_error_free): make this reinit the error
5503 * dbus/dbus-sysdeps.c (_dbus_exit): new function
5505 * bus/activation.c: handle/return errors
5507 * dbus/dbus-errors.h: add more DBUS_ERROR #define
5509 * dbus/dbus-sysdeps.c (_dbus_directory_open) (_dbus_file_get_contents)
5510 (_dbus_directory_get_next_file): use DBusError instead of DBusResultCode
5511 (_dbus_result_from_errno): move to this file
5513 2003-03-10 Anders Carlsson <andersca@codefactory.se>
5515 * dbus/dbus-marshal.c:
5516 (_dbus_marshal_set_string):
5517 Take a length argument so we can marshal the correct string
5520 (_dbus_marshal_dict), (_dbus_demarshal_dict),
5521 (_dbus_marshal_get_arg_end_pos), (_dbus_marshal_validate_arg),
5522 (_dbus_marshal_test):
5523 * dbus/dbus-marshal.h:
5524 Add support for marshalling and demarshalling dicts.
5526 * dbus/dbus-message-builder.c: (_dbus_message_data_load):
5527 Add support for TYPE DICT.
5529 * dbus/dbus-message.c: (set_string_field):
5530 Adjust header padding.
5532 (dbus_message_append_args_valist), (dbus_message_append_dict),
5533 (dbus_message_get_args_valist), (dbus_message_iter_get_arg_type),
5534 (dbus_message_iter_get_dict), (_dbus_message_loader_return_buffer),
5535 (check_message_handling), (check_have_valid_message):
5536 * dbus/dbus-message.h:
5537 Add functions for setting and getting dicts.
5539 * dbus/dbus-protocol.h:
5545 * doc/dbus-specification.sgml:
5546 Add information about how dicts are marshalled.
5548 * test/data/invalid-messages/dict-with-nil-value.message:
5549 * test/data/invalid-messages/too-short-dict.message:
5550 * test/data/valid-messages/dict-simple.message:
5551 * test/data/valid-messages/dict.message:
5552 Add sample messages containing dicts.
5554 2003-03-08 Anders Carlsson <andersca@codefactory.se>
5556 * dbus/dbus-dict.h: Add DBUS_END_DECLS.
5558 2003-03-07 Anders Carlsson <andersca@codefactory.se>
5561 * dbus/dbus-dict.c: (dbus_dict_entry_free), (dbus_dict_new),
5562 (dbus_dict_get_keys), (insert_entry), (dbus_dict_set_boolean),
5563 (dbus_dict_set_int32), (dbus_dict_set_uint32),
5564 (dbus_dict_set_double), (dbus_dict_set_string),
5565 (dbus_dict_set_boolean_array), (dbus_dict_set_int32_array),
5566 (dbus_dict_set_uint32_array), (dbus_dict_set_double_array),
5567 (dbus_dict_set_string_array), (_dbus_dict_test):
5569 Fix according to comments from Havoc.
5571 2003-03-06 Michael Meeks <michael@server.home>
5573 * configure.in: if we don't have kde-config, disable have_qt.
5575 2003-03-07 Anders Carlsson <andersca@codefactory.se>
5580 * dbus/dbus-dict.c: (dbus_dict_entry_free), (dbus_dict_new),
5581 (dbus_dict_ref), (dbus_dict_unref), (dbus_dict_contains),
5582 (dbus_dict_remove), (dbus_dict_get_value_type),
5583 (dbus_dict_get_keys), (dbus_dict_put_boolean),
5584 (dbus_dict_put_int32), (dbus_dict_put_uint32),
5585 (dbus_dict_put_double), (dbus_dict_put_string),
5586 (dbus_dict_put_boolean_array), (dbus_dict_put_int32_array),
5587 (dbus_dict_put_uint32_array), (dbus_dict_put_double_array),
5588 (dbus_dict_put_string_array), (dbus_dict_get_boolean),
5589 (dbus_dict_get_int32), (dbus_dict_get_uint32),
5590 (dbus_dict_get_double), (dbus_dict_get_string),
5591 (dbus_dict_get_boolean_array), (dbus_dict_get_int32_array),
5592 (dbus_dict_get_uint32_array), (dbus_dict_get_double_array),
5593 (dbus_dict_get_string_array), (_dbus_dict_test):
5595 Add DBusDict implementation
5597 * dbus/dbus-test.c: (dbus_internal_do_not_use_run_tests):
5601 2003-03-04 Havoc Pennington <hp@pobox.com>
5603 * test/data/auth/*: adapt to changes
5605 * dbus/dbus-auth-script.c (_dbus_auth_script_run): add
5606 USERID_BASE64 and change USERNAME_BASE64 to put in username not
5609 * dbus/dbus-keyring.c (_dbus_keyring_validate_context): prevent
5610 more stuff from being in a context name, to make the protocol
5611 simpler to deal with
5613 * dbus/dbus-errors.c (dbus_error_has_name): new function
5614 (dbus_error_is_set): new function
5616 * dbus/dbus-auth.c: replace DBUS_STUPID_TEST_MECH auth
5617 with DBUS_COOKIE_SHA1, implement DBUS_COOKIE_SHA1
5619 * dbus/dbus-connection.c (dbus_connection_flush): also read
5620 messages during a flush operation
5622 * dbus/Makefile.am: remove dbus-md5 since it isn't currently used.
5624 2003-03-05 Anders Carlsson <andersca@codefactory.se>
5626 * configure.in: Check for gethostbyname on Solaris.
5628 * dbus/dbus-transport.c: (_dbus_transport_open):
5629 Remove duplicate "tcp" entry.
5631 * doc/dbus-specification.sgml:
5632 Clarify some things.
5634 2003-03-05 Anders Carlsson <andersca@codefactory.se>
5636 * dbus/dbus-auth.c: (send_rejected), (process_test_subdir):
5637 * dbus/dbus-keyring.c: (_dbus_keyring_new_homedir),
5638 (_dbus_keyring_test):
5639 * dbus/dbus-md5.c: (_dbus_md5_compute):
5640 * dbus/dbus-sha.c: (_dbus_sha_compute):
5643 2003-03-05 Anders Carlsson <andersca@codefactory.se>
5645 * README: Add some things.
5647 2003-03-04 Anders Carlsson <andersca@codefactory.se>
5649 * dbus/dbus-message.c (dbus_message_append_args_valist): Add a break;
5650 after case DBUS_TYPE_BOOELAN.
5652 2003-03-02 Havoc Pennington <hp@pobox.com>
5654 * test/break-loader.c (randomly_set_extreme_ints): add test that
5655 sets really huge and small integers
5657 * dbus/dbus-marshal.c (_dbus_marshal_validate_arg): add check
5658 that length of boolean array fits in the string, and that
5659 string has room for boolean value in single-bool case.
5661 * dbus/dbus-message-builder.c (_dbus_message_data_load): add
5662 optional value to "ALIGN" command which is what to fill the
5665 * test/data/valid-messages/no-padding.message: add regression
5666 test for the message padding problem
5668 2003-03-02 Havoc Pennington <hp@pobox.com>
5670 * dbus/dbus-message.c (decode_header_data): fix to always init
5671 message_padding, from Benjamin Dauvergne
5673 2003-03-02 Havoc Pennington <hp@pobox.com>
5679 2003-03-01 Joe Shaw <joe@assbarn.com>
5681 * configure.in: Check for "struct cmsgcred" and try to access its
5682 members for BSD-like unices.
5684 * dbus/dbus-sysdeps.c (read_credentials_byte): Fold this back into
5685 _dbus_read_credentials_unix_socket().
5686 (_dbus_read_credentials_unix_socket): Use recvmsg() instead of
5687 read() for reading the credential byte off the unix socket. Use
5688 struct cmsgcred on systems that support it.
5690 2003-02-27 Alexander Larsson <alexl@redhat.com>
5694 Make gthreads-2.0 dependency optional. Don't build thread test if
5697 2003-02-27 Havoc Pennington <hp@pobox.com>
5699 * dbus/dbus-connection.c
5700 (dbus_connection_send_message_with_reply_and_block): fix doh!
5701 doh! doh! bug that resulted in never removing a reply from the
5702 queue, no wonder we called get_reply_serial so much ;-)
5704 * dbus/dbus-message.c (struct DBusMessage): cache reply serial
5705 and client serial instead of demarshaling them every time
5707 2003-02-27 Havoc Pennington <hp@pobox.com>
5709 * dbus/dbus-marshal.c (_dbus_demarshal_int32): rewrite to be much
5710 more inlined, using dbus-string-private.h, speeds things up
5713 * dbus/dbus-string.c (_dbus_string_free): apply align offset
5714 when freeing the string
5715 (_dbus_string_steal_data): fix for align offset
5716 (undo_alignment): new function
5718 2003-02-26 Havoc Pennington <hp@redhat.com>
5720 All kinds of audit fixes from Owen, plus initial attempt to
5721 handle unaligned memory returned from malloc.
5723 * dbus/dbus-string.c (_dbus_string_init): clamp max length to
5724 leave room for align_offset and nul byte
5725 (fixup_alignment): function to track an align_offset and
5726 ensure real->str is aligned
5727 (DBUS_GENERIC_STRING_PREAMBLE): len must be less than allocated,
5728 to allow a nul byte plus align offset
5729 (_dbus_string_lock): fix overflow issue
5730 (_dbus_string_init_const_len): add assertions on sanity of len,
5731 assign allocated to be ALLOCATION_PADDING larger than len
5732 (set_length): fixup the overflow handling
5733 (_dbus_string_get_data_len): fix overflow in assertion
5734 (open_gap): detect overflow in size of gap to be opened
5735 (_dbus_string_lengthen): add overflow check
5736 (_dbus_string_align_length): fix overflow with _DBUS_ALIGN_VALUE
5737 (_dbus_string_append): add overflow check
5738 (_dbus_string_append_unichar): overflow
5739 (_dbus_string_delete): fix overflow in assertion
5740 (_dbus_string_copy_len): overflow in assertion
5741 (_dbus_string_replace_len): overflows in assertions
5742 (_dbus_string_find): change to implement in terms of
5743 _dbus_string_find_to
5744 (_dbus_string_find_to): assorted fixage
5745 (_dbus_string_equal_c_str): assert c_str != NULL,
5746 fix logic so the function works
5747 (_dbus_string_ends_with_c_str): fix overflow thingy
5748 (_dbus_string_base64_encode): overflow fix
5749 (_dbus_string_validate_ascii): overflow
5750 (_dbus_string_validate_nul): overflow
5752 2003-02-26 Havoc Pennington <hp@redhat.com>
5754 * dbus/dbus-marshal.c (_dbus_marshal_test): fix to work with DISABLE_ASSERTS
5756 2003-02-26 Alexander Larsson <alexl@redhat.com>
5759 Set DBUS_GLIB_THREADS_LIBS for apps using gthread-2.0
5761 * dbus/dbus-connection.c:
5762 * dbus/dbus-connection.h:
5763 Fix _dbus_connection_acquire_io_path and _dbus_connection_acquire_dispatch.
5764 Add dbus_connection_set_wakeup_main_function and use it when queueing
5765 incoming and outgoing messages.
5768 * dbus/dbus-dataslot.c:
5769 Threadsafe usage of DBusDataSlotAllocator
5771 * dbus/dbus-message.c: (dbus_message_get_args_iter):
5774 * dbus/dbus-server-unix.c:
5777 * glib/dbus-gmain.c:
5778 Implement the new wakeup functions for glib.
5781 * glib/test-thread-client.c:
5782 * glib/test-thread-server.c:
5783 * glib/test-thread.h:
5784 Initial cut at some thread test code. Not really done yet.
5786 2003-02-26 Havoc Pennington <hp@pobox.com>
5788 * dbus/dbus-connection.c
5789 (dbus_connection_send_message_with_reply_and_block): fix crash
5790 where we ref'd the outgoing message instead of the returned reply
5792 * dbus/dbus-transport-unix.c (do_authentication): check read watch
5793 at the end of this function, so if we didn't need to read for
5794 authentication, we reinstall it for receiving messages
5796 * dbus/dbus-message.c (dbus_message_new_reply): allow replies to
5797 a NULL sender for peer-to-peer case
5799 * dbus/dbus-transport-unix.c (check_read_watch): handle
5800 !authenticated case correctly
5802 * glib/dbus-gmain.c: add support for DBusServer
5804 * dbus/dbus-server.c: add data slot support
5806 * glib/dbus-gmain.c (dbus_connection_setup_with_g_main): check
5807 return values and handle errors
5809 * dbus/dbus-dataslot.c: factor out the data slot stuff from
5812 * Doxyfile.in (INPUT): add glib subdir
5814 * glib/dbus-gmain.c (dbus_connection_setup_with_g_main): rename
5815 setup_with_g_main instead of hookup_with_g_main; write docs
5817 2003-02-24 Anders Carlsson <andersca@codefactory.se>
5819 * dbus/dbus-marshal.c: (_dbus_marshal_validate_arg):
5820 * dbus/dbus-message-builder.c: (_dbus_message_data_load):
5821 * dbus/dbus-message.c: (dbus_message_append_boolean),
5822 (dbus_message_append_boolean_array),
5823 (dbus_message_get_args_valist), (_dbus_message_test):
5824 * dbus/dbus-message.h:
5825 * doc/dbus-specification.sgml:
5826 Various fixes as pointed out by Havoc.
5828 * test/data/invalid-messages/bad-boolean-array.message:
5829 * test/data/invalid-messages/bad-boolean.message:
5830 Add invalid boolean value test cases.
5832 2003-02-24 Anders Carlsson <andersca@codefactory.se>
5834 * dbus/dbus-internals.c: (_dbus_type_to_string):
5835 * dbus/dbus-marshal.c: (_dbus_marshal_get_arg_end_pos),
5836 (_dbus_marshal_validate_arg):
5837 * dbus/dbus-message-builder.c: (_dbus_message_data_load):
5838 * dbus/dbus-message.c: (dbus_message_append_args_valist),
5839 (dbus_message_append_boolean), (dbus_message_append_boolean_array),
5840 (dbus_message_get_args_valist), (dbus_message_iter_get_boolean),
5841 (dbus_message_iter_get_int32), (dbus_message_iter_get_uint32),
5842 (dbus_message_iter_get_double),
5843 (dbus_message_iter_get_boolean_array), (message_iter_test):
5844 * dbus/dbus-message.h:
5845 * dbus/dbus-protocol.h:
5846 * doc/dbus-specification.sgml:
5847 * test/data/valid-messages/lots-of-arguments.message:
5848 Add support for boolean and boolean array types.
5850 2003-02-23 Havoc Pennington <hp@pobox.com>
5852 * dbus/dbus-keyring.c: finish most of this implementation and
5855 * dbus/dbus-errors.c (dbus_set_error_const, dbus_set_error): make
5856 these barf if the error isn't cleared to NULL
5858 * dbus/dbus-sysdeps.c (_dbus_delete_file): set error on failure
5859 (_dbus_create_directory): new function
5861 * dbus/dbus-errors.c (dbus_set_error): fix warning
5863 * dbus/dbus-string.c (_dbus_string_hex_encode): new function
5864 (_dbus_string_hex_decode): new function
5865 (test_hex_roundtrip): test code
5867 * dbus/dbus-sha.c (_dbus_sha_compute): use dbus_string_hex_encode
5869 * dbus/dbus-md5.c (_dbus_md5_compute): use dbus_string_hex_encode
5871 * dbus/dbus-sysdeps.c (_dbus_string_save_to_file): make this use
5872 the save-to-temp/rename trick to atomically write the new file
5873 (_dbus_string_parse_uint): new function
5875 2003-02-22 Havoc Pennington <hp@pobox.com>
5877 * test/Makefile.am (dist-hook): fix dist for test/data/sha-1
5879 2003-02-22 Havoc Pennington <hp@pobox.com>
5881 * dbus/dbus-message.c (dbus_message_iter_get_string_array):
5882 (dbus_message_iter_get_byte_array): Fix up doxygen warnings
5884 * dbus/dbus-sha.c: add implementation of SHA-1 algorithm
5886 * dbus/test/data/sha-1: add US government test suite for SHA-1
5888 2003-02-21 Anders Carlsson <andersca@codefactory.se>
5890 * dbus/dbus-marshal.c: (_dbus_demarshal_string_array):
5891 Make string arrays NULL-terminated.
5893 * dbus/dbus-memory.c: (dbus_free_string_array):
5894 * dbus/dbus-memory.h:
5895 New function for freeing NULL-terminated string arrays.
5897 * dbus/dbus-message-builder.c: (append_quoted_string),
5898 (_dbus_message_data_load):
5899 Add support for array types.
5901 * dbus/dbus-message.c: (check_message_handling):
5902 Add more types as test cases.
5904 * dbus/dbus-sysdeps.c: (_dbus_string_parse_int),
5905 (_dbus_string_parse_double):
5906 Add the start offset to the end offset.
5908 * test/data/valid-messages/lots-of-arguments.message:
5909 New test message with lots of arguments.
5911 2003-02-21 Anders Carlsson <andersca@codefactory.se>
5913 * dbus/dbus-message.c: (dbus_message_append_nil),
5914 (dbus_message_append_int32), (dbus_message_append_uint32),
5915 (dbus_message_append_double), (dbus_message_append_string),
5916 (dbus_message_append_int32_array),
5917 (dbus_message_append_uint32_array),
5918 (dbus_message_append_double_array),
5919 (dbus_message_append_byte_array),
5920 (dbus_message_append_string_array):
5921 Fix all out-of-memory handling in these functions.
5923 2003-02-21 Anders Carlsson <andersca@codefactory.se>
5925 * dbus/dbus-message.c: (dbus_message_append_nil):
5928 2003-02-21 Anders Carlsson <andersca@codefactory.se>
5930 * dbus/dbus-message.c: (dbus_message_append_args_valist),
5931 (dbus_message_append_nil), (dbus_message_append_int32_array),
5932 (dbus_message_append_uint32_array),
5933 (dbus_message_append_double_array),
5934 (dbus_message_append_byte_array),
5935 (dbus_message_append_string_array), (dbus_message_get_args_valist),
5936 (dbus_message_iter_get_int32_array),
5937 (dbus_message_iter_get_uint32_array),
5938 (dbus_message_iter_get_double_array),
5939 (dbus_message_iter_get_byte_array),
5940 (dbus_message_iter_get_string_array):
5942 * dbus/dbus-message.h:
5943 Add functions for appending and getting arrays.
5945 2003-02-21 Anders Carlsson <andersca@codefactory.se>
5947 * dbus/dbus-mempool.c (_dbus_mem_pool_new): Make the
5948 element size at least 8 bytes, fixes mempool tests on
5951 2003-02-20 Alexander Larsson <alexl@redhat.com>
5953 * dbus/dbus-transport-unix.c (unix_do_iteration):
5954 Unlock the connection mutex during a blocking select call.
5955 Add todo about how we need a way to wake up the select.
5957 * dbus/dbus-connection-internal.h:
5958 * dbus/dbus-connection.c:
5959 Add _dbus_connection_lock and _dbus_connection_unlock.
5961 2003-02-19 Havoc Pennington <hp@pobox.com>
5963 * Doxyfile.in (PREDEFINED): put DOXYGEN_SHOULD_SKIP_THIS in
5964 Doxyfile.in, not Doxyfile
5966 * dbus/dbus-keyring.c: do some hacking on this
5968 * dbus/dbus-sysdeps.c (_dbus_delete_file): new
5970 * dbus/dbus-errors.c (dbus_set_error_const): do not call
5972 (dbus_set_error): remove dbus_error_init, check for message ==
5973 NULL *before* we sprintf into it, and add @todo about including
5974 system headers in this file
5976 * dbus/dbus-sysdeps.c (_dbus_create_file_exclusively): new
5978 * dbus/dbus-errors.h (DBUS_ERROR_FAILED): add
5980 * dbus/dbus-sysdeps.c (get_user_info): break this function out to
5981 get various bits of user information based on either username
5983 (_dbus_homedir_from_username): new function
5985 2003-02-19 Anders Carlsson <andersca@codefactory.se>
5988 Add check for nonposix getpwnam_r
5990 * dbus/dbus-mempool.c: (_dbus_mem_pool_new):
5991 Align the pool element size to a sizeof (void *) boundary.
5993 * dbus/dbus-sysdeps.c: (_dbus_setenv), (_dbus_connect_unix_socket),
5994 (_dbus_listen_unix_socket), (_dbus_credentials_from_username):
5995 General Solaris fixes.
5997 * test/data/valid-messages/simplest-manual.message:
5998 Explicitly state that we want little-endian packing.
6000 2003-02-19 Mikael Hallendal <micke@codefactory.se>
6002 * dbus/dbus-server.c (dbus_server_listen): Support tcp: addresses.
6004 * dbus/dbus-transport-unix.c (_dbus_transport_new_for_tcp_socket):
6005 Added to create a transport connecting using a tcp/ip socket.
6007 * dbus/dbus-sysdeps.c (_dbus_connect_tcp_socket): Added to connect
6008 to a tcp socket at given host and port.
6009 (_dbus_listen_tcp_socket): added to listen on tcp socket for given
6012 * dbus/dbus-server.c (dbus_server_listen): Support tcp: addresses.
6014 * dbus/dbus-server-unix.c (_dbus_server_new_for_tcp_socket):
6015 Added to create a server listening on a TCP/IP socket.
6017 2003-02-19 Havoc Pennington <hp@pobox.com>
6019 Throughout: mop up all the Doxygen warnings and undocumented
6022 * dbus/dbus-sysdeps.c (do_exec): do not use execvp, we don't want
6023 to search any paths.
6025 * dbus/dbus-threads.c: move global mutex initializers to
6026 dbus-internals.h, multiple prototypes was confusing doxygen
6027 besides being kind of ugly
6029 * Doxyfile (PREDEFINED): have Doxygen define
6030 DOXYGEN_SHOULD_SKIP_THIS so we can exclude things from
6031 docs with #ifndef DOXYGEN_SHOULD_SKIP_THIS
6032 (do not abuse the feature! it's for stuff like the autogenerated
6033 macros in dbus-md5.c, not just for things you don't feel like
6036 2003-02-18 Havoc Pennington <hp@pobox.com>
6038 * dbus/dbus-string.c (_dbus_string_zero): new function
6040 * dbus/dbus-md5.c: include MD5 implementation by L. Peter Deutsch,
6041 wrap it in some dbus-friendly API
6043 * dbus/dbus-types.h: add 16-bit types
6045 2003-02-18 Joe Shaw <joe@assbarn.com>
6047 * dbus/dbus-auth.c (handle_server_data_stupid_test_mech): Just get
6048 credentials from our currently running process.
6049 (get_word): Fix a buglet where we were copying the entire length
6050 instead of relative to our position.
6052 * dbus/dbus-hash.c (_dbus_hash_test): Don't try to allocate the
6053 keys on the stack... it's 640k of data.
6055 * dbus/dbus-sysdeps.c (_dbus_read_credentials_unix_socket): Always
6056 read the credentials byte off the socket, even if we don't have
6058 (_dbus_poll): Implement poll() using select() for systems which
6061 * glib/test-dbus-glib.c (main): Print out an error if no
6062 parameters are given.
6064 * test/data/auth/fallback.auth-script: Added. Tests that a client
6065 can fallback to a secondary auth mechanism if the first fails.
6067 2003-02-18 Havoc Pennington <hp@pobox.com>
6071 2003-02-17 Havoc Pennington <hp@pobox.com>
6073 * doc/dbus-specification.sgml: lots of cosmetic
6074 cleanups/rearrangement, add assorted FIXME, change DBUS_ADDRESS
6075 env variable to DBUS_BUS_ADDRESS, s/client/application/,
6076 s/server/bus/ (except in authentication section). Add a section
6077 "Message Bus Message Routing"
6079 2003-02-17 Anders Carlsson <andersca@codefactory.se.>
6085 2003-02-17 Anders Carlsson <andersca@codefactory.se>
6087 * doc/dbus-specification.sgml:
6088 Specification updates.
6090 2003-02-17 Anders Carlsson <andersca@codefactory.se>
6092 * bus/activation.c: (bus_activation_init), (child_setup),
6093 (bus_activation_activate_service):
6095 * bus/main.c: (main):
6096 Set DBUS_ADDRESS environment variable.
6098 * dbus/dbus-errors.c: (dbus_set_error):
6099 Don't use va_copy since that's a C99 feature.
6101 * dbus/dbus-sysdeps.c: (_dbus_setenv), (do_exec),
6102 (_dbus_spawn_async):
6103 * dbus/dbus-sysdeps.h:
6104 Add child_setup_func to _dbus_spawn_async.
6106 * doc/dbus-specification.sgml:
6107 Update specification.
6109 * test/spawn-test.c: (setup_func), (main):
6112 2003-02-17 Alexander Larsson <alexl@redhat.com>
6114 * dbus/dbus-connection.c (_dbus_connection_handler_destroyed_locked):
6117 2003-02-17 Anders Carlsson <andersca@codefactory.se>
6121 * doc/dbus-test-plan.sgml:
6122 Add test plan document.
6127 2003-02-17 Anders Carlsson <andersca@codefactory.se>
6129 * dbus/dbus-message.c: (decode_header_data),
6130 (_dbus_message_loader_return_buffer):
6131 Set the header padding amount when loading a message.
6133 2003-02-16 Anders Carlsson <andersca@codefactory.se>
6135 * bus/dispatch.c: (send_one_message):
6136 Only send broadcast messages to registered connections.
6138 * dbus/dbus-message.c: (dbus_message_name_is):
6139 * dbus/dbus-message.h:
6140 New convenience function.
6142 * dbus/dbus-transport-debug.c: (do_reading):
6143 Only dispatch one message per run.
6146 * test/bus-test.c: (new_connection_callback), (die),
6147 (test_hello_client1_handler), (test_hello_client2_handler),
6148 (test_hello_replies), (main):
6150 * test/bus-test-loop.[ch]:
6153 2003-02-16 Havoc Pennington <hp@pobox.com>
6155 * dbus/dbus-connection.c (dbus_connection_dispatch_message): fix
6156 backward conditional
6158 2003-02-16 Alexander Larsson <alexl@redhat.com>
6160 * dbus/dbus-connection.c:
6161 Implement sent_message_with_reply. (with_reply_and block is still
6163 Made dispatch_message not lose message if OOM.
6165 * dbus/dbus-errors.h:
6166 Add NoReply error (for reply timeouts).
6168 2003-02-16 Alexander Larsson <alexl@redhat.com>
6170 * dbus/dbus-hash.c (_dbus_hash_table_unref):
6171 Actually free keys and values when destroying hashtable.
6173 2003-02-16 Anders Carlsson <andersca@codefactory.se>
6175 * dbus/dbus-auth.c: (client_try_next_mechanism):
6178 * dbus/dbus-threads.c: (dbus_condvar_wait_timeout):
6179 Return TRUE if there's no thread implementation around.
6181 * glib/dbus-gmain.c: (free_source),
6182 (dbus_connection_hookup_with_g_main):
6183 Make sure to remove the GSource when the connection is finalized.
6185 2003-02-16 Anders Carlsson <andersca@codefactory.se>
6187 * bus/dispatch.c: (bus_dispatch_message_handler):
6188 * dbus/dbus-errors.h:
6189 Return an error if someone tries to send a message to a service
6192 2003-02-16 Anders Carlsson <andersca@codefactory.se>
6194 * bus/activation.c: (load_directory), (bus_activation_init),
6195 (bus_activation_activate_service):
6198 (bus_driver_handle_activate_service), (bus_driver_handle_message):
6199 More work on the activation handling.
6201 * dbus/dbus-errors.h:
6202 Add some error messages
6204 * dbus/dbus-message.c: (dbus_message_new_error_reply):
6205 * dbus/dbus-message.h:
6206 New function that creates an error message.
6208 * dbus/dbus-protocol.h:
6209 Add ACTIVATE_SERVER message.
6211 * dbus/dbus-server-unix.c: (unix_handle_watch),
6212 (_dbus_server_new_for_domain_socket):
6213 Call _dbus_fd_set_close_on_exec.
6215 * dbus/dbus-sysdeps.c: (make_pipe), (do_exec),
6216 (_dbus_spawn_async), (_dbus_disable_sigpipe),
6217 (_dbus_fd_set_close_on_exec):
6218 * dbus/dbus-sysdeps.h:
6219 Add _dbus_fd_set_close_on exec function. Also add function that checks
6220 that all open fds are set to close-on-exec and warns otherwise.
6222 * dbus/dbus-transport-unix.c:
6223 (_dbus_transport_new_for_domain_socket):
6224 Call _dbus_fd_set_close_on_exec.
6226 2003-02-16 Havoc Pennington <hp@pobox.com>
6228 * dbus/dbus-connection.c (dbus_connection_set_change_sigpipe):
6229 allow people to avoid setting SIGPIPE to SIG_IGN
6230 (_dbus_connection_new_for_transport): disable SIGPIPE unless
6231 we've been asked not to
6233 2003-02-15 Anders Carlsson <andersca@codefactory.se>
6235 * dbus/dbus-list.c: (_dbus_list_append_link),
6236 (_dbus_list_prepend_link):
6237 * dbus/dbus-memory.c: (dbus_malloc), (dbus_malloc0),
6241 2003-02-15 Anders Carlsson <andersca@codefactory.se>
6244 * bus/activation.c: (bus_activation_entry_free),
6245 (add_desktop_file_entry), (load_directory), (bus_activation_init):
6247 * bus/main.c: (main):
6248 Add simple activation support, doesn't work yet though.
6250 2003-02-15 Zack Rusin <zack@kde.org>
6252 * qt/dbus-qthread.cpp: small casting fix
6254 2003-02-15 Anders Carlsson <andersca@codefactory.se>
6256 * dbus/dbus-errors.c: (dbus_set_error):
6257 * dbus/dbus-errors.h:
6258 Add a few errors and make dbus_set_error void.
6260 * dbus/dbus-sysdeps.c:
6261 (_dbus_errno_to_string), (close_and_invalidate), (make_pipe),
6262 (write_err_and_exit), (read_ints), (do_exec), (_dbus_spawn_async):
6263 * dbus/dbus-sysdeps.h:
6264 Add _dbus_spawn_async.
6266 * test/spawn-test.c: (main):
6267 Test for _dbus_spawn_async.
6269 2003-02-15 Anders Carlsson <andersca@codefactory.se>
6271 * dbus/dbus-internals.h:
6272 Fix build without tests.
6274 * dbus/dbus-list.c: (alloc_link):
6275 Fix a segfault when a malloc fails.
6277 * dbus/dbus-memory.c: (initialize_malloc_debug), (dbus_malloc),
6278 (dbus_malloc0), (dbus_realloc):
6279 Add support for malloc debugging.
6281 2003-02-15 Alexander Larsson <alexl@redhat.com>
6283 * dbus/dbus-threads.c:
6284 * dbus/dbus-threads.h:
6285 Add condvars. Remove static mutext from API.
6286 Implement static mutexes by initializing them from threads_init.
6288 * glib/dbus-gthread.c:
6289 * qt/dbus-qthread.cpp:
6290 Update with the thread api changes.
6295 Turn StaticMutex into normal mutex + init function.
6296 Export new functions _dbus_list_alloc_link, _dbus_list_free_link,
6297 _dbus_list_append_link, _dbus_list_prepend_link
6300 * dbus/dbus-sysdeps.c:
6301 * dbus/dbus-sysdeps.h:
6302 New type dbus_atomic_t, and new functions _dbus_atomic_inc,
6303 _dbus_atomic_dec. Only slow fallback implementation at the moment.
6305 * dbus/dbus-protocol.h:
6306 Add DBUS_MESSAGE_LOCAL_DISCONNECT define
6308 * dbus/dbus-message.c:
6309 Make ref/unref atomic.
6312 * dbus/dbus-connection-internal.h:
6313 * dbus/dbus-connection.c:
6314 * dbus/dbus-connection.h:
6316 Change _peek to _borrow,_return & _steal_borrowed.
6317 Change disconnect callback to event.
6318 Make dbus_connection_dispatch_messages reentrant.
6320 * dbus/dbus-transport.c:
6321 Don't ref the connection on calls to the transport
6324 * dbus/dbus-message-handler.c:
6327 * glib/dbus-gmain.c:
6328 Don't use peek_message anymore
6331 * test/debug-thread.c:
6332 * test/debug-thread.h:
6333 Simple thread implementation that asserts() on deadlocks in
6334 single-threaded code.
6337 (main) Call debug_threads_init.
6340 Use disconnect message instead of disconnect callback.
6344 Don't call dbus_connection_set_disconnect_function. Instead export
6345 bus_connection_disconnect.
6348 Call bus_connection_disconnect when we get a disconnected message.
6350 2003-02-15 Havoc Pennington <hp@pobox.com>
6352 * dbus/dbus-message.c (dbus_message_new): fool around with the
6355 2003-02-14 Havoc Pennington <hp@pobox.com>
6357 * dbus/dbus-mempool.c: fail if the debug functions so indicate
6359 * dbus/dbus-memory.c: fail if the debug functions indicate we
6362 * dbus/dbus-internals.c (_dbus_set_fail_alloc_counter)
6363 (_dbus_decrement_fail_alloc_counter): debug functions to
6364 simulate memory allocation failures
6366 2003-02-14 Havoc Pennington <hp@pobox.com>
6368 * dbus/dbus-errors.h (struct DBusError): add a word of padding
6371 2003-02-13 Anders Carlsson <andersca@codefactory.se>
6373 * bus/driver.c: (bus_driver_handle_hello):
6375 * bus/services.c: (bus_service_lookup):
6376 Reorder message sending so we get a more sane order.
6378 * test/bus-test.c: (message_handler):
6381 2003-02-13 Anders Carlsson <andersca@codefactory.se>
6383 * bus/driver.c: (bus_driver_send_service_deleted),
6384 (bus_driver_send_service_created), (bus_driver_send_service_lost),
6385 (bus_driver_send_service_acquired), (bus_driver_handle_hello),
6386 (bus_driver_send_welcome_message),
6387 (bus_driver_handle_list_services),
6388 (bus_driver_handle_acquire_service),
6389 (bus_driver_handle_service_exists):
6390 * dbus/dbus-bus.c: (dbus_bus_register_client),
6391 (dbus_bus_acquire_service), (dbus_bus_service_exists):
6392 * dbus/dbus-errors.c: (dbus_result_to_string):
6393 * dbus/dbus-errors.h:
6394 * dbus/dbus-message.c: (dbus_message_append_args),
6395 (dbus_message_append_args_valist), (dbus_message_get_args),
6396 (dbus_message_get_args_valist), (dbus_message_get_args_iter),
6397 (dbus_message_iter_get_arg_type), (dbus_message_iter_get_string),
6398 (dbus_message_iter_get_byte_array),
6399 (dbus_message_iter_get_string_array), (message_iter_test),
6400 (check_message_handling), (_dbus_message_test):
6401 * dbus/dbus-message.h:
6402 * test/bus-test.c: (main):
6403 Change fields to arguments in messages, so that they won't be
6404 confused with header fields.
6406 * glib/test-dbus-glib.c: (main):
6407 Remove append_fields from hello message.
6409 2003-02-13 Anders Carlsson <andersca@codefactory.se>
6411 * dbus/dbus-errors.c:
6412 * dbus/dbus-message.c:
6413 * dbus/dbus-string.c:
6414 Documentation fixes.
6416 2003-02-13 Anders Carlsson <andersca@codefactory.se>
6418 * glib/dbus-gmain.c: (timeout_handler), (add_timeout),
6420 Implement support for timeouts in dbus-glib.
6422 2003-02-13 Anders Carlsson <andersca@codefactory.se>
6424 * dbus/dbus-message-builder.c: (_dbus_message_data_load):
6425 * dbus/dbus-message.c: (process_test_subdir):
6426 * test/break-loader.c: (find_breaks_based_on):
6427 Plug some memory leaks.
6429 2003-02-13 Richard Hult <rhult@codefactory.se>
6431 * bus/main.c: Fix build.
6433 * dbus/dbus-errors.h:
6434 * dbus/dbus-errors.c: Fix copyright for Anders.
6436 2003-02-13 Anders Carlsson <andersca@codefactory.se>
6441 * bus/connection.c: (bus_connection_foreach):
6444 * bus/desktop-file.c: (grow_lines_in_section), (grow_sections),
6445 (unescape_string), (new_section), (parse_section_start),
6446 (parse_key_value), (report_error), (bus_desktop_file_load),
6447 (bus_desktop_file_get_string):
6448 * bus/desktop-file.h:
6449 Use DBusError for error reporting.
6451 * bus/dispatch.c: (send_one_message),
6452 (bus_dispatch_message_handler):
6453 * bus/driver.c: (bus_driver_send_service_deleted),
6454 (bus_driver_send_service_created), (bus_driver_send_service_lost),
6455 (bus_driver_send_service_acquired), (bus_driver_handle_hello),
6456 (bus_driver_send_welcome_message),
6457 (bus_driver_handle_list_services),
6458 (bus_driver_handle_acquire_service),
6459 (bus_driver_handle_service_exists):
6460 * bus/loop.c: (bus_loop_run):
6462 Use BUS_HANDLE_OOM instead of _DBUS_HANDLE_OOM.
6464 * bus/utils.c: (bus_wait_for_memory):
6466 New files with general utility functions.
6468 * dbus/dbus-internals.h:
6469 Remove _DBUS_HANDLE_OOM.
6471 2003-02-13 Anders Carlsson <andersca@codefactory.se>
6473 * dbus/dbus-errors.c: (dbus_result_to_string), (dbus_error_init),
6474 (dbus_error_free), (dbus_set_error_const), (dbus_set_error):
6475 * dbus/dbus-errors.h:
6476 Add DBusError structure.
6478 2003-02-13 Anders Carlsson <andersca@codefactory.se>
6480 * test/data/valid-messages/standard-acquire-service.message:
6481 * test/data/valid-messages/standard-hello.message:
6482 * test/data/valid-messages/standard-list-services.message:
6483 * test/data/valid-messages/standard-service-exists.message:
6484 Add some standard messages.
6486 2003-02-13 Anders Carlsson <andersca@codefactory.se>
6488 * bus/driver.c: (bus_driver_send_welcome_message),
6489 (bus_driver_handle_list_services),
6490 (bus_driver_handle_acquire_service),
6491 (bus_driver_handle_service_exists), (bus_driver_handle_message):
6492 Update for API changes in libdbus.
6494 * dbus/dbus-message.c: (dbus_message_new_reply):
6495 * dbus/dbus-message.h:
6496 Remove the name argument. The spec states that replies shouldn't
6499 2003-02-13 Anders Carlsson <andersca@codefactory.se>
6501 * bus/desktop-file.c: (parse_section_start), (parse_key_value),
6502 (report_error), (bus_desktop_file_load), (lookup_section),
6503 (lookup_line), (bus_desktop_file_get_raw),
6504 (bus_desktop_file_get_string):
6505 * bus/desktop-file.h:
6506 Some fixes, and new functions for getting a key value from a section.
6508 2003-02-13 Havoc Pennington <hp@pobox.com>
6510 * test/data/auth/fail-after-n-attempts.auth-script: new test
6512 * dbus/dbus-auth.c (send_rejected): shutdown_mech() when we
6515 2003-02-13 Havoc Pennington <hp@pobox.com>
6517 * dbus/dbus-auth.c (handle_server_data_external_mech): args to
6518 dbus_credentials_match were backward
6520 * dbus/dbus-auth-script.c (_dbus_auth_script_run): support
6521 NO_CREDENTIALS and ROOT_CREDENTIALS
6523 * dbus/dbus-auth.c (_dbus_auth_do_work): move get_state() routine
6524 into here. Never process more commands after we've reached an
6525 end state; store further data as unused bytes.
6527 * test/data/auth/*: add more auth tests
6529 * dbus/dbus-auth-script.c (_dbus_auth_script_run): support EXPECT
6530 command to match exact string and EXPECT_UNUSED to match unused
6533 * test/Makefile.am (dist-hook): fix to dist all the test stuff
6535 2003-02-12 Havoc Pennington <hp@pobox.com>
6537 * dbus/dbus-string.c (_dbus_string_pop_line): fix to also strip
6538 \r off of popped lines
6540 * dbus/dbus-auth.c (_dbus_auth_test): write code to run auth
6543 * dbus/dbus-auth-script.c (_dbus_auth_script_run): when doing a
6546 2003-02-12 Havoc Pennington <hp@pobox.com>
6548 * dbus/Makefile.am: remove break-loader from the build, since it
6551 * configure.in: add --enable-gcov to turn on coverage profiling
6552 flags and disable optimization
6554 2003-02-10 Havoc Pennington <hp@pobox.com>
6556 * dbus/dbus-auth-script.c, dbus/dbus-auth-script.h: sync
6557 initial cut at test framework for DBusAuth from laptop.
6558 Doesn't quite work yet but it compiles and I need to get
6559 it off the 266mhz laptop. ;-)
6561 * dbus/dbus-server-debug.c (_dbus_server_debug_accept_transport):
6562 fix a memleak in error case
6564 2003-02-12 Anders Carlsson <andersca@codefactory.se>
6567 * bus/desktop-file.c:
6568 * bus/desktop-file.h:
6569 Add a desktop file parser.
6571 2003-02-11 Zack Rusin <zack@kde.org>
6573 * qt/message.[h|cpp]: sample implementation
6574 of the KDE wrapper for DBusMessage
6576 2003-02-09 Zack Rusin <zack@kde.org>
6578 * test/bus-test.c: make_it_compile
6579 * doc/dbus-specification.sgml: minimal semantic fix
6581 2003-02-06 Anders Carlsson <andersca@codefactory.se>
6587 2003-02-06 Anders Carlsson <andersca@codefactory.se>
6590 * dbus/dbus-break-loader.c:
6592 * test/break-loader.c:
6593 Move dbus-break-loader to test/ and rename it to break-loader.
6595 2003-02-02 Havoc Pennington <hp@pobox.com>
6597 * dbus/dbus-keyring.c, dbus/dbus-keyring.h: template files
6598 for code to manage cookies in your home directory
6600 * dbus/dbus-sysdeps.c (_dbus_generate_random_bytes): new function
6602 * dbus/dbus-auth.c (get_state): impose a maximum number of tries
6603 to authenticate, then disconnect the client.
6605 2003-02-03 Alexander Larsson <alexl@redhat.com>
6607 * dbus/dbus-message.c (dbus_message_append_fields):
6610 2003-02-02 Anders Carlsson <andersca@codefactory.se>
6612 * doc/dbus-specification.sgml:
6613 Update address format section.
6615 2003-02-02 Anders Carlsson <andersca@codefactory.se>
6618 * test/bus-test.c: (get_time), (add_timeout), (remove_timeout),
6619 (message_handler), (new_connection_callback), (loop_quit),
6623 2003-02-02 Anders Carlsson <andersca@codefactory.se>
6625 * bus/driver.c: (bus_driver_handle_service_exists):
6626 Simplify the code a bit.
6628 * dbus/dbus-bus.c: (dbus_bus_service_exists):
6631 2003-02-02 Anders Carlsson <andersca@codefactory.se>
6634 Add libdbus-daemon.la and link to it.
6636 2003-02-01 James Willcox <jwillcox@gnome.org>
6638 * bus/driver.c: (bus_driver_handle_own_service):
6639 Actually include the service reply code in the message.
6641 2003-02-02 Anders Carlsson <andersca@codefactory.se>
6643 * bus/driver.c: (bus_driver_handle_service_exists):
6644 Don't unref the incoming message.
6646 2003-02-02 Anders Carlsson <andersca@codefactory.se>
6648 * dbus/dbus.h: Add dbus-address.h and dbus-bus.h
6650 2003-02-02 Anders Carlsson <andersca@codefactory.se>
6652 * dbus/dbus-server.c: (dbus_server_listen):
6653 * dbus/dbus-transport.c: (_dbus_transport_open):
6654 ifdef out the calls to the debug transport and server.
6656 2003-02-02 Alexander Larsson <alexl@redhat.com>
6658 * dbus/dbus-watch.c (dbus_watch_get_flags):
6659 Add note in the docs that ERROR or HANGUP won't be returned
6660 and are assumed always on.
6662 * glib/dbus-gmain.c (add_watch):
6663 Always add IO_ERR | IO_HUP
6665 * dbus/dbus-message.h:
6666 Add semicolon after dbus_message_iter_get_string_array().
6667 Makes qt code build again
6669 2003-02-01 Anders Carlsson <andersca@codefactory.se>
6671 * bus/driver.c: (create_unique_client_name),
6672 (bus_driver_handle_hello):
6673 Don't take a name, just use a numeric id to identify
6677 * dbus/dbus-bus.c: (dbus_bus_register_client),
6678 (dbus_bus_acquire_service), (dbus_bus_service_exists):
6680 Add new convenience functions for communicating with the bus.
6682 * dbus/dbus-message.h:
6684 * dbus/dbus-protocol.h:
6687 2003-02-01 Alexander Larsson <alexl@redhat.com>
6689 * dbus/dbus-message.c (dbus_message_append_fields):
6690 Add some more doc comments.
6692 2003-02-01 Havoc Pennington <hp@pobox.com>
6694 * dbus/dbus-break-loader.c (randomly_modify_length): change
6695 a 4-byte value in the message as if it were a length
6697 * dbus/dbus-sysdeps.c (_dbus_string_save_to_file): don't set
6698 execute bit on saved files
6700 2003-02-01 Havoc Pennington <hp@pobox.com>
6702 * dbus/dbus-break-loader.c (main): new program to find messages
6703 that break the loader.
6705 * dbus/dbus-sysdeps.c (_dbus_string_append_uint): new function
6706 * dbus/dbus-sysdeps.c (_dbus_string_save_to_file): new function
6708 * dbus/dbus-string.c (_dbus_string_set_byte): new
6710 2003-01-31 Havoc Pennington <hp@pobox.com>
6712 * dbus/dbus-message.c: refactor the test code to be more general,
6713 in preparation for writing a "randomly permute test cases to
6714 try to break the loader" program.
6716 2003-01-31 Havoc Pennington <hp@pobox.com>
6718 * doc/dbus-specification.sgml: work on the specification
6720 * dbus/dbus-message.c (_dbus_message_loader_return_buffer): check
6721 the protocol version of the message.
6723 * dbus/dbus-protocol.h: drop special _REPLY names, the spec
6724 no longer specifies that.
6725 (DBUS_SERVICE_REPLY_SERVICE_EXISTS): fix flags (1/2/4/8 not
6728 * dbus/dbus-marshal.c (_dbus_marshal_get_arg_end_pos): add missing
6729 "break" for DBUS_TYPE_NIL, remove @todo
6731 2003-01-31 Havoc Pennington <hp@pobox.com>
6733 * dbus/dbus-message.c (dbus_message_set_is_error_reply): rename
6734 just set_is_error/get_is_error as this is a commonly-used
6735 function, and write docs.
6737 2003-01-31 Anders Carlsson <andersca@codefactory.se>
6739 * dbus/dbus-address.c: (dbus_address_entry_free):
6740 Free key and value lists.
6742 * dbus/dbus-internals.c: (_dbus_type_to_string):
6743 Add the types we didn't have.
6745 * dbus/dbus-marshal.c: (_dbus_marshal_get_arg_end_pos),
6746 (_dbus_marshal_validate_arg):
6749 * dbus/dbus-message.c: (dbus_message_set_sender):
6750 Remove todo about being able to set sender to NULL.
6752 (dbus_message_set_is_error_reply),
6753 (dbus_message_get_is_error_reply):
6754 * dbus/dbus-message.h:
6757 * dbus/dbus-protocol.h:
6758 Add error reply flag.
6760 * test/data/valid-messages/opposite-endian.message:
6761 Add NIL type to test.
6763 2003-01-31 Havoc Pennington <hp@pobox.com>
6765 * doc/dbus-specification.sgml: fully specify the header. Add
6766 flags and major protocol version, and change header/body len to
6769 * dbus/dbus-message-builder.c (append_saved_length): append length
6772 * dbus/dbus-message.c (dbus_message_create_header): change header
6773 length and body length to unsigned. Add the new fields from the
6775 (_dbus_message_loader_return_buffer): unsigned header/body len
6777 2003-01-30 Havoc Pennington <hp@pobox.com>
6779 * dbus/dbus-auth.c: rework to use only REJECTED, no
6782 * doc/dbus-sasl-profile.txt: drop MECHANISMS and just
6783 use REJECTED, suggested by Mark McLoughlin
6785 2003-01-30 Havoc Pennington <hp@pobox.com>
6787 * dbus/dbus-server.c (dbus_server_listen): @todo about how we need
6788 a better way to report errors here. e.g. "unix address lacks
6789 path" or something. also "no such file" when the path doesn't
6792 * dbus/dbus-address.c (dbus_address_entries_free): add @todo about
6794 (dbus_parse_address): add @todo about documenting address format,
6795 and allowing , and ; to be escaped
6797 2003-01-30 Anders Carlsson <andersca@codefactory.se>
6800 Add dbus-address.[ch]
6802 * dbus/dbus-address.c: (dbus_address_entry_free),
6803 (dbus_address_entries_free), (create_entry),
6804 (dbus_address_entry_get_method), (dbus_address_entry_get_value),
6805 (dbus_parse_address), (_dbus_address_test):
6806 * dbus/dbus-address.h:
6807 New files for dealing with address parsing.
6809 * dbus/dbus-connection.c:
6810 Document timeout functions.
6812 * dbus/dbus-message.c:
6813 Document dbus_message_new_from_message.
6815 * dbus/dbus-server-debug.c:
6818 * dbus/dbus-server.c: (dbus_server_listen):
6819 Parse address and use correct server implementation.
6821 * dbus/dbus-string.c: (_dbus_string_find_to), (_dbus_string_test):
6822 * dbus/dbus-string.h:
6823 New function with test.
6825 * dbus/dbus-test.c: (dbus_internal_symbol_do_not_use_run_tests):
6829 * dbus/dbus-transport-debug.c:
6832 * dbus/dbus-transport.c: (_dbus_transport_open):
6833 Parse address and use correct transport implementation.
6835 2003-01-30 Havoc Pennington <hp@pobox.com>
6837 * dbus/dbus-message.c: use message->byte_order instead of
6838 DBUS_COMPILER_BYTE_ORDER throughout.
6839 (dbus_message_create_header): pad header to align the
6840 start of the body of the message to 8-byte boundary
6842 * dbus/dbus-marshal.h: make all the demarshalers take const
6843 DBusString arguments.
6845 * dbus/dbus-message.c (_dbus_message_loader_return_buffer):
6846 validate message args here, so we don't have to do slow validation
6847 later, and so we catch bad messages as they are incoming. Also add
6848 better checks on header_len and body_len. Also fill in
6851 * dbus/dbus-string.c (_dbus_string_validate_utf8): new (not
6852 implemented properly)
6853 (_dbus_string_validate_nul): new function to check all-nul
6855 * dbus/dbus-marshal.c (_dbus_marshal_get_field_end_pos): rename
6856 get_arg_end_pos and remove all validation
6857 (_dbus_marshal_validate_arg): actually do validation here.
6859 2003-01-29 Havoc Pennington <hp@pobox.com>
6861 * dbus/dbus-message.c (check_message_handling): fix assertion
6862 failure on set_client_serial
6864 2003-01-28 Havoc Pennington <hp@pobox.com>
6866 * dbus/dbus-server-debug.c: Add doc section comments
6868 * dbus/dbus-transport-debug.c: add doc section comments
6870 2003-01-28 Havoc Pennington <hp@redhat.com>
6872 * dbus/dbus-string.c (_dbus_string_base64_decode): append bytes in
6873 the reverse order from how I had it
6874 (_dbus_string_base64_encode): reverse encoding order. I was
6875 basically byteswapping everything during encoding.
6877 2003-01-28 Anders Carlsson <andersca@codefactory.se>
6879 * dbus/dbus-connection-internal.h:
6880 * dbus/dbus-connection.c: (_dbus_connection_add_timeout),
6881 (_dbus_connection_remove_timeout):
6882 Add functions for adding and removing timeouts.
6884 * dbus/dbus-message.c: (dbus_message_new_from_message):
6885 Add new function that takes a message and creates an exact
6886 copy of it, but with the refcount set to 1.
6887 (check_message_handling):
6890 * dbus/dbus-server-protected.h:
6891 * dbus/dbus-server.c: (_dbus_server_init_base),
6892 (_dbus_server_finalize_base), (_dbus_server_add_timeout),
6893 (dbus_server_set_timeout_functions):
6894 (_dbus_server_remove_timeout):
6895 New functions so that a server can add and remove timeouts.
6897 (dbus_server_listen):
6898 Add commented out call to dbus_server_debug_new.
6900 * dbus/dbus-timeout.c: (_dbus_timeout_new):
6901 Actually set the handler, doh.
6903 * dbus/dbus-transport.c: (_dbus_transport_open):
6904 Add commented out call to dbus_transport_debug_client_new.
6907 Add dbus-transport-debug.[ch] and dbus-server-debug.[ch]
6909 2003-01-28 Havoc Pennington <hp@pobox.com>
6911 * dbus/dbus-message.c (check_message_handling): function to check
6912 on the loaded message, iterates over it etc.
6914 2003-01-28 Havoc Pennington <hp@pobox.com>
6916 * test/Makefile.am (dist-hook): fix make distdir
6918 * dbus/Makefile.am (TESTS_ENVIRONMENT): fix make check
6920 2003-01-27 Havoc Pennington <hp@pobox.com>
6922 * dbus/dbus-mempool.c (time_for_size): replace printf with
6925 * dbus/dbus-message-builder.c (_dbus_message_data_load): allow
6926 empty lines; fix the SAVE_LENGTH stuff to be
6927 START_LENGTH/END_LENGTH so it actually works; couple other
6930 * test/Makefile.am (dist-hook): add dist-hook for .message files
6932 * dbus/dbus-string.c (DBUS_STRING_COPY_PREAMBLE): source of a copy
6933 can be constant or locked.
6934 (_dbus_string_free): allow freeing a const string as
6937 * dbus/dbus-sysdeps.c (_dbus_concat_dir_and_file): utility
6939 * dbus/dbus-test-main.c (main): take an argument which is the
6940 directory containing test data
6942 * dbus/dbus-message.c (_dbus_message_test): pass a test_data_dir
6943 argument to this and load all the messages in test/data/
6944 checking that they can be loaded or not loaded as appropriate.
6946 2003-01-27 Anders Carlsson <andersca@codefactory.se>
6948 * bus/dispatch.c: (bus_dispatch_message_handler):
6949 Dispatch messages sent to services.
6951 * bus/driver.c: (bus_driver_send_service_deleted),
6952 (bus_driver_send_service_created), (bus_driver_send_service_lost),
6953 (bus_driver_send_service_acquired):
6954 Add helper functions for sending service related messages.
6956 (bus_driver_send_welcome_message):
6957 Send HELLO_REPLY instead of WELCOME.
6959 (bus_driver_handle_list_services):
6960 Send LIST_SERVICES_REPLY instead of SERVICES.
6962 (bus_driver_handle_own_service),
6963 (bus_driver_handle_service_exists):
6964 New message handlers.
6966 (bus_driver_handle_message):
6967 Invoke new message handlers.
6969 (bus_driver_remove_connection):
6970 Don't remove any services here since that's done automatically
6971 by bus_service_remove_owner now.
6974 New function signatures.
6976 * bus/services.c: (bus_service_add_owner):
6977 Send ServiceAcquired message if we're the only primary owner.
6979 (bus_service_remove_owner):
6980 Send ServiceAcquired/ServiceLost messages.
6982 (bus_service_set_prohibit_replacement),
6983 (bus_service_get_prohibit_replacement):
6984 Functions for setting prohibit replacement.
6986 (bus_service_has_owner):
6987 New function that checks if a connection is in the owner queue of
6991 Add new function signatures.
6993 * dbus/dbus-list.c: (_dbus_list_test):
6994 Add tests for _dbus_list_remove_last and traversing the list backwards.
6997 Fix a typo in _dbus_list_get_prev_link, if we're at the first element we can't
6998 go any further, so return NULL then.
7000 * dbus/dbus-protocol.h:
7001 Add new messages, service flags and service replies.
7003 2003-01-26 Havoc Pennington <hp@pobox.com>
7005 * dbus/dbus-message-builder.c: implement, completely untested.
7007 * test/data/*: add data to be used in testing.
7008 ".message" files are our simple loadable text format.
7009 ".message-raw" will be binary dumps of messages.
7011 * dbus/dbus-string.c (_dbus_string_starts_with_c_str): new
7013 2003-01-26 Havoc Pennington <hp@pobox.com>
7015 * dbus/dbus-sysdeps.c (_dbus_file_get_contents): new function
7017 * dbus/dbus-errors.c (dbus_result_to_string): add
7020 * dbus/dbus-message-builder.c: new file, will contain code to load
7021 up messages from files. Not implemented yet.
7023 2003-01-26 Havoc Pennington <hp@pobox.com>
7025 * dbus/dbus-message.c (dbus_message_set_sender): support deleting
7026 the sender by setting to NULL
7028 2003-01-26 Havoc Pennington <hp@pobox.com>
7030 The unit tests pass, but otherwise untested. If it breaks, the
7031 tests should have been better. ;-)
7033 * bus/driver.c (bus_driver_handle_hello): return if we disconnect
7036 * dbus/dbus-message.c: redo everything so we maintain
7037 message->header as the only copy of the various fields.
7038 This avoids the possibility of out-of-memory in some cases,
7039 for example dbus_message_lock() can't run out of memory anymore,
7040 and avoids extra copying. Figured I may as well go ahead and do
7041 this since it was busted for dbus_message_lock to not return
7042 failure on OOM, and dbus_message_write_header was totally
7043 unchecked for OOM. Also fixed some random other bugs.
7045 * dbus/dbus-marshal.c (_dbus_marshal_get_field_end_pos): verify
7046 that strings are nul-terminated. Also, end_pos can be equal
7047 to string length just not greater than, I think.
7048 (_dbus_marshal_set_int32): new function
7049 (_dbus_marshal_set_uint32): new function
7050 (_dbus_marshal_set_string): new function
7052 * dbus/dbus-connection.c (_dbus_connection_new_for_transport): fix
7053 a warning, init timeout_list to NULL
7054 (dbus_connection_send_message): don't use uninitialized variable
7057 * dbus/dbus-string.c (_dbus_string_replace_len): new function
7059 2003-01-26 Anders Carlsson <andersca@codefactory.se>
7061 * bus/driver.c: (bus_driver_handle_hello),
7062 (bus_driver_send_welcome_message):
7065 2003-01-26 Anders Carlsson <andersca@codefactory.se>
7067 * dbus/dbus-auth.c: (process_auth), (_dbus_auth_unref):
7068 * dbus/dbus-connection.c: (_dbus_connection_new_for_transport),
7069 (dbus_connection_unref):
7070 * dbus/dbus-marshal.c: (_dbus_marshal_test):
7071 * dbus/dbus-message.c: (dbus_message_unref),
7074 (dbus_message_get_fields):
7075 Remove debugging printout.
7077 (_dbus_message_loader_return_buffer):
7078 Don't store the header string.
7080 (_dbus_message_test):
7083 2003-01-26 Richard Hult <rhult@codefactory.se>
7085 * glib/dbus-gmain.c (dbus_connection_dispatch): Traverse a copy of
7086 the file descriptor list, since it can change under us.
7088 2003-01-25 Anders Carlsson <andersca@codefactory.se>
7090 * glib/dbus-gmain.c: (dbus_connection_prepare),
7091 (dbus_connection_check), (dbus_connection_dispatch), (add_watch),
7092 (remove_watch), (dbus_connection_hookup_with_g_main):
7093 Rewrite the glib handling to use its own GSource instead of a
7094 GIOChannel so we can catch messages put in the queue while waiting
7097 2003-01-25 Anders Carlsson <andersca@codefactory.se>
7100 * bus/connection.c: (connection_disconnect_handler),
7101 (connection_watch_callback), (bus_connection_setup):
7102 * bus/dispatch.c: (send_one_message),
7103 (bus_dispatch_broadcast_message), (bus_dispatch_message_handler),
7104 (bus_dispatch_add_connection), (bus_dispatch_remove_connection):
7106 * bus/driver.c: (bus_driver_send_service_deleted),
7107 (bus_driver_send_service_created), (bus_driver_handle_hello),
7108 (bus_driver_send_welcome_message),
7109 (bus_driver_handle_list_services), (bus_driver_remove_connection),
7110 (bus_driver_handle_message):
7112 Refactor code, put the message dispatching in its own file. Use
7113 _DBUS_HANDLE_OOM. Also send ServiceDeleted messages when a client
7116 2003-01-25 Anders Carlsson <andersca@codefactory.se>
7118 * dbus/dbus-internals.h:
7119 Add _DBUS_HANDLE_OOM macro, it doesn't do anything currently.
7121 * dbus/dbus-message.c: (dbus_message_get_sender):
7122 * dbus/dbus-message.h:
7123 Implement dbus_message_get_sender.
7125 * dbus/dbus-protocol.h:
7126 Add message and service defines.
7128 2003-01-25 Anders Carlsson <andersca@codefactory.se>
7130 * dbus/dbus-connection.c: (dbus_connection_send_message):
7131 * dbus/dbus-message-internal.h:
7132 * dbus/dbus-message.c: (_dbus_message_get_client_serial),
7133 (dbus_message_write_header):
7134 Remove _dbus_messag_unlock and don't set the client serial on a
7135 message if one already exists.
7137 2003-01-24 Havoc Pennington <hp@pobox.com>
7139 * dbus/dbus-list.c (alloc_link): put a thread lock on the global
7142 * bus/driver.c (bus_driver_handle_list_services): fix a leak
7145 2003-01-25 Anders Carlsson <andersca@codefactory.se>
7147 * dbus/dbus-list.c: (alloc_link), (free_link):
7148 Use a memory pool for the links.
7150 2003-01-25 Anders Carlsson <andersca@codefactory.se>
7152 * bus/connection.c: (bus_connection_foreach):
7154 Add new bus_connection_foreach function.
7156 * bus/driver.c: (send_one_message), (bus_driver_broadcast_message):
7157 Add function that broadcasts a message to all clients.
7159 (bus_driver_send_service_created), (bus_driver_handle_hello),
7160 (bus_driver_send_welcome_message),
7161 (bus_driver_handle_list_services), (bus_driver_message_handler):
7162 Implement functions that take care of listing services, and notifying
7163 clients when new services are created.
7165 * bus/services.c: (bus_services_list):
7167 Add new function that returns an array of strings with the currently
7168 registered services.
7171 * glib/dbus-gmain.c:
7172 Update copyright year.
7174 2003-01-25 Anders Carlsson <andersca@codefactory.se>
7176 * dbus/dbus-connection.c: (dbus_connection_send_message):
7177 Unlock the message in case it was sent earlier.
7179 (dbus_connection_send_message_with_reply_and_block):
7180 Remove the reply message from the list.
7182 * dbus/dbus-marshal.c: (_dbus_demarshal_string_array):
7183 Set array_len and new_pos correctly.
7185 (_dbus_marshal_test):
7186 Remove debug output.
7188 * dbus/dbus-message-internal.h:
7189 * dbus/dbus-message.c: (_dbus_message_get_reply_serial):
7190 New function that returns the reply serial.
7192 (_dbus_message_unlock):
7193 New function that unlocks a message and resets its header.
7195 (dbus_message_append_string_array),
7196 (dbus_message_get_fields_valist),
7197 (dbus_message_iter_get_field_type),
7198 (dbus_message_iter_get_string_array),
7199 (dbus_message_get_fields),
7200 (dbus_message_append_fields_valist):
7201 Handle string arrays.
7203 (dbus_message_set_sender):
7204 Make this function public since the bus daemon needs it.
7206 (decode_header_data):
7207 Set the reply serial to -1 initially.
7209 * dbus/dbus-message.h:
7210 Add dbus_message_set_sender.
7212 2003-01-24 Havoc Pennington <hp@pobox.com>
7214 * doc/dbus-specification.sgml: add some stuff
7216 2003-01-22 Havoc Pennington <hp@pobox.com>
7218 * doc/dbus-specification.sgml: Start to document the protocol.
7220 2003-01-22 Havoc Pennington <hp@pobox.com>
7222 * dbus/dbus-connection.c
7223 (dbus_connection_send_message_with_reply_and_block): add some @todo
7225 * bus/driver.c (bus_driver_add_connection): add a FIXME about memleak
7227 2003-01-21 Havoc Pennington <hp@pobox.com>
7229 (patch untested because can't compile)
7231 * bus/driver.c (create_unique_client_name): make this function
7232 never recycle client names. Also, caller should initialize
7235 * dbus/dbus-sysdeps.c (_dbus_get_current_time): new function
7237 2003-01-21 Anders Carlsson <andersca@codefactory.se>
7239 * dbus/dbus-marshal.c: (_dbus_marshal_double),
7240 (_dbus_marshal_int32), (_dbus_marshal_uint32),
7241 (_dbus_marshal_int32_array), (_dbus_marshal_uint32_array),
7242 (_dbus_marshal_double_array), (_dbus_marshal_string_array),
7243 (_dbus_demarshal_int32_array), (_dbus_demarshal_uint32_array),
7244 (_dbus_demarshal_double_array), (_dbus_demarshal_string_array),
7245 (_dbus_marshal_get_field_end_pos), (_dbus_marshal_test):
7246 * dbus/dbus-marshal.h:
7247 * dbus/dbus-protocol.h:
7248 Add support for marshalling and demarshalling integer, double
7251 2003-01-21 Anders Carlsson <andersca@codefactory.se>
7256 * bus/connection.c: (connection_disconnect_handler):
7257 Remove the connection from the bus driver's list.
7259 (connection_watch_callback): Dispatch messages.
7261 (free_connection_data): Free connection name.
7263 (bus_connection_setup): Add connection to the bus driver's list.
7264 (bus_connection_remove_owned_service):
7265 (bus_connection_set_name), (bus_connection_get_name):
7266 Add functions for setting and getting the connection's name.
7269 Add function headers.
7271 * bus/driver.c: (create_unique_client_name),
7272 (bus_driver_handle_hello_message),
7273 (bus_driver_send_welcome_message), (bus_driver_message_handler),
7274 (bus_driver_add_connection), (bus_driver_remove_connection):
7277 * bus/services.c: (bus_service_free):
7279 New file that handles communication and registreation with the bus
7282 2003-01-21 Anders Carlsson <andersca@codefactory.se>
7284 * dbus/dbus-connection.c: (dbus_connection_send_message):
7285 Add a new client_serial parameter.
7287 (dbus_connection_send_message_with_reply):
7288 Remove a @todo since we've implemented the blocking function.
7290 (dbus_connection_send_message_with_reply_and_block):
7291 New function that sends a message and waits for a reply and
7292 then returns the reply.
7294 * dbus/dbus-connection.h:
7297 * dbus/dbus-errors.c: (dbus_result_to_string):
7298 * dbus/dbus-errors.h:
7299 Add new DBUS_RESULT.
7301 * dbus/dbus-message-internal.h:
7302 * dbus/dbus-message.c: (_dbus_message_get_reply_serial),
7303 (_dbus_message_set_sender), (dbus_message_write_header),
7304 (dbus_message_new_reply), (decode_header_data),
7305 (_dbus_message_loader_return_buffer), (_dbus_message_test):
7306 * dbus/dbus-message.h:
7307 Add new functions that set the reply serial and sender.
7308 Also marshal and demarshal them correctly and add test.
7310 * dbus/dbus-protocol.h:
7311 Add new DBUS_MESSAGE_TYPE_SENDER.
7314 * glib/dbus-gmain.c: (watch_callback), (free_callback_data),
7315 (add_watch), (remove_watch), (add_timeout), (remove_timeout),
7316 (dbus_connection_hookup_with_g_main):
7317 * glib/test-dbus-glib.c: (main):
7318 Rewrite to use GIOChannel and remove the GSource crack.
7320 * test/echo-client.c: (main):
7321 * test/watch.c: (check_messages):
7322 Update for changed APIs
7324 2003-01-19 Anders Carlsson <andersca@codefactory.se>
7326 * dbus/Makefile.am: Add dbus-timeout.[cħ]
7328 * dbus/dbus-connection.c: (_dbus_connection_new_for_transport):
7329 Create a DBusTimeoutList.
7330 (dbus_connection_set_timeout_functions): Add new function to
7331 set timeout callbacks
7333 * dbus/dbus-connection.h: Add public DBusTimeout API.
7335 * dbus/dbus-message.c: (dbus_message_get_service):
7336 * dbus/dbus-message.h: New function.
7338 * dbus/dbus-server.c: Fix small doc typo.
7340 * dbus/dbus-timeout.[ch]: New files for mainloop timeouts.
7342 2003-01-19 Anders Carlsson <andersca@codefactory.se>
7344 * dbus/dbus-string.c (_dbus_string_move_len): Don't delete all
7345 of the string, just as long as specified.
7347 2003-01-19 Havoc Pennington <hp@pobox.com>
7349 * dbus/dbus-connection.c (dbus_connection_get_is_authenticated):
7352 * dbus/dbus-server.c (dbus_server_set_max_connections)
7353 (dbus_server_get_max_connections, dbus_server_get_n_connections):
7354 keep track of current number of connections, and add API for
7355 setting a max (but haven't implemented enforcing the max yet)
7357 2003-01-18 Havoc Pennington <hp@pobox.com>
7359 * dbus/dbus-transport-unix.c (unix_do_iteration): only do the
7360 reading/writing if read_watch != NULL or write_watch != NULL.
7362 * dbus/dbus-message.c (_dbus_message_loader_return_buffer): fix
7363 the message loader code to actually load message->header and
7364 message->body into the newly-created message.
7366 * dbus/dbus-transport-unix.c (check_write_watch): fix a mem leak
7369 * dbus/dbus-connection.c (dbus_connection_set_max_message_size)
7370 (dbus_connection_get_max_message_size)
7371 (dbus_connection_set_max_live_messages_size)
7372 (dbus_connection_get_max_live_messages_size): implement some
7373 resource limitation functions
7375 * dbus/dbus-resources.c: new file implementing some of the
7376 resource limits stuff
7378 * dbus/dbus-message.c (dbus_message_iter_get_byte_array): add
7379 missing docs, add @todo to handle OOM etc.
7381 * dbus/dbus-marshal.c (_dbus_demarshal_byte_array): add missing
7384 2003-01-18 Havoc Pennington <hp@pobox.com>
7386 * dbus/dbus-connection.c (dbus_connection_unref): disconnect the
7387 connection if it hasn't been already.
7389 * dbus/dbus-connection.h: kill off the idea of an ErrorFunction,
7390 replace with DisconnectFunction.
7392 2003-01-18 Havoc Pennington <hp@pobox.com>
7394 Building --disable-verbose-mode --disable-asserts --disable-tests
7395 cuts the library from 112K to 45K or so
7397 * configure.in: check for varargs macro support,
7398 add --enable-verbose-mode, --enable-asserts.
7400 * dbus/dbus-internals.h (_dbus_assert): support
7402 (_dbus_verbose): support DBUS_ENABLE_VERBOSE_MODE
7404 2003-01-18 Havoc Pennington <hp@pobox.com>
7406 * dbus/dbus-test.c: include config.h so that tests actually run
7408 * dbus/dbus-string.c: add assertions that stuff is 8-byte aligned,
7409 so the failure mode when that assumption fails will be plenty
7412 2003-01-18 Havoc Pennington <hp@pobox.com>
7414 * configure.in: default --enable-tests to $USE_MAINTAINER_MODE
7416 * dbus/Makefile.am: fix it up so dubs-test-main.c is included in
7419 * test/Makefile.am: don't use special variable "TESTS" for echo-*
7420 since we don't want to use those in make check
7422 2003-01-15 Havoc Pennington <hp@redhat.com>
7428 2003-01-15 Havoc Pennington <hp@redhat.com>
7430 * test/Makefile.am: fix so that test source code ends up in the
7431 distribution on make distcheck
7433 2003-01-15 Havoc Pennington <hp@redhat.com>
7439 2003-01-15 Havoc Pennington <hp@redhat.com>
7441 * dbus/dbus-test.c (dbus_internal_symbol_do_not_use_run_tests):
7442 fix build when --disable-tests
7444 * Makefile.am (EXTRA_DIST): put HACKING in here
7446 * HACKING: document procedure for making a tarball release.
7448 2003-01-14 Anders Carlsson <andersca@codefactory.se>
7450 * bus/connection.c: (connection_error_handler),
7451 (bus_connection_setup):
7452 * bus/main.c: (main):
7453 Make sure that the DBusConnectionData struct is NULLed
7454 out to prevent a segfault.
7456 * dbus/dbus-errors.c: (dbus_result_to_string):
7457 * dbus/dbus-errors.h:
7458 * dbus/dbus-message.c: (dbus_message_get_fields),
7459 (dbus_message_get_fields_valist), (_dbus_message_test):
7460 * dbus/dbus-message.h:
7461 Make dbus_message_get_fields return a result code so we can
7462 track invalid fields as well as oom.
7464 2003-01-11 Havoc Pennington <hp@pobox.com>
7466 * configure.in: change --enable-test/--enable-ansi action-if-given
7467 to enable_foo=$enableval instead of enable_foo=yes
7469 2003-01-08 Havoc Pennington <hp@pobox.com>
7471 * dbus/dbus-string.c (_dbus_string_align_length): new function
7473 * dbus/dbus-test-main.c: move main() for test app here
7475 (dbus_internal_symbol_do_not_use_run_tests): we have to export a
7476 symbol to run tests, because dbus-test isn't in the main
7479 Code review nitpicks.
7481 * dbus/dbus-message.c (dbus_message_write_header): add newlines
7482 for people with narrow emacs ;-). Assert client_serial was filled
7483 in. Assert message->name != NULL.
7484 (dbus_message_append_fields): have "first_field_type" arg separate
7485 from va list, needed for C++ binding that also uses varargs IIRC
7486 and helps with type safety
7487 (dbus_message_new): add @todo about using DBusString to store
7488 service/name internally
7489 (dbus_message_new): don't leak ->service and ->name on OOM later
7491 (dbus_message_unref): free the service name
7492 (dbus_message_get_fields): same change to varargs
7493 i.e. first_field_type
7494 (_dbus_message_loader_return_buffer): assert that the message data
7495 is aligned (if not it's a bug in our code). Put in verbose griping
7496 about why we set corrupted = TRUE.
7497 (decode_header_data): add FIXME that char* is evil. Was going to
7498 add FIXME about evil locale-specific string.h strncmp, but just
7499 switched to wacky string-as-uint32 optimization. Move check for
7500 "no room for field name" above get_const_data_len() to avoid
7501 assertion failure in get_const_data_len if we have trailing 2
7502 bytes or the like. Check for service and name fields being
7503 provided twice. Don't leak service/name on error. Require field
7504 names to be aligned to 4 bytes.
7506 * dbus/dbus-marshal.c: move byte swap stuff to header
7507 (_dbus_pack_int32): uscore-prefix
7508 (_dbus_unpack_int32): uscore-prefix
7509 (_dbus_unpack_uint32): export
7510 (_dbus_demarshal_string): add @todo complaining about use of
7512 (_dbus_marshal_get_field_end_pos): add @todo about bad error
7513 handling allowing corrupt data to go unchecked
7515 2003-01-08 Havoc Pennington <hp@redhat.com>
7517 * dbus/dbus-transport-unix.c (unix_do_iteration): add read/write
7518 to the select() as needed for authentication. (should be using
7519 _dbus_poll() not select, but for another day)
7521 * dbus/dbus.h: include dbus/dbus-protocol.h
7523 2003-01-08 Anders Carlsson <andersca@codefactory.se>
7525 * dbus/Makefile.am (dbusinclude_HEADERS): Install
7528 2003-01-08 Anders Carlsson <andersca@codefactory.se>
7530 * dbus/dbus-internals.c: (_dbus_type_to_string):
7531 New function that returns a string describing a type.
7533 * dbus/dbus-marshal.c: (_dbus_demarshal_byte_array):
7534 * dbus/dbus-marshal.h:
7535 * dbus/dbus-message.c: (dbus_message_get_fields_valist),
7536 (dbus_message_iter_get_field_type), (dbus_message_iter_get_double),
7537 (dbus_message_iter_get_byte_array):
7538 * dbus/dbus-message.h:
7539 Add new convenience functions for appending and getting message fields.
7540 Also add demarshalling routines for byte arrays.
7542 2003-01-07 Anders Carlsson <andersca@codefactory.se>
7544 * dbus/dbus-connection-internal.h:
7545 * dbus/dbus-connection.c: (_dbus_connection_new_for_transport),
7546 (_dbus_connection_get_next_client_serial),
7547 (dbus_connection_send_message):
7548 * dbus/dbus-internals.h:
7549 * dbus/dbus-marshal.c: (unpack_uint32), (dbus_unpack_int32),
7550 (dbus_pack_int32), (_dbus_marshal_double), (_dbus_marshal_int32),
7551 (_dbus_marshal_uint32), (_dbus_demarshal_double),
7552 (_dbus_demarshal_int32), (_dbus_demarshal_uint32),
7553 (_dbus_demarshal_string), (_dbus_marshal_get_field_end_pos),
7554 (_dbus_verbose_bytes), (_dbus_marshal_test):
7555 * dbus/dbus-marshal.h:
7556 * dbus/dbus-message-internal.h:
7557 * dbus/dbus-message.c: (_dbus_message_set_client_serial),
7558 (dbus_message_write_header), (_dbus_message_lock),
7559 (dbus_message_new), (dbus_message_ref), (dbus_message_unref),
7560 (dbus_message_get_name), (dbus_message_append_int32),
7561 (dbus_message_append_uint32), (dbus_message_append_double),
7562 (dbus_message_append_string), (dbus_message_append_byte_array),
7563 (dbus_message_get_fields_iter), (dbus_message_iter_ref),
7564 (dbus_message_iter_unref), (dbus_message_iter_has_next),
7565 (dbus_message_iter_next), (dbus_message_iter_get_field_type),
7566 (dbus_message_iter_get_string), (dbus_message_iter_get_int32),
7567 (dbus_message_iter_get_uint32), (dbus_message_iter_get_double),
7568 (decode_header_data), (_dbus_message_loader_return_buffer),
7569 (message_iter_test), (_dbus_message_test):
7570 * dbus/dbus-message.h:
7571 * dbus/dbus-protocol.h:
7572 * dbus/dbus-test.c: (main):
7574 * glib/test-dbus-glib.c: (message_handler), (main):
7575 * test/echo-client.c: (main):
7576 * test/watch.c: (check_messages):
7577 Make messages sendable and receivable for real.
7579 2003-01-07 Anders Carlsson <andersca@codefactory.se>
7581 * dbus/dbus-marshal.c: (_dbus_marshal_double),
7582 (_dbus_marshal_string), (_dbus_marshal_byte_array):
7583 * dbus/dbus-message.c: (dbus_message_append_int32),
7584 (dbus_message_append_uint32), (dbus_message_append_double),
7585 (dbus_message_append_string), (dbus_message_append_byte_array):
7586 Handle OOM restoration.
7588 2003-01-07 Anders Carlsson <andersca@codefactory.se>
7590 * dbus/dbus-marshal.c: (_dbus_marshal_string),
7591 (_dbus_demarshal_string), (_dbus_marshal_test):
7592 * dbus/dbus-marshal.h:
7593 * dbus/dbus-message.c: (dbus_message_get_name),
7594 Document these functions.
7596 (dbus_message_append_int32), (dbus_message_append_uint32),
7597 (dbus_message_append_double), (dbus_message_append_string),
7598 (dbus_message_append_byte_array):
7599 * dbus/dbus-message.h:
7600 Add functions for adding message fields of different types.
7602 * dbus/dbus-protocol.h:
7603 Add the different types.
7605 2003-01-05 Havoc Pennington <hp@pobox.com>
7607 * bus/connection.c: implement routines for handling connections,
7608 first thing is keeping a list of owned services on each connection
7609 and setting up watches etc.
7611 * bus/services.c: implement a mapping from service names to lists
7614 * dbus/dbus-hash.c: add DBUS_HASH_POINTER
7616 * dbus/dbus-threads.c (dbus_static_mutex_lock): add functions
7617 to use static mutexes for global data
7619 * dbus/dbus-connection.c (dbus_connection_set_data): add new
7620 collection of functions to set/get application-specific data
7621 on the DBusConnection.
7623 2003-01-04 Havoc Pennington <hp@pobox.com>
7625 * dbus/dbus-sysdeps.c (_dbus_sleep_milliseconds): new function
7626 (_dbus_poll): new function
7628 * dbus/dbus-internals.h (_DBUS_STRUCT_OFFSET): new macro
7631 * bus/loop.c: initial code for the daemon main loop
7633 2003-01-04 Havoc Pennington <hp@pobox.com>
7635 * test/watch.c (error_handler): make it safe if the error handler
7636 is called multiple times (if we s/error handler/disconnect
7637 handler/ we should just guarantee it's called only once)
7639 * dbus/dbus-transport.c (_dbus_transport_disconnect): call the
7640 error handler on disconnect (it's quite possible we should
7641 just change the error handler to a "disconnect handler," I'm
7642 not sure we have any other meaningful errors)
7644 * configure.in: check for getpwnam_r
7646 * dbus/dbus-transport.c, dbus/dbus-transport-unix.c,
7647 dbus/dbus-auth.c: add credentials support, add EXTERNAL auth
7648 mechanism as in SASL spec, using socket credentials
7650 * dbus/dbus-sysdeps.c (_dbus_read_credentials_unix_socket): new function
7651 (_dbus_send_credentials_unix_socket): new function
7653 * dbus/dbus-sysdeps.c (_dbus_accept_unix_socket): rename just
7655 (_dbus_write): only check errno if <0 returned
7656 (_dbus_write_two): ditto
7658 2003-01-02 Anders Carlsson <andersca@codefactory.se>
7660 * dbus/dbus-marshal.c: (_dbus_marshal_utf8_string),
7661 (_dbus_marshal_byte_array), (_dbus_demarshal_utf8_string),
7662 (_dbus_marshal_test):
7663 * dbus/dbus-marshal.h:
7664 Add _dbus_marshal_byte_array and rename _dbus_marshal_string
7665 to _dbus_marshal_utf8_string. Also fix some tests.
7667 2002-12-28 Harri Porten <porten@kde.org>
7669 * configure.in: added check for C++ compiler and a very cheesy
7670 check for the Qt integration
7672 * Makefile.am (SUBDIRS): compile qt subdir if support is enabled
7674 * qt/Makefile.am: added
7676 * qt/.cvsignore: added
7678 * qt/dbus-qthread.cc, qt/dbus-qthread.cpp: renamed former to
7679 latter, added #ifdef QT_THREAD_SUPPORT guard.
7681 * dbus/Makefile.am: added missing headers for make dist
7683 2002-12-28 Kristian Rietveld <kris@gtk.org>
7685 * dbus/Makefile.am: fixup export-symbols-regex.
7687 2002-12-27 Anders Carlsson <andersca@codefactory.se>
7689 * acinclude.m4: Add this file and put the
7690 PKG_CHECK_MODULE macro in it.
7692 2002-12-27 Anders Carlsson <andersca@codefactory.se>
7694 * dbus/dbus-marshal.c: (_dbus_marshal_string),
7695 (_dbus_demarshal_double), (_dbus_demarshal_int32),
7696 (_dbus_demarshal_uint32), (_dbus_demarshal_string),
7697 (_dbus_marshal_test):
7698 Make the demarshalling routines align the pos argument.
7699 Add string marshalling tests and fix the obvious bugs
7702 2002-12-26 Havoc Pennington <hp@pobox.com>
7704 * dbus/dbus-auth.c: fixes fixes fixes
7706 * dbus/dbus-transport-unix.c: wire up support for
7707 encoding/decoding data on the wire
7709 * dbus/dbus-auth.c (_dbus_auth_encode_data)
7710 (_dbus_auth_decode_data): append to target string
7711 instead of nuking it.
7713 2002-12-26 Havoc Pennington <hp@pobox.com>
7715 * dbus/dbus-marshal.h (DBUS_COMPILER_BYTE_ORDER): #ifdef
7716 WORDS_BIGENDIAN then compiler byte order is DBUS_BIG_ENDIAN,
7719 * dbus/dbus-marshal.c: Add macros to do int swapping in-place and
7720 avoid swap_bytes() overhead (ignoring possible assembly stuff for
7721 now). Main point is because I wanted unpack_uint32 to implement
7723 (_dbus_verbose_bytes): new function
7725 * dbus/dbus-string.c (_dbus_string_validate_ascii): new function
7727 * dbus/dbus-message.c (_dbus_message_loader_get_is_corrupted): add
7728 mechanism to handle a corrupt message stream
7729 (_dbus_message_loader_new): fix preallocation to only prealloc,
7732 * dbus/dbus-string.c (_dbus_string_skip_blank): fix this function
7733 (_dbus_string_test): enhance tests for copy/move and fix the
7736 * dbus/dbus-transport-unix.c: Hold references in more places to
7737 avoid reentrancy problems
7739 * dbus/dbus-transport.c: ditto
7741 * dbus/dbus-connection.c (dbus_connection_dispatch_message): don't
7742 leak reference count in no-message case
7744 * test/watch.c (do_mainloop): handle adding/removing watches
7745 during iteration over the watches. Also, ref the connection/server
7746 stored on a watch, so we don't try to mangle a destroyed one.
7748 * dbus/dbus-transport-unix.c (do_authentication): perform
7751 * dbus/dbus-auth.c (get_state): add a state
7752 AUTHENTICATED_WITH_UNUSED_BYTES and return it if required
7753 (_dbus_auth_get_unused_bytes): append the unused bytes
7754 to the passed in string, rather than prepend
7756 * dbus/dbus-transport.c (_dbus_transport_init_base): create
7757 the auth conversation DBusAuth
7759 * dbus/dbus-transport-unix.c (_dbus_transport_new_for_fd)
7760 (_dbus_transport_new_for_domain_socket): when creating a
7761 transport, pass in whether it's a client-side or server-side
7762 transport so we know which DBusAuth to create
7764 2002-12-03 Havoc Pennington <hp@pobox.com>
7766 * dbus/dbus-transport-unix.c (unix_finalize): finalize base
7767 _after_ finalizing the derived members
7768 (unix_connection_set): unref watch if we fail to add it
7770 * dbus/dbus-connection.c (dbus_connection_unref): delete the
7771 transport first, so that the connection owned by the
7772 transport will be valid as the transport finalizes.
7774 * dbus/dbus-transport-unix.c (unix_finalize): free the write_watch
7775 if necessary, and remove watches from the connection.
7777 * dbus/dbus-watch.c (_dbus_watch_list_free): improve a comment
7779 2002-12-26 Anders Carlsson <andersca@codefactory.se>
7781 * dbus/dbus-marshal.c: (_dbus_marshal_string),
7782 (_dbus_demarshal_double), (_dbus_demarshal_int32),
7783 (_dbus_demarshal_uint32), (_dbus_demarshal_string),
7784 (_dbus_marshal_test):
7785 * dbus/dbus-marshal.h:
7786 Add string marshal functions and have the demarshal functions
7787 return the new position.
7789 2002-12-25 Havoc Pennington <hp@pobox.com>
7791 * doc/dbus-sasl-profile.txt: docs on the authentication protocol,
7792 it is a simple protocol that just maps directly to SASL.
7794 * dbus/dbus-auth.h, dbus/dbus-auth.c: authentication protocol
7795 initial implementation, not actually used yet.
7797 * dbus/dbus-string.c (_dbus_string_find): new function
7798 (_dbus_string_equal): new function
7799 (_dbus_string_base64_encode): new function
7800 (_dbus_string_base64_decode): new function
7802 2002-12-25 Anders Carlsson <andersca@codefactory.se>
7805 * dbus/dbus-marshal.c: (swap_bytes), (_dbus_marshal_double),
7806 (_dbus_marshal_int32), (_dbus_marshal_uint32),
7807 (_dbus_demarshal_double), (_dbus_demarshal_int32),
7808 (_dbus_demarshal_uint32), (_dbus_marshal_test):
7809 * dbus/dbus-marshal.h:
7810 * dbus/dbus-protocol.h:
7811 * dbus/dbus-test.c: (main):
7813 Add un-optimized marshalling/demarshalling routines.
7815 2002-12-25 Harri Porten <porten@kde.org>
7817 * qt/dbus-qt.h: adjusted ctor and getter to KDE/Qt conventions
7819 2002-12-24 Zack Rusin <zack@kde.org>
7821 * qt/dbus-qthread.cc: adding - integrates QMutex into Dbus
7822 * qt/dbus-qt.h: skeleton with two sample implemenatation of the
7825 2002-12-24 Havoc Pennington <hp@pobox.com>
7827 * glib/dbus-gthread.c: fix include
7829 * glib/dbus-glib.h: rename DBusMessageHandler for now.
7830 I think glib API needs to change, though, as you don't
7831 want to use DBusMessageFunction, you want to use the
7832 DBusMessageHandler object. Probably
7833 dbus_connection_open_with_g_main_loop()
7834 and dbus_connection_setup_g_main_loop() or something like that
7835 (but think of better names...) that just create a connection
7836 that has watch/timeout functions etc. already set up.
7838 * dbus/dbus-connection.c
7839 (dbus_connection_send_message_with_reply): new function just to
7840 show how the message handler helps us deal with replies.
7842 * dbus/dbus-list.c (_dbus_list_remove_last): new function
7844 * dbus/dbus-string.c (_dbus_string_test): free a string that
7847 * dbus/dbus-hash.c: use memory pools for the hash entries
7848 (rebuild_table): be more paranoid about overflow, and
7849 shrink table when we can
7850 (_dbus_hash_test): reduce number of sprintfs and write
7851 valid C89. Add tests for case where we grow and then
7852 shrink the hash table.
7854 * dbus/dbus-mempool.h, dbus/dbus-mempool.c: memory pools
7856 * dbus/dbus-connection.c (dbus_connection_register_handler)
7857 (dbus_connection_unregister_handler): new functions
7859 * dbus/dbus-message.c (dbus_message_get_name): new
7861 * dbus/dbus-list.c: fix docs typo
7863 * dbus/dbus-message-handler.h, dbus/dbus-message-handler.c:
7864 an object representing a handler for messages.
7866 2002-12-16 Anders Carlsson <andersca@codefactory.se>
7869 * glib/dbus-gthread.c: (dbus_gthread_init):
7870 Don't use the gdbus prefix for public functions.
7872 2002-12-16 Anders Carlsson <andersca@codefactory.se>
7876 Add GLib checks and fixup .pc files
7880 * glib/dbus-gmain.c: (gdbus_connection_prepare),
7881 (gdbus_connection_check), (gdbus_connection_dispatch),
7882 (gdbus_add_connection_watch), (gdbus_remove_connection_watch),
7883 (dbus_connection_gsource_new):
7884 * glib/dbus-gthread.c: (dbus_gmutex_new), (dbus_gmutex_free),
7885 (dbus_gmutex_lock), (dbus_gmutex_unlock), (dbus_gthread_init):
7886 * glib/test-dbus-glib.c: (message_handler), (main):
7889 2002-12-15 Harri Porten <porten@kde.org>
7891 * autogen.sh: check for libtoolize before attempting to use it
7893 * dbus/dbus-transport-unix.c: include <sys/time.h> for timeval
7896 * .cvsignore: ignore more stamp files
7898 * dbus/dbus-watch.c (_dbus_watch_list_new): fixed doc error
7900 * test/Makefile.am: added -I$(top_srcdir) to be able to compile
7901 without make install.
7903 2002-12-15 Havoc Pennington <hp@pobox.com>
7905 * dbus/dbus-threads.c: add thread stubs that a higher library
7906 layer can fill in. e.g. the GLib wrapper might fill them in with
7907 GThread stuff. We still need to use this thread API to
7908 thread-safe-ize the library.
7910 2002-12-12 Havoc Pennington <hp@pobox.com>
7912 * dbus/dbus-transport-unix.c, dbus/dbus-server-unix.c: use the
7913 below new interfaces and include fewer system headers.
7915 * dbus/dbus-sysdeps.c (_dbus_read): new function
7916 (_dbus_write): new function
7917 (_dbus_write_two): new function
7918 (_dbus_connect_unix_socket): new function
7919 (_dbus_listen_unix_socket): new function
7921 * dbus/dbus-message-internal.h: change interfaces to use
7924 2002-12-11 Havoc Pennington <hp@pobox.com>
7926 * dbus/dbus-types.h: add dbus_unichar
7928 * dbus/dbus-internals.c (_dbus_verbose): use _dbus_getenv
7930 * dbus/dbus-connection.c (dbus_connection_send_message): return
7933 * dbus/dbus-transport.c: include dbus-watch.h
7935 * dbus/dbus-connection.c: include dbus-message-internal.h
7937 * HACKING: add file with coding guidelines stuff.
7939 * dbus/dbus-string.h, dbus/dbus-string.c: Encapsulate all string
7940 handling here, for security purposes (as in vsftpd). Not actually
7941 using this class yet.
7943 * dbus/dbus-sysdeps.h, dbus/dbus-sysdeps.c: Encapsulate all
7944 system/libc usage here, as in vsftpd, for ease of auditing (and
7945 should also simplify portability). Haven't actually moved all the
7946 system/libc usage into here yet.
7948 2002-11-25 Havoc Pennington <hp@pobox.com>
7950 * dbus/dbus-internals.c (_dbus_verbose): fix to not
7951 always print the first verbose message.
7953 2002-11-24 Havoc Pennington <hp@pobox.com>
7955 * test/echo-client.c, test/echo-server.c: cheesy test
7958 * configure.in (AC_CHECK_FUNCS): check for writev
7960 * dbus/dbus-message.c (_dbus_message_get_network_data): new
7963 * dbus/dbus-list.c (_dbus_list_foreach): new function
7965 * dbus/dbus-internals.c (_dbus_verbose): new function
7967 * dbus/dbus-server.c, dbus/dbus-server.h: public object
7968 representing a server that listens for connections.
7970 * dbus/.cvsignore: create
7972 * dbus/dbus-errors.h, dbus/dbus-errors.c:
7973 public API for reporting errors
7975 * dbus/dbus-connection.h, dbus/dbus-connection.c:
7976 public object representing a connection that
7977 sends/receives messages. (Same object used for
7978 both client and server.)
7980 * dbus/dbus-transport.h, dbus/dbus-transport.c:
7981 Basic abstraction for different kinds of stream
7982 that we might read/write messages from.
7984 2002-11-23 Havoc Pennington <hp@pobox.com>
7986 * dbus/dbus-internals.h (_DBUS_INT_MAX): add _DBUS_INT_MIN
7989 * dbus/dbus-test.c (main): add list test, and include
7990 dbus-test.h as intended
7992 * dbus/dbus-hash.c (_dbus_hash_table_remove_string)
7993 (_dbus_hash_table_remove_int): return value indicates
7994 whether the entry existed to remove
7996 * dbus/dbus-list.c: add linked list utility class,
7999 * dbus/dbus-hash.c: add TODO item about shrinking the hash bucket
8002 2002-11-23 Havoc Pennington <hp@pobox.com>
8004 * Doxyfile.in (INCLUDE_FILE_PATTERNS): expand DBUS_BEGIN_DECLS/
8005 DBUS_END_DECLS to nothing, that should fix this once and for all
8007 * Doxyfile.in (JAVADOC_AUTOBRIEF): set to YES
8009 * dbus/dbus-message.c, dbus/dbus-hash.c:
8010 add some missing @brief
8012 2002-11-23 Havoc Pennington <hp@pobox.com>
8014 * dbus/dbus-message.h: put semicolons after DEBUG_BEGIN_DECLS
8015 to avoid confusing Doxygen
8017 * dbus/dbus-hash.c: @} not }@
8019 * dbus/dbus-message.c (struct DBusMessage): split out
8022 2002-11-23 Havoc Pennington <hp@pobox.com>
8024 * configure.in: pile on more warning flags if using gcc
8026 * Doxyfile.in (EXTRACT_STATIC): set to NO, so we don't have
8027 to document static functions
8029 * configure.in: add summary to end of configure so it
8030 looks nice and attractive
8032 * dbus/dbus-hash.c: finish implementation and write unit
8035 * configure.in: add --enable-tests to enable unit tests
8037 * dbus/dbus-test.c: test program to run unit tests
8038 for all files in dbus/*, initially runs a test for
8041 * dbus/dbus-internals.h: file to hold some internal utility stuff
8043 2002-11-22 Havoc Pennington <hp@redhat.com>
8045 * dbus/dbus-hash.c: copy in Tcl hash table, not yet
8046 "ported" away from Tcl
8048 * dbus/dbus-types.h: header for types such as dbus_bool_t
8050 2002-11-22 Havoc Pennington <hp@redhat.com>
8052 * dbus/dbus.h: fixups for doc warnings
8054 * Doxyfile.in (FILE_PATTERNS): we need to scan .h to pick up
8056 (QUIET): make it quiet so we can see warnings
8058 * dbus/dbus-memory.c: teach D-BUS to allocate and free memory
8060 2002-11-22 Havoc Pennington <hp@redhat.com>
8062 * Makefile.am: include "Doxyfile" target in all-local
8064 * configure.in: generate the Doxyfile
8066 * Doxyfile.in: move Doxyfile here, so we can use
8067 configure to generate a Doxyfile with the right
8070 2002-11-22 Havoc Pennington <hp@redhat.com>
8072 * dbus/dbus-message.c: move inline docs into .c file
8074 * Doxyfile (OUTPUT_DIRECTORY): move output to doc/api
8075 so all docs are under doc/
8076 (MAN_EXTENSION): generate man pages. Use extension
8077 ".3dbus" which matches ".3qt" on my system,
8078 I guess this is OK, I don't know really.
8079 (FILE_PATTERNS): look for .c files not .h, makes sense
8082 2002-11-22 Havoc Pennington <hp@pobox.com>
8084 * Makefile.am (SUBDIRS): rename subdir "server" to "bus"
8085 because any app can be a server, and any app can be a client,
8086 the bus is a special kind of server.
8088 Thu Nov 21 23:35:31 2002 Zack Rusin <zack@kde.org>
8090 * Doxyfile : adding. Still needs Makefile rules to be generated
8091 automatically (just run "doxygen" in the toplevel dir for now to
8094 * dbus/dbus-message.h : Adding sample docs (javadoc since
8095 resembles gtk-doc a little more)
8097 * dbus/dbus.h : Adding sample docs
8099 2002-11-21 Havoc Pennington <hp@redhat.com>
8101 * dbus/Makefile.am (INCLUDES): define DBUS_COMPILATION
8102 so we can allow ourselves to include files directly,
8103 instead of having to use dbus.h
8105 * dbus/dbus.h: fill in
8107 * dbus/dbus-message.h: sketch out a sample header file.
8108 Include griping if you include it directly instead of
8111 * dbus/dbus-macros.h: new file with macros for extern "C",
8112 TRUE/FALSE, NULL, etc.
8114 * doc/file-boilerplate.c: put include guards in here
8116 2002-11-21 Havoc Pennington <hp@redhat.com>
8118 * doc/file-boilerplate.c: include both AFL and GPL boilerplate.
8120 * COPYING: include the GPL as well, and license code
8121 under both AFL and GPL.
8123 2002-11-21 Havoc Pennington <hp@redhat.com>
8125 * acconfig.h: get rid of this
8127 * autogen.sh (run_configure): add --no-configure option
8129 * configure.in: remove AC_ARG_PROGRAM to make
8130 autoconf complain less. add AC_PREREQ.
8131 add AC_DEFINE third arg.
8133 2002-11-21 Anders Carlsson <andersca@codefactory.se>
8136 Fix references so we can distcheck.
8138 2002-11-21 Havoc Pennington <hp@redhat.com>
8140 * Initial module creation