2003-04-06 Havoc Pennington <hp@pobox.com>
[platform/upstream/dbus.git] / ChangeLog
1 2003-04-06  Havoc Pennington  <hp@pobox.com>
2
3         * dbus/dbus-threads.c: Redo how the fake debug mutexes are done 
4         so it detects deadlocks and also we actually init threads when 
5         debugging.
6
7 2003-04-06  Havoc Pennington  <hp@pobox.com>
8
9         * dbus/dbus-server-unix.c (_dbus_server_new_for_domain_socket):
10         save the domain socket name, and unlink it when we disconnect the
11         server. Means that at least when we exit normally, we won't leave
12         a bunch of junk in /tmp
13
14         * dbus/dbus-transport-unix.c
15         (_dbus_transport_new_for_domain_socket): code cleanup (nicer
16         memory management). (I was making a real change here but then
17         didn't)
18
19 2003-04-06  Havoc Pennington  <hp@pobox.com>
20
21         * bus/bus.c (bus_context_new): fix wrong handling of
22         server_data_slot_unref() in the error case. 
23
24         * dbus/dbus-internals.h (_dbus_assert): change so it passes
25         "(condition) != 0" to _dbus_real_assert so that
26         "_dbus_assert (pointer)" doesn't cause a warning
27
28         * bus/main.c (main): accept --print-address option to print out
29         the message bus address
30
31         * dbus/dbus-sysdeps.c (_dbus_generate_random_ascii): export this
32
33         * dbus/dbus-transport.c (_dbus_transport_open): special error for
34         "tmpdir" option to unix: address on client side
35
36         * dbus/dbus-server.c (dbus_server_listen): handle "tmpdir" option 
37         to unix: address
38         
39         * configure.in (TEST_SOCKET_DIR): locate a temporary directory 
40         we can use to create sockets in the test suite.
41
42         * bus/main.c (signal_handler): on SIGTERM, exit the daemon
43         cleanly. To be used for testing.
44
45         * dbus/dbus-spawn.c (babysit): use _dbus_set_signal_handler()
46
47         * dbus/dbus-sysdeps.c (_dbus_set_signal_handler): new
48
49         * dbus/dbus-server-debug-pipe.c (_dbus_transport_debug_pipe_new):
50         handle trying to call this when there's no servers active
51
52 2003-04-05  Havoc Pennington  <hp@pobox.com>
53
54         * NEWS: update
55
56         * configure.in: 0.8
57
58 2003-04-05  Havoc Pennington  <hp@pobox.com>
59
60         * bus/bus.c (setup_server): fix this so dbus-daemon-1 doesn't 
61         crash on startup. Need to get "try starting the daemon" 
62         in the test suite I guess. ;-)
63
64         * dbus/dbus-server.h, dbus/dbus-server.c: remove the stuff that
65         tracked the number of open connections; it's better done in 
66         application-specific code as you want it to span all servers etc.
67
68 2003-04-05  Havoc Pennington  <hp@pobox.com>
69
70         * bus/Makefile.am (install-data-hook): add missing DESTDIR, 
71         patch from Colin Walters
72
73 2003-04-05  Havoc Pennington  <hp@pobox.com>
74
75         * doc/config-file.txt (Elements): fix docs of <auth> to reflect 
76         reality; in fact multiple mechanisms are allowed.
77
78         * dbus/dbus-internals.c (_dbus_real_assert)
79         (_dbus_real_assert_not_reached): move guts of _dbus_assert() and
80         _dbus_assert_not_reached() into functions, so that they don't show
81         up in basic block counts for test coverage, and don't use up as
82         much disk space. Does mean slower execution speed though, so
83         assumes --disable-asserts is the normal production case.
84
85 2003-04-05  Havoc Pennington  <hp@pobox.com>
86
87         * test/Makefile.am (dist-hook): also dist *.in files
88
89         * NEWS: update
90
91         * configure.in: 0.7
92         
93 2003-04-05  Havoc Pennington  <hp@pobox.com>
94
95         * dbus/dbus-string.c: docs warning
96         
97         * dbus/dbus-spawn.c: missing docs
98
99         * dbus/dbus-memory.c (struct ShutdownClosure): missing docs
100
101 2003-04-05  Havoc Pennington  <hp@pobox.com>
102
103         * bus/loop.c (bus_loop_iterate): fix the timeout code, using 
104         magic from GLib
105
106         * dbus/dbus-spawn.c (_dbus_babysitter_unref): set sitter_pid 
107         to -1 once we've reaped the babysitter
108         (_dbus_babysitter_handle_watch): do as much work as we can, not
109         just one go of it
110
111         * bus/activation.c: add code using DBusBabysitter so that we
112         handle it when a service fails to start up properly.
113         (bus_activation_service_created): don't remove the activation
114         entries as we go, just let them get removed when we free the pending
115         activation. Unref reply messages after sending them.
116
117 2003-04-05  Havoc Pennington  <hp@pobox.com>
118
119         * test/decode-gcov.c (main): print per-directory stats in the report
120
121         * Makefile.am (coverage-report.txt): don't include test/* in gcov stats
122
123 2003-04-05  Havoc Pennington  <hp@pobox.com>
124
125         * Makefile.am (coverage-report.txt): add target "coverage-report.txt"
126
127         * test/decode-gcov.c: hack up a little program to suck data 
128         out of gcov files. Yes this is sort of silly.
129
130         * configure.in: define something in config.h and do an
131         AM_CONDITIONAL when gcov is enabled
132
133 2003-04-04  Havoc Pennington  <hp@redhat.com>
134
135         * dbus/dbus-spawn.c, dbus/dbus-spawn.h: Change dbus_spawn to
136         return a "babysitter" object that is used to monitor the status of
137         the spawned process and reap it when required.
138
139         * test/test-segfault.c, test/test-exit.c,
140         test/test-sleep-forever.c: binaries that do various lame things, 
141         used in the test suite.
142
143         * dbus/dbus-sysdeps.c: kill _dbus_errno_to_string()
144         
145 2003-04-03  Havoc Pennington  <hp@pobox.com>
146
147         * dbus/dbus-spawn.c: Move dbus-spawn into a separate file 
148         in preparation for modifying it, dbus-sysdeps is getting 
149         a bit unmanageable.
150
151 2003-04-03  Havoc Pennington  <hp@redhat.com>
152
153         * bus/loop.h, bus/loop.c: make the mainloop an object so we can
154         have multiple ones
155
156         * bus/*.[hc]: adapt to mainloop change
157
158 2003-04-03  Havoc Pennington  <hp@redhat.com>
159
160         * bus/activation.c (load_directory): fix up memleaks
161         (bus_activation_entry_free): free the entry
162
163         * dbus/dbus-bus.c (dbus_bus_acquire_service): return an error if
164         we get one from the message bus; fix memleaks.
165
166         * dbus/dbus-message.c (dbus_set_error_from_message): new function
167
168 2003-04-03  Havoc Pennington  <hp@pobox.com>
169
170         * bus/config-parser.c (bus_config_parser_unref): free 
171         list of mechanisms, bug discovered by test suite enhancements
172         (putting system.conf and session.conf into suite)
173
174         * test/Makefile.am, test/test-service.c: add placeholder for a
175         test service that we'll activate as part of test suite. Doesn't 
176         do anything yet.
177
178         * dbus/dbus-sysdeps.c (_dbus_setenv): support unsetenv by 
179         setting NULL value, and use system malloc not dbus_malloc() 
180         when we have unavoidable memleakage.
181
182         * dbus/dbus-bus.c (dbus_bus_get): fix bug where bus type of 0
183         didn't work, and support DBUS_BUS_ACTIVATION.
184         
185         * bus/activation.c (child_setup): pass our well-known bus type to
186         the child
187
188         * bus/config-parser.c: support <type> to specify well-known type
189
190         * doc/dbus-specification.sgml: document the env variables to 
191         locate well-known buses and find service activator
192
193 2003-04-02  Havoc Pennington  <hp@redhat.com>
194
195         * test/Makefile.am (all-local): add a rule to copy tests to
196         builddir, so we can have generated tests. Use this to remove the
197         silly hack for testing system.conf and session.conf. Will use this 
198         shortly to generate .service files pointing to test binaries.
199
200 2003-04-02  Havoc Pennington  <hp@redhat.com>
201
202         * dbus/dbus-string.c (set_length): fix a bug - we allocated max of
203         current alloc and needed new length, not max of the doubled
204         allocation and needed new length. Also, when building tests, 
205         don't do the double-allocation stuff, just realloc every time.
206
207 2003-04-02  Havoc Pennington  <hp@redhat.com>
208
209         * dbus/dbus-sysdeps.c (_dbus_file_get_contents): include filenames
210         in error messages
211         (_dbus_string_get_dirname): new
212         (_dbus_sysdeps_test): new
213         (_dbus_directory_open): include dirnames in error messages
214
215         * bus/config-parser.c: interpret <include> and <includedir> and
216         <servicedir> relative to config file location if the given
217         filename is not absolute.
218
219         * dbus/dbus-string.c (_dbus_string_find_byte_backward): new
220
221 2003-04-02  Havoc Pennington  <hp@redhat.com>
222
223         * bus/connection.c (bus_transaction_send_error_reply): set sender
224         service for the error, and unref the reply on success
225
226         * bus/activation.c: convert to use BusTransaction so OOM can be
227         handled correctly
228         (bus_activation_service_created): set sender of the message
229
230 2003-04-01  Havoc Pennington  <hp@redhat.com>
231
232         * bus/config-parser.c, bus/bus.c: implement <servicedir> and
233         <includedir> (at least mostly)
234
235         * dbus/dbus-sysdeps.c (_dbus_change_identity): set the group ID
236         first, then the user ID
237
238 2003-04-01  Havoc Pennington  <hp@pobox.com>
239
240         * dbus/dbus-server.c (dbus_server_set_auth_mechanisms): new
241         function
242
243         * dbus/dbus-auth.c (_dbus_auth_set_mechanisms): new
244
245         * dbus/dbus-internals.c (_dbus_dup_string_array): new function
246
247         * dbus/dbus-sysdeps.c (_dbus_listen_unix_socket): chmod the
248         socket 0777, and unlink any existing socket.
249
250         * bus/bus.c (bus_context_new): change our UID/GID and fork if
251         the configuration file so specifies; set up auth mechanism 
252         restrictions
253
254         * bus/config-parser.c (bus_config_parser_content): add support
255         for <fork> option and fill in code for <auth> 
256
257         * bus/system.conf.in: add <fork/> to default configuration, 
258         and limit auth mechanisms to EXTERNAL
259
260         * doc/config-file.txt (Elements): add <fork>
261
262         * dbus/dbus-sysdeps.c (_dbus_become_daemon): new function
263         (_dbus_change_identity): new function
264
265 2003-03-31  Havoc Pennington  <hp@redhat.com>
266
267         * dbus/dbus-sysdeps.c (_dbus_connect_unix_socket) 
268         (_dbus_listen_unix_socket): fix off-by-one error in null
269         termination spotted by Nalin
270
271 2003-03-31  Havoc Pennington  <hp@redhat.com>
272
273         * dbus/dbus-keyring.c (_dbus_keyring_new_homedir): allow setting
274         DBUS_TEST_HOMEDIR when tests are enabled, so we can test without
275         having a real home directory available.
276
277 2003-03-31  Havoc Pennington  <hp@redhat.com>
278
279         * bus/Makefile.am (install-data-hook): create /var/run/dbus
280
281         * bus/messagebus.in: add init script for Red Hat /etc/init.d
282
283         * configure.in: add support for specifying a style of init script
284         to install
285
286 2003-03-31  Havoc Pennington  <hp@redhat.com>
287
288         Fix some annoying DBusString API and fix all affected code.
289         
290         * dbus/dbus-string.c (_dbus_string_init): get rid of annoying
291         max_length argument
292         (_dbus_string_get_data): change to return string instead of using 
293         an out param
294         (_dbus_string_get_const_data): ditto
295         (_dbus_string_get_data_len): ditto
296         (_dbus_string_get_const_data_len): ditto
297
298 2003-03-31  Havoc Pennington  <hp@redhat.com>
299
300         * bus/main.c (main): fix up the command line arguments to be nicer
301
302 2003-03-31  Havoc Pennington  <hp@redhat.com>
303
304         * dbus/Makefile.am (INCLUDES): use EXPANDED_LOCALSTATEDIR to
305         define DBUS_SYSTEM_BUS_PATH as we want to compile in the same 
306         final location that lands in the config file
307
308         * bus/config-loader-expat.c (bus_config_load): fix type of
309         XML_Parser variable
310
311         * doc/TODO: remove TODO item for dbus_bus_get()
312
313         * dbus/dbus-bus.c (bus_data_free): add missing lock/unlock
314
315 2003-03-31  Havoc Pennington  <hp@pobox.com>
316
317         * dbus/dbus-transport-unix.c (_dbus_transport_new_for_domain_socket)
318         (_dbus_transport_new_for_tcp_socket): these didn't need the "server"
319         argument since they are always client side
320
321         * dbus/dbus-server.c (dbus_server_get_address): new function
322
323         * bus/main.c (main): take the configuration file as an argument.
324
325         * test/data/valid-config-files/debug-allow-all.conf: new file to 
326         use with dispatch.c tests for example
327
328         * bus/test-main.c (main): require test data dir
329
330         * bus/bus.c (bus_context_new): change this to take a
331         configuration file name as argument
332
333         * doc/config-file.txt (Elements): add <servicedir>
334
335         * bus/system.conf, bus/session.conf: new files
336         
337         * dbus/dbus-bus.c (dbus_bus_get): look for system bus on
338         well-known socket if none set
339
340         * configure.in: create system.conf and session.conf
341
342 2003-03-30  Havoc Pennington  <hp@pobox.com>
343
344         * bus/config-parser.c: hacking
345         
346         * dbus/dbus-memory.c: don't use DBusList for the list of stuff 
347         to shut down, since it could cause weirdness with the DBusList
348         lock
349
350         * dbus/dbus-list.c (_dbus_list_test): add tests for the
351         link-oriented stack routines
352         (alloc_link): free the mempool if the first alloc from it fails
353
354         * dbus/dbus-mempool.c (struct DBusMemBlock): fix alignment issue
355
356         * dbus/dbus-string.c (UNICODE_VALID): sync new version of this
357         from GLib
358         (_dbus_string_skip_white): new
359
360         * doc/config-file.txt (Elements): add <includedir>
361
362 2003-03-28  Havoc Pennington  <hp@pobox.com>
363
364         * dbus/dbus-string.c (_dbus_string_copy_data_len)
365         (_dbus_string_copy_data): new functions
366
367 2003-03-28  Anders Carlsson  <andersca@codefactory.se>
368
369         * dbus/dbus-bus.c: (bus_data_free), (dbus_bus_get):
370         * dbus/dbus-bus.h:
371         Add dbus_bus_get.
372         
373         * dbus/dbus-memory.c:
374         Fix a doc comment.
375         
376 2003-03-28  Havoc Pennington  <hp@pobox.com>
377
378         * bus/test.c (bus_test_flush_bus): remove the sleep from here, 
379         I think it may have just been superstition. Not sure.
380
381         * dbus/dbus-string.c (_dbus_string_base64_decode): catch some OOM
382         failures that were not being handled.
383
384         * dbus/dbus-auth.c (process_auth): fix a memleak in OOM handling
385
386         * dbus/dbus-memory.c: add ability to set number of mallocs in a
387         row that will fail on out-of-memory.
388
389         * dbus/dbus-internals.c (_dbus_test_oom_handling): convenience
390         function for testing out-of-memory handling.
391
392         * bus/config-loader-expat.c (memsuite): don't wrap the dbus
393         allocation functions, they do map exactly to the expat ones.
394
395 2003-03-27  Havoc Pennington  <hp@redhat.com>
396
397         * bus/config-loader-libxml.c (bus_config_load): add another error
398         check
399
400 2003-03-26  Anders Carlsson  <andersca@codefactory.se>
401
402         * doc/TODO:
403         Add note about automatic service activation.
404         
405         * doc/dbus-specification.sgml:
406         Rename the specification and clarify a few things.
407         
408 2003-03-26  Anders Carlsson  <andersca@codefactory.se>
409
410         * Doxyfile.in:
411         * dbus/dbus-address.c:
412         * dbus/dbus-dict.c:
413         * dbus/dbus-marshal.c:
414         * dbus/dbus-server-debug-pipe.c:
415         * dbus/dbus-transport-unix.c:
416         Fix documentation warnings.
417         
418 2003-03-26  Havoc Pennington  <hp@pobox.com>
419
420         * bus/test-main.c, dbus/dbus-test.c (main): check memleaks
421         after every test so it's quick and easy to see which leaked, and
422         so we test multiple dbus_shutdown() calls
423
424         * configure.in: change configure.in XML stuff to also support
425         expat
426
427         * config-loader-libxml.c: some hacking
428
429         * config-loader-expat.c: some hacking
430
431         * config-parser.c: some hacking, plus tests
432
433 2003-03-25  Havoc Pennington  <hp@redhat.com>
434
435         * throughout - add more _DBUS_ASSERT_ERROR_IS_CLEAR
436         
437         * configure.in: add --with-xml option to specify XML library,
438         right now only libxml is supported.
439
440         * bus/config-loader-libxml.c, config-parser.c: sync some minor 
441         nonworking code between home and work, still just stubs
442
443 2003-03-24  Havoc Pennington  <hp@redhat.com>
444
445         * dbus/dbus-sysdeps.c (_dbus_set_fd_nonblocking): move to this
446         file
447
448         * dbus/dbus-errors.c (dbus_set_error, dbus_set_error_const): allow 
449         NULL argument for "message" if the error is a well-known one, 
450         fill in a generic message in this case.
451
452         * dbus/dbus-errors.h (DBusResultCode): Kill DBusResultCode in
453         favor of DBusError
454
455         * bus/test.c (bus_test_flush_bus): add
456
457         * bus/policy.c (bus_policy_test): test code stub
458
459 2003-03-24  Havoc Pennington  <hp@pobox.com>
460
461         * bus/connection.c (bus_connections_setup_connection): set up 
462         the "can this user connect" function, but it always returns 
463         TRUE until we have a config file parser so we can have a config
464         file that allows connections.
465
466 2003-03-23  Havoc Pennington  <hp@pobox.com>
467
468         * dbus/dbus-threads.c (dbus_mutex_new, dbus_condvar_new): with 
469         DBUS_BUILD_TESTS, actually alloc/free a block of memory for 
470         the mutex, so we can check for proper memory management 
471         and OOM handling.
472
473         * dbus/dbus-dataslot.c: remove the mutex from
474         DBusDataSlotAllocator and lock it manually when using it, 
475         to simplify fitting it into the global slots framework.
476
477         * dbus/dbus-threads.c (init_static_locks): rework how we're
478         handling global locks so they are easily shut down.
479
480         * bus/policy.c (bus_policy_append_rule): fix
481
482         * bus/test-main.c (main): check for memleaks
483
484         * dbus/dbus-test.c (dbus_internal_do_not_use_run_tests): make 
485         test suite check for memleaks
486
487         * dbus/dbus-memory.c: add support in test mode for tracking 
488         number of outstanding blocks
489
490 2003-03-23  Havoc Pennington  <hp@pobox.com>
491
492         * bus/policy.c, bus/bus.c, bus/connection.c: implement allow/deny
493         policies code
494         
495         * dbus/dbus-hash.h: add ULONG hash keys
496
497         * dbus/dbus-sysdeps.c (_dbus_get_groups): new
498         (_dbus_get_group_id): new function
499
500 2003-03-20  Havoc Pennington  <hp@redhat.com>
501
502         * dbus/dbus-connection.c (dbus_connection_set_unix_user_function):
503         new function
504         (dbus_connection_get_unix_user): new function
505
506 2003-03-20  Havoc Pennington  <hp@pobox.com>
507
508         * bus/connection.c (bus_connection_send_oom_error): assert that
509         message has a sender
510         (connection_execute_transaction): ditto
511         (bus_connection_preallocate_oom_error): fix to set the sender, and
512         set recipient to the destination service, not the bus driver
513
514         * bus/policy.c: hacking
515
516         * dbus/dbus-message.c (dbus_message_service_is): new function
517         (dbus_message_sender_is): new
518
519 2003-03-19  Havoc Pennington  <hp@redhat.com>
520
521         * bus/policy.c: start sketching code for policy restrictions on 
522         what connections can do.
523
524 2003-03-18  Havoc Pennington  <hp@redhat.com>
525
526         * doc/TODO: some notes on high-level todo items. Little nitpick
527         stuff is all in @todo, so no need to add it here.
528
529         * doc/config-file.txt: some notes on how config file might look
530
531 2003-03-18  Anders Carlsson  <andersca@codefactory.se>
532
533         * configure.in: 0.6
534
535         * NEWS: Update.
536         
537 2003-03-17  Havoc Pennington  <hp@redhat.com>
538
539         * dbus/dbus-internals.h: add gcc attributes so that 
540         our printf-style functions warn on bad arguments to 
541         format
542         
543         * dbus/dbus-sysdeps.c (_dbus_connect_tcp_socket): fix printf 
544         format bug
545
546         * dbus/dbus-message.c (_dbus_message_loader_queue_messages): fix
547         printf format bug
548
549 2003-03-17  Havoc Pennington  <hp@redhat.com>
550
551         * bus/test-main.c (main): make it print something as it runs 
552         so make check doesn't look stuck
553
554         * doc/negotiation.txt, doc/dbus-sasl-profile.txt: remove 
555         from CVS, now obsolete
556
557 2003-03-17  Anders Carlsson  <andersca@codefactory.se>
558
559         * bus/dispatch.c: (bus_dispatch):
560         Refetch the service name since it may have been reallocated
561         when dbus_message_set_sender was called.
562         
563         * dbus/dbus-sysdeps.c: (_dbus_accept):
564         Add address and address length variables and use them to stop
565         valgrind from complaining.
566         
567 2003-03-17  Havoc Pennington  <hp@pobox.com>
568
569         All tests pass, no memleaks, no valgrind complaints.
570         
571         * bus/test.c: refcount handler_slot
572
573         * bus/connection.c (bus_connections_new): refcount
574         connection_data_slot
575
576         * dbus/dbus-auth-script.c (_dbus_auth_script_run): delete unused
577         bytes so that auth scripts pass.
578
579         * bus/dispatch.c: init message_handler_slot so it gets allocated
580         properly
581
582         * bus/dispatch.c (message_handler_slot_ref): fix memleak
583
584         * dbus/dbus-server-debug-pipe.c (_dbus_server_debug_pipe_new):
585         dealloc server_pipe_hash when no longer used for benefit of
586         leak checking
587
588         * dbus/dbus-auth.c (process_command): memleak fix
589
590         * bus/dispatch.c (check_hello_message): memleak fix
591
592 2003-03-16  Havoc Pennington  <hp@pobox.com>
593
594         * dbus/dbus-bus.c (ensure_bus_data): fix double-unref of the data slot
595
596 2003-03-17  Anders Carlsson  <andersca@codefactory.se>
597
598         * bus/activation.c (bus_activation_activate_service): Append
599         the pending activation entry to the list of pending activations.
600
601 2003-03-16  Havoc Pennington  <hp@pobox.com>
602
603         * bus/dispatch.c (bus_dispatch_test): remove double-unrefs of
604         connections
605
606         * dbus/dbus-address.c (create_entry): fix OOM handling when
607         failing to alloc entry->method
608
609 2003-03-16  Havoc Pennington  <hp@pobox.com>
610
611         * dbus/dbus-watch.c (_dbus_watch_new): handle failure to malloc
612         the watch
613
614         * dbus/dbus-server-debug-pipe.c (_dbus_transport_debug_pipe_new):
615         add some missing dbus_set_result
616
617         * bus/dispatch.c (bus_dispatch_add_connection): handle failure to 
618         alloc the DBusMessageHandler
619
620         * dbus/dbus-transport.c (_dbus_transport_disconnect): don't ref
621         the transport here, since we call this from the finalizer; it 
622         resulted in a double-finalize.
623
624         * dbus/dbus-transport.c (_dbus_transport_disconnect): fix a bug 
625         where we tried to use transport->connection that was NULL, 
626         happened when transport was disconnected early on due to OOM
627
628         * bus/*.c: adapt to handle OOM for watches/timeouts
629
630         * dbus/dbus-transport-unix.c: port to handle OOM during 
631         watch handling
632         
633         * dbus/dbus-auth.c (_dbus_auth_get_unused_bytes): return a
634         reference to unused bytes instead of a copy
635
636         * dbus/dbus-server.c (dbus_server_handle_watch): return FALSE for
637         out of memory
638
639         * dbus/dbus-connection.c (dbus_connection_handle_watch): return
640         FALSE on OOM
641
642         * dbus/dbus-timeout.c (dbus_timeout_handle): return FALSE for out
643         of memory
644
645 2003-03-16  Anders Carlsson  <andersca@codefactory.se>
646
647         * doc/dbus-specification.sgml:
648         Document reply message for ActivateService.
649         
650 2003-03-16  Anders Carlsson  <andersca@codefactory.se>
651
652         * bus/activation.c: (bus_pending_activation_entry_free),
653         (bus_pending_activation_free), (bus_activation_new),
654         (bus_activation_unref), (bus_activation_service_created),
655         (bus_activation_activate_service):
656         * bus/activation.h:
657         * bus/bus.c: (bus_context_new):
658         * bus/desktop-file.c: (new_section):
659         * bus/driver.c: (bus_driver_send_service_deleted),
660         (bus_driver_handle_activate_service):
661         * bus/services.c: (bus_registry_new), (bus_registry_ensure):
662         * bus/services.h:
663         * dbus/dbus-connection.c:
664         (dbus_connection_send_with_reply_and_block):
665         * dbus/dbus-message.c: (dbus_message_append_args_valist):
666         * dbus/dbus-protocol.h:
667         Make activation work better. Now pending activations will be queued
668         and the daemon won't try to activate services that are already registered.
669         
670 2003-03-16  Havoc Pennington  <hp@pobox.com>
671
672         * dbus/dbus-bus.c (ensure_bus_data): handle failure to set
673         connection data
674
675         * dbus/dbus-memory.c (_dbus_initialize_malloc_debug): support
676         DBUS_MALLOC_BACKTRACES to print trace when failing an alloc
677
678 2003-03-16  Havoc Pennington  <hp@pobox.com>
679
680         * dbus/dbus-string.c (_dbus_string_validate_utf8): oops, unbreak
681         this. always run the test suite before commit...
682
683         * bus/*: adapt to DBusConnection API changes
684
685         * glib/dbus-gmain.c: adapt to DBusConnection API changes, 
686         requires renaming stuff to avoid dbus_connection_dispatch name 
687         conflict.
688
689         * dbus/dbus-transport.c (_dbus_transport_queue_messages): new
690         function
691
692         * dbus/dbus-message.c (_dbus_message_loader_queue_messages):
693         separate from _dbus_message_loader_return_buffer()
694
695         * dbus/dbus-connection.c (dbus_connection_get_n_messages): remove
696         this, because it's now always broken to use; the number of
697         messages in queue vs. the number still buffered by the message
698         loader is undefined/meaningless. Should use
699         dbus_connection_get_dispatch_state().
700         (dbus_connection_dispatch): rename from
701         dbus_connection_dispatch_message
702
703 2003-03-16  Havoc Pennington  <hp@pobox.com>
704
705         * dbus/dbus-string.c (_dbus_string_validate_utf8): copy in a real
706         implementation
707
708 2003-03-16  Anders Carlsson  <andersca@codefactory.se>
709
710         * dbus/dbus-connection.c:
711         (dbus_connection_send_with_reply_and_block):
712         Decrease connection->n_incoming when removing an entry 
713         from the list.
714         * dbus/dbus-dict.c: (dbus_dict_entry_free),
715         (dbus_dict_set_boolean_array), (dbus_dict_set_int32_array),
716         (dbus_dict_set_uint32_array), (dbus_dict_set_double_array),
717         (dbus_dict_set_byte_array), (dbus_dict_set_string_array),
718         (dbus_dict_get_boolean_array), (dbus_dict_get_double_array),
719         (dbus_dict_get_byte_array):
720         Handle NULL arrays and strings. Also add support for byte arrays.
721         
722         * dbus/dbus-marshal.c: (_dbus_marshal_byte_array),
723         (_dbus_marshal_dict), (_dbus_demarshal_byte_array),
724         (_dbus_demarshal_int32_array), (_dbus_demarshal_uint32_array),
725         (_dbus_demarshal_double_array), (_dbus_demarshal_string_array),
726         (_dbus_demarshal_dict), (demarshal_and_validate_len),
727         (_dbus_marshal_validate_arg), (_dbus_marshal_test):
728         * dbus/dbus-marshal.h:
729         Add support for marshalling and demarshalling empty arrays and strings.
730         
731         * dbus/dbus-message.c: (dbus_message_append_args_valist),
732         (dbus_message_append_string_array),
733         (dbus_message_iter_get_boolean),
734         (dbus_message_iter_get_boolean_array),
735         (dbus_message_iter_get_int32_array),
736         (dbus_message_iter_get_uint32_array),
737         (dbus_message_iter_get_double_array),
738         (dbus_message_iter_get_byte_array),
739         (dbus_message_iter_get_string_array), (dbus_message_iter_get_dict),
740         (check_message_handling):
741         Add support for getting empty arrays and dicts.
742         
743         * dbus/dbus-string.c: (_dbus_string_validate_utf8):
744         Don't do any validation at all for now, that's better than just checking
745         for ASCII.
746         
747         * test/data/valid-messages/emptiness.message:
748         New test message with lots of empty arrays.
749         
750 2003-03-16  Havoc Pennington  <hp@pobox.com>
751
752         * dbus/dbus-connection.c
753         (_dbus_connection_queue_received_message_link): new function that
754         can't fail due to OOM
755
756         * dbus/dbus-message.c (_dbus_message_loader_pop_message_link):
757         new function pops a message together with a list link 
758         containing it.
759
760         * dbus/dbus-transport-unix.c (queue_messages): use new link-based
761         message queuing functions to avoid needing to alloc memory
762
763 2003-03-16  Havoc Pennington  <hp@pobox.com>
764
765         Oops - test code was only testing failure of around 30 of the
766         mallocs in the test path, but it turns out there are 500+
767         mallocs. I believe this was due to misguided linking setup such
768         that there was one copy of dbus_malloc etc. in the daemon and one
769         in the shared lib, and only daemon mallocs were tested. In any
770         case, the test case now tests all 500+ mallocs, and doesn't pass
771         yet, though there are lots of fixes in this patch.
772         
773         * dbus/dbus-connection.c (dbus_connection_dispatch_message): fix
774         this so that it doesn't need to allocate memory, since it 
775         has no way of indicating failure due to OOM (and would be 
776         annoying if it did).
777
778         * dbus/dbus-list.c (_dbus_list_pop_first_link): new function
779
780         * bus/Makefile.am: rearrange to create two self-contained
781         libraries, to avoid having libraries with overlapping symbols. 
782         that was resulting in weirdness, e.g. I'm pretty sure there 
783         were two copies of global static variables.
784
785         * dbus/dbus-internals.c: move the malloc debug stuff to 
786         dbus-memory.c
787
788         * dbus/dbus-list.c (free_link): free list mempool if it becomes
789         empty.
790
791         * dbus/dbus-memory.c (_dbus_disable_mem_pools): new function
792
793         * dbus/dbus-address.c (dbus_parse_address): free list nodes
794         on failure.
795
796         * bus/dispatch.c (bus_dispatch_add_connection): free
797         message_handler_slot when no longer using it, so 
798         memory leak checkers are happy for the test suite.
799
800         * dbus/dbus-server-debug-pipe.c (debug_finalize): free server name
801
802         * bus/bus.c (new_connection_callback): disconnect in here if 
803         bus_connections_setup_connection fails.
804
805         * bus/connection.c (bus_connections_unref): fix to free the 
806         connections
807         (bus_connections_setup_connection): if this fails, don't
808         disconnect the connection, just be sure there are no side
809         effects.
810
811         * dbus/dbus-string.c (undo_alignment): unbreak this
812
813         * dbus/dbus-auth.c (_dbus_auth_unref): free some stuff we were
814         leaking
815         (_dbus_auth_new): fix the order in which we free strings 
816         on OOM failure
817
818         * bus/connection.c (bus_connection_disconnected): fix to 
819         not send ServiceDeleted multiple times in case of memory 
820         allocation failure
821
822         * dbus/dbus-bus.c (dbus_bus_get_base_service): new function to
823         get the base service name
824         (dbus_bus_register_client): don't return base service name,
825         instead store it on the DBusConnection and have an accessor
826         function for it.
827         (dbus_bus_register_client): rename dbus_bus_register()
828
829         * bus/dispatch.c (check_hello_message): verify that other 
830         connections on the bus also got the correct results, not 
831         just the one sending hello
832
833 2003-03-15  Havoc Pennington  <hp@pobox.com>
834
835         Make it pass the Hello handling test including all OOM codepaths.
836         Now to do other messages...
837         
838         * bus/services.c (bus_service_remove_owner): fix crash when
839         removing owner from an empty list of owners
840         (bus_registry_ensure): don't leave service in the list of 
841         a connection's owned services if we fail to put the service
842         in the hash table.
843
844         * bus/connection.c (bus_connection_preallocate_oom_error): set
845         error flag on the OOM error.
846
847         * dbus/dbus-connection.c (_dbus_connection_new_for_transport):
848         handle _dbus_transport_set_connection failure
849
850         * dbus/dbus-transport-unix.c (_dbus_transport_new_for_fd): modify
851         to create watches up front and simply enable/disable them as
852         needed.
853         (unix_connection_set): this can now fail on OOM
854
855         * dbus/dbus-timeout.c, dbus/dbus-watch.c: add concept 
856         of enabling/disabling a watch or timeout.
857
858         * bus/loop.c (bus_loop_iterate): don't touch disabled
859         watches/timeouts
860
861         * glib/dbus-gmain.c: adapt to enable/disable watches and timeouts
862
863 2003-03-15  Havoc Pennington  <hp@pobox.com>
864
865         * bus/dispatch.c (bus_dispatch_test): OK, now finally actually
866         write useful test code, after all that futzing around ;-)
867
868         Test does not yet pass because we can't handle OOM in
869         _dbus_transport_messages_pending (basically,
870         dbus_connection_preallocate_send() does not prealloc the write
871         watch). To fix this, I think we need to add new stuff to
872         set_watch_functions, namely a SetEnabled function so we can alloc
873         the watch earlier, then enable it later.
874         
875         * dbus/Makefile.am (libdbus_convenience_la_SOURCES): move
876         dbus-memory.c to the convenience lib
877
878         * bus/test.c: rename some static functions to keep them clearly 
879         distinct from stuff in connection.c. Handle client disconnection.
880
881 2003-03-14  Havoc Pennington  <hp@pobox.com>
882
883         * bus/dispatch.c (bus_dispatch_test): do test using debug-pipe 
884         transport, tests more of the real codepath. Set up clients 
885         with bus_setup_debug_client.
886
887         * bus/test.c (bus_setup_debug_client): function to set up debug 
888         "clients" on the main loop
889
890         * dbus/dbus-transport.c (_dbus_transport_open): add debug-pipe 
891         support
892
893         * dbus/dbus-server.c (dbus_server_listen): add debug-pipe 
894         server type
895
896         * dbus/dbus-server-debug.c: support a debug server based on pipes
897
898         * dbus/dbus-sysdeps.c (_dbus_full_duplex_pipe): new function
899         (_dbus_close): new function
900         
901         * configure.in: check for socketpair
902
903 2003-03-14  Havoc Pennington  <hp@redhat.com>
904
905         * dbus/dbus-memory.c: add a "detect buffer overwrites on free" 
906         cheesy hack
907
908         * dbus/dbus-transport-debug.c: rework this a good bit to be 
909         less complicated. hopefully still works.
910
911         * dbus/dbus-server-debug.c (handle_new_client): remove timeout
912         manually
913
914         * glib/dbus-gmain.c (timeout_handler): don't remove timeout 
915         after running it
916
917         * dbus/dbus-message.c (dbus_message_copy): rename from 
918         dbus_message_new_from_message, fix it up to copy 
919         all the message fields, add test case
920
921         * bus/dispatch.c (bus_dispatch_test): add some more test code, 
922         not quite passing yet
923
924 2003-03-14  Havoc Pennington  <hp@pobox.com>
925
926         * bus/loop.c (bus_loop_iterate): add this so we can "run loop
927         until no work remains" in test code. (the large diff here 
928         is just code movement, no actual changes)
929
930         * dbus/dbus-server-debug.c (DEFAULT_INTERVAL): change interval to
931         1, no point waiting around for test code.
932         (_dbus_server_debug_accept_transport): unref the timeout 
933         after adding it (right?)
934
935         * dbus/dbus-transport-debug.c (DEFAULT_INTERVAL): ditto
936         
937 2003-03-13  Havoc Pennington  <hp@redhat.com>
938
939         * dbus/dbus-timeout.c (_dbus_timeout_list_set_functions): handle
940         out of memory
941
942         * dbus/dbus-watch.c (_dbus_watch_list_set_functions): handle out
943         of memory
944
945         * dbus/dbus-connection.h: Make AddWatchFunction and
946         AddTimeoutFunction return a bool so they can fail on out-of-memory
947
948         * bus/bus.c (bus_context_new): set up timeout handlers
949
950         * bus/connection.c (bus_connections_setup_connection): set up
951         timeout handlers
952
953         * glib/dbus-gmain.c: adapt to the fact that set_functions stuff
954         can fail
955
956         * bus/bus.c (bus_context_new): adapt to changes
957
958         * bus/connection.c: adapt to changes
959
960         * test/watch.c: adapt to DBusWatch changes
961
962         * bus/dispatch.c (bus_dispatch_test): started adding this but
963         didn't finish
964         
965 2003-03-14  Anders Carlsson  <andersca@codefactory.se>
966
967         * bus/dispatch.c (send_service_nonexistent_error): Fix typo.
968
969 2003-03-13  Havoc Pennington  <hp@pobox.com>
970
971         * bus/test.c, bus/test.h, bus/Makefile.am, bus/test-main.c: 
972         set up a test framework as for the library
973
974 2003-03-12  Havoc Pennington  <hp@pobox.com>
975
976         Throughout: purge global variables, introduce BusActivation, 
977         BusConnections, BusRegistry, etc. objects instead.
978         
979         * bus/bus.h, bus/bus.c: introduce BusContext as a global 
980         message bus object
981
982         * test/Makefile.am (TEST_BINARIES): disable bus-test for now, 
983         going to redo this a bit differently I think
984         
985 2003-03-12  Havoc Pennington  <hp@redhat.com>
986
987         Mega-patch that gets the message bus daemon initially handling 
988         out-of-memory. Work still needed. Also lots of random 
989         moving stuff to DBusError instead of ResultCode.
990         
991         * dbus/dbus-list.c (_dbus_list_length_is_one): new function
992
993         * dbus/dbus-connection.c
994         (dbus_connection_send_with_reply_and_block): use DBusError
995
996         * dbus/dbus-bus.c: adapt to API changes, make it use DBusError not
997         DBusResultCode
998
999         * dbus/dbus-connection.c (dbus_connection_send): drop the result
1000         code here, as the only failure possible is OOM.
1001
1002         * bus/connection.c (bus_connection_disconnect):
1003         rename bus_connection_disconnected as it's a notification only
1004
1005         * bus/driver.c (bus_driver_handle_acquire_service): don't free
1006         "name" on get_args failure, should be done by get_args; 
1007         don't disconnect client for bad args, just return an error.
1008         (bus_driver_handle_service_exists): ditto
1009
1010         * bus/services.c (bus_services_list): NULL-terminate returned array
1011
1012         * bus/driver.c (bus_driver_send_service_lost)
1013         (bus_driver_send_service_acquired): send messages from driver to a
1014         specific client to the client's unique name, not to the broadcast
1015         service.
1016
1017         * dbus/dbus-message.c (decode_header_data): reject messages that
1018         contain no name field
1019         (_dbus_message_get_client_serial): rename to
1020         dbus_message_get_serial and make public
1021         (_dbus_message_set_serial): rename from set_client_serial
1022         (_dbus_message_set_reply_serial): make public
1023         (_dbus_message_get_reply_serial): make public
1024
1025         * bus/connection.c (bus_connection_foreach): allow stopping
1026         iteration by returning FALSE from foreach function.
1027
1028         * dbus/dbus-connection.c (dbus_connection_send_preallocated) 
1029         (dbus_connection_free_preallocated_send) 
1030         (dbus_connection_preallocate_send): new API for sending a message
1031         without possibility of malloc failure.
1032         (dbus_connection_send_message): rename to just
1033         dbus_connection_send (and same for whole function family)
1034
1035         * dbus/dbus-errors.c (dbus_error_free): make this reinit the error
1036
1037         * dbus/dbus-sysdeps.c (_dbus_exit): new function
1038
1039         * bus/activation.c: handle/return errors
1040
1041         * dbus/dbus-errors.h: add more DBUS_ERROR #define
1042
1043         * dbus/dbus-sysdeps.c (_dbus_directory_open) (_dbus_file_get_contents)
1044         (_dbus_directory_get_next_file): use DBusError instead of DBusResultCode
1045         (_dbus_result_from_errno): move to this file
1046
1047 2003-03-10  Anders Carlsson  <andersca@codefactory.se>
1048
1049         * dbus/dbus-marshal.c: 
1050         (_dbus_marshal_set_string):
1051         Take a length argument so we can marshal the correct string
1052         length.
1053         
1054         (_dbus_marshal_dict), (_dbus_demarshal_dict),
1055         (_dbus_marshal_get_arg_end_pos), (_dbus_marshal_validate_arg),
1056         (_dbus_marshal_test):
1057         * dbus/dbus-marshal.h:  
1058         Add support for marshalling and demarshalling dicts.
1059         
1060         * dbus/dbus-message-builder.c: (_dbus_message_data_load):
1061         Add support for TYPE DICT.
1062         
1063         * dbus/dbus-message.c: (set_string_field):
1064         Adjust header padding.
1065         
1066         (dbus_message_append_args_valist), (dbus_message_append_dict),
1067         (dbus_message_get_args_valist), (dbus_message_iter_get_arg_type),
1068         (dbus_message_iter_get_dict), (_dbus_message_loader_return_buffer),
1069         (check_message_handling), (check_have_valid_message):
1070         * dbus/dbus-message.h:
1071         Add functions for setting and getting dicts.
1072
1073         * dbus/dbus-protocol.h:
1074         Add DBUS_TYPE_DICT.
1075         
1076         * dbus/dbus.h:
1077         Add dbus-dict.h
1078         
1079         * doc/dbus-specification.sgml:
1080         Add information about how dicts are marshalled.
1081         
1082         * test/data/invalid-messages/dict-with-nil-value.message:
1083         * test/data/invalid-messages/too-short-dict.message:
1084         * test/data/valid-messages/dict-simple.message:
1085         * test/data/valid-messages/dict.message:
1086         Add sample messages containing dicts.
1087
1088 2003-03-08  Anders Carlsson  <andersca@codefactory.se>
1089
1090         * dbus/dbus-dict.h: Add DBUS_END_DECLS.
1091
1092 2003-03-07  Anders Carlsson  <andersca@codefactory.se>
1093
1094         * dbus/Makefile.am:
1095         * dbus/dbus-dict.c: (dbus_dict_entry_free), (dbus_dict_new),
1096         (dbus_dict_get_keys), (insert_entry), (dbus_dict_set_boolean),
1097         (dbus_dict_set_int32), (dbus_dict_set_uint32),
1098         (dbus_dict_set_double), (dbus_dict_set_string),
1099         (dbus_dict_set_boolean_array), (dbus_dict_set_int32_array),
1100         (dbus_dict_set_uint32_array), (dbus_dict_set_double_array),
1101         (dbus_dict_set_string_array), (_dbus_dict_test):
1102         * dbus/dbus-dict.h:
1103         Fix according to comments from Havoc.
1104         
1105 2003-03-06  Michael Meeks  <michael@server.home>
1106
1107         * configure.in: if we don't have kde-config, disable have_qt.
1108
1109 2003-03-07  Anders Carlsson  <andersca@codefactory.se>
1110
1111         * dbus/Makefile.am:
1112         Add dbus-dict.[ch]
1113         
1114         * dbus/dbus-dict.c: (dbus_dict_entry_free), (dbus_dict_new),
1115         (dbus_dict_ref), (dbus_dict_unref), (dbus_dict_contains),
1116         (dbus_dict_remove), (dbus_dict_get_value_type),
1117         (dbus_dict_get_keys), (dbus_dict_put_boolean),
1118         (dbus_dict_put_int32), (dbus_dict_put_uint32),
1119         (dbus_dict_put_double), (dbus_dict_put_string),
1120         (dbus_dict_put_boolean_array), (dbus_dict_put_int32_array),
1121         (dbus_dict_put_uint32_array), (dbus_dict_put_double_array),
1122         (dbus_dict_put_string_array), (dbus_dict_get_boolean),
1123         (dbus_dict_get_int32), (dbus_dict_get_uint32),
1124         (dbus_dict_get_double), (dbus_dict_get_string),
1125         (dbus_dict_get_boolean_array), (dbus_dict_get_int32_array),
1126         (dbus_dict_get_uint32_array), (dbus_dict_get_double_array),
1127         (dbus_dict_get_string_array), (_dbus_dict_test):
1128         * dbus/dbus-dict.h:
1129         Add DBusDict implementation
1130         
1131         * dbus/dbus-test.c: (dbus_internal_do_not_use_run_tests):
1132         * dbus/dbus-test.h:
1133         Add _dbus_dict_test
1134         
1135 2003-03-04  Havoc Pennington  <hp@pobox.com>
1136
1137         * test/data/auth/*: adapt to changes
1138
1139         * dbus/dbus-auth-script.c (_dbus_auth_script_run): add
1140         USERID_BASE64 and change USERNAME_BASE64 to put in username not
1141         userid
1142
1143         * dbus/dbus-keyring.c (_dbus_keyring_validate_context): prevent
1144         more stuff from being in a context name, to make the protocol 
1145         simpler to deal with
1146
1147         * dbus/dbus-errors.c (dbus_error_has_name): new function
1148         (dbus_error_is_set): new function
1149
1150         * dbus/dbus-auth.c: replace DBUS_STUPID_TEST_MECH auth 
1151         with DBUS_COOKIE_SHA1, implement DBUS_COOKIE_SHA1
1152         
1153         * dbus/dbus-connection.c (dbus_connection_flush): also read
1154         messages during a flush operation
1155
1156         * dbus/Makefile.am: remove dbus-md5 since it isn't currently used.
1157
1158 2003-03-05  Anders Carlsson  <andersca@codefactory.se>
1159
1160         * configure.in: Check for gethostbyname on Solaris.
1161
1162         * dbus/dbus-transport.c: (_dbus_transport_open):
1163         Remove duplicate "tcp" entry.
1164         
1165         * doc/dbus-specification.sgml:
1166         Clarify some things.
1167         
1168 2003-03-05  Anders Carlsson  <andersca@codefactory.se>
1169
1170         * dbus/dbus-auth.c: (send_rejected), (process_test_subdir):
1171         * dbus/dbus-keyring.c: (_dbus_keyring_new_homedir),
1172         (_dbus_keyring_test):
1173         * dbus/dbus-md5.c: (_dbus_md5_compute):
1174         * dbus/dbus-sha.c: (_dbus_sha_compute):
1175         Plug memory leaks.
1176
1177 2003-03-05  Anders Carlsson  <andersca@codefactory.se>
1178
1179         * README: Add some things.
1180
1181 2003-03-04  Anders Carlsson  <andersca@codefactory.se>
1182
1183         * dbus/dbus-message.c (dbus_message_append_args_valist): Add a break;
1184         after case DBUS_TYPE_BOOELAN.
1185
1186 2003-03-02  Havoc Pennington  <hp@pobox.com>
1187
1188         * test/break-loader.c (randomly_set_extreme_ints): add test that
1189         sets really huge and small integers
1190
1191         * dbus/dbus-marshal.c (_dbus_marshal_validate_arg): add check
1192         that length of boolean array fits in the string, and that 
1193         string has room for boolean value in single-bool case.
1194
1195         * dbus/dbus-message-builder.c (_dbus_message_data_load): add
1196         optional value to "ALIGN" command which is what to fill the
1197         alignment with.
1198
1199         * test/data/valid-messages/no-padding.message: add regression
1200         test for the message padding problem
1201
1202 2003-03-02  Havoc Pennington  <hp@pobox.com>
1203
1204         * dbus/dbus-message.c (decode_header_data): fix to always init
1205         message_padding, from Benjamin Dauvergne
1206
1207 2003-03-02  Havoc Pennington  <hp@pobox.com>
1208
1209         * configure.in: 0.5
1210
1211         * NEWS: Update.
1212
1213 2003-03-01  Joe Shaw  <joe@assbarn.com>
1214
1215         * configure.in: Check for "struct cmsgcred" and try to access its
1216         members for BSD-like unices.
1217
1218         * dbus/dbus-sysdeps.c (read_credentials_byte): Fold this back into
1219         _dbus_read_credentials_unix_socket().
1220         (_dbus_read_credentials_unix_socket): Use recvmsg() instead of
1221         read() for reading the credential byte off the unix socket.  Use
1222         struct cmsgcred on systems that support it.
1223
1224 2003-02-27  Alexander Larsson  <alexl@redhat.com>
1225
1226         * glib/Makefile.am: 
1227         * configure.in:
1228         Make gthreads-2.0 dependency optional. Don't build thread test if
1229         its not found.
1230
1231 2003-02-27  Havoc Pennington  <hp@pobox.com>
1232
1233         * dbus/dbus-connection.c
1234         (dbus_connection_send_message_with_reply_and_block): fix doh!
1235         doh! doh! bug that resulted in never removing a reply from the
1236         queue, no wonder we called get_reply_serial so much ;-)
1237         
1238         * dbus/dbus-message.c (struct DBusMessage): cache reply serial
1239         and client serial instead of demarshaling them every time
1240
1241 2003-02-27  Havoc Pennington  <hp@pobox.com>
1242
1243         * dbus/dbus-marshal.c (_dbus_demarshal_int32): rewrite to be much
1244         more inlined, using dbus-string-private.h, speeds things up 
1245         substantially
1246
1247         * dbus/dbus-string.c (_dbus_string_free): apply align offset
1248         when freeing the string
1249         (_dbus_string_steal_data): fix for align offset
1250         (undo_alignment): new function
1251
1252 2003-02-26  Havoc Pennington  <hp@redhat.com>
1253
1254         All kinds of audit fixes from Owen, plus initial attempt to 
1255         handle unaligned memory returned from malloc.
1256         
1257         * dbus/dbus-string.c (_dbus_string_init): clamp max length to 
1258         leave room for align_offset and nul byte
1259         (fixup_alignment): function to track an align_offset and 
1260         ensure real->str is aligned
1261         (DBUS_GENERIC_STRING_PREAMBLE): len must be less than allocated, 
1262         to allow a nul byte plus align offset
1263         (_dbus_string_lock): fix overflow issue
1264         (_dbus_string_init_const_len): add assertions on sanity of len, 
1265         assign allocated to be ALLOCATION_PADDING larger than len
1266         (set_length): fixup the overflow handling
1267         (_dbus_string_get_data_len): fix overflow in assertion
1268         (open_gap): detect overflow in size of gap to be opened
1269         (_dbus_string_lengthen): add overflow check
1270         (_dbus_string_align_length): fix overflow with _DBUS_ALIGN_VALUE
1271         (_dbus_string_append): add overflow check
1272         (_dbus_string_append_unichar): overflow
1273         (_dbus_string_delete): fix overflow in assertion
1274         (_dbus_string_copy_len): overflow in assertion
1275         (_dbus_string_replace_len): overflows in assertions
1276         (_dbus_string_find): change to implement in terms of 
1277         _dbus_string_find_to
1278         (_dbus_string_find_to): assorted fixage
1279         (_dbus_string_equal_c_str): assert c_str != NULL, 
1280         fix logic so the function works
1281         (_dbus_string_ends_with_c_str): fix overflow thingy
1282         (_dbus_string_base64_encode): overflow fix
1283         (_dbus_string_validate_ascii): overflow
1284         (_dbus_string_validate_nul): overflow
1285         
1286 2003-02-26  Havoc Pennington  <hp@redhat.com>
1287
1288         * dbus/dbus-marshal.c (_dbus_marshal_test): fix to work with DISABLE_ASSERTS
1289
1290 2003-02-26  Alexander Larsson  <alexl@redhat.com>
1291
1292         * configure.in:
1293         Set DBUS_GLIB_THREADS_LIBS for apps using gthread-2.0
1294         
1295         * dbus/dbus-connection.c:
1296         * dbus/dbus-connection.h:
1297         Fix _dbus_connection_acquire_io_path and _dbus_connection_acquire_dispatch.
1298         Add dbus_connection_set_wakeup_main_function and use it when queueing
1299         incoming and outgoing messages.
1300         
1301         
1302         * dbus/dbus-dataslot.c:
1303         Threadsafe usage of DBusDataSlotAllocator
1304         
1305         * dbus/dbus-message.c: (dbus_message_get_args_iter):
1306         dbus_new can fail.
1307         
1308         * dbus/dbus-server-unix.c:
1309         Add todo comment
1310         
1311         * glib/dbus-gmain.c:
1312         Implement the new wakeup functions for glib.
1313         
1314         * glib/Makefile.am:
1315         * glib/test-thread-client.c: 
1316         * glib/test-thread-server.c: 
1317         * glib/test-thread.h:
1318         Initial cut at some thread test code. Not really done yet.
1319
1320 2003-02-26  Havoc Pennington  <hp@pobox.com>
1321
1322         * dbus/dbus-connection.c
1323         (dbus_connection_send_message_with_reply_and_block): fix crash
1324         where we ref'd the outgoing message instead of the returned reply
1325
1326         * dbus/dbus-transport-unix.c (do_authentication): check read watch
1327         at the end of this function, so if we didn't need to read for
1328         authentication, we reinstall it for receiving messages
1329
1330         * dbus/dbus-message.c (dbus_message_new_reply): allow replies to 
1331         a NULL sender for peer-to-peer case
1332
1333         * dbus/dbus-transport-unix.c (check_read_watch): handle
1334         !authenticated case correctly
1335
1336         * glib/dbus-gmain.c: add support for DBusServer
1337
1338         * dbus/dbus-server.c: add data slot support
1339
1340         * glib/dbus-gmain.c (dbus_connection_setup_with_g_main): check
1341         return values and handle errors
1342
1343         * dbus/dbus-dataslot.c: factor out the data slot stuff from
1344         DBusConnection
1345
1346         * Doxyfile.in (INPUT): add glib subdir
1347
1348         * glib/dbus-gmain.c (dbus_connection_setup_with_g_main): rename 
1349         setup_with_g_main instead of hookup_with_g_main; write docs
1350         
1351 2003-02-24  Anders Carlsson  <andersca@codefactory.se>
1352
1353         * dbus/dbus-marshal.c: (_dbus_marshal_validate_arg):
1354         * dbus/dbus-message-builder.c: (_dbus_message_data_load):
1355         * dbus/dbus-message.c: (dbus_message_append_boolean),
1356         (dbus_message_append_boolean_array),
1357         (dbus_message_get_args_valist), (_dbus_message_test):
1358         * dbus/dbus-message.h:
1359         * doc/dbus-specification.sgml:
1360         Various fixes as pointed out by Havoc.
1361         
1362         * test/data/invalid-messages/bad-boolean-array.message:
1363         * test/data/invalid-messages/bad-boolean.message:
1364         Add invalid boolean value test cases.
1365         
1366 2003-02-24  Anders Carlsson  <andersca@codefactory.se>
1367
1368         * dbus/dbus-internals.c: (_dbus_type_to_string):
1369         * dbus/dbus-marshal.c: (_dbus_marshal_get_arg_end_pos),
1370         (_dbus_marshal_validate_arg):
1371         * dbus/dbus-message-builder.c: (_dbus_message_data_load):
1372         * dbus/dbus-message.c: (dbus_message_append_args_valist),
1373         (dbus_message_append_boolean), (dbus_message_append_boolean_array),
1374         (dbus_message_get_args_valist), (dbus_message_iter_get_boolean),
1375         (dbus_message_iter_get_int32), (dbus_message_iter_get_uint32),
1376         (dbus_message_iter_get_double),
1377         (dbus_message_iter_get_boolean_array), (message_iter_test):
1378         * dbus/dbus-message.h:
1379         * dbus/dbus-protocol.h:
1380         * doc/dbus-specification.sgml:
1381         * test/data/valid-messages/lots-of-arguments.message:
1382         Add support for boolean and boolean array types.
1383         
1384 2003-02-23  Havoc Pennington  <hp@pobox.com>
1385
1386         * dbus/dbus-keyring.c: finish most of this implementation and 
1387         simple unit test
1388
1389         * dbus/dbus-errors.c (dbus_set_error_const, dbus_set_error): make
1390         these barf if the error isn't cleared to NULL
1391
1392         * dbus/dbus-sysdeps.c (_dbus_delete_file): set error on failure
1393         (_dbus_create_directory): new function
1394
1395         * dbus/dbus-errors.c (dbus_set_error): fix warning
1396
1397         * dbus/dbus-string.c (_dbus_string_hex_encode): new function
1398         (_dbus_string_hex_decode): new function
1399         (test_hex_roundtrip): test code
1400
1401         * dbus/dbus-sha.c (_dbus_sha_compute): use dbus_string_hex_encode
1402
1403         * dbus/dbus-md5.c (_dbus_md5_compute): use dbus_string_hex_encode
1404
1405         * dbus/dbus-sysdeps.c (_dbus_string_save_to_file): make this use 
1406         the save-to-temp/rename trick to atomically write the new file
1407         (_dbus_string_parse_uint): new function
1408
1409 2003-02-22  Havoc Pennington  <hp@pobox.com>
1410
1411         * test/Makefile.am (dist-hook): fix dist for test/data/sha-1
1412
1413 2003-02-22  Havoc Pennington  <hp@pobox.com>
1414
1415         * dbus/dbus-message.c (dbus_message_iter_get_string_array):
1416         (dbus_message_iter_get_byte_array): Fix up doxygen warnings
1417
1418         * dbus/dbus-sha.c: add implementation of SHA-1 algorithm
1419
1420         * dbus/test/data/sha-1: add US government test suite for SHA-1
1421
1422 2003-02-21  Anders Carlsson  <andersca@codefactory.se>
1423
1424         * dbus/dbus-marshal.c: (_dbus_demarshal_string_array):
1425         Make string arrays NULL-terminated.
1426         
1427         * dbus/dbus-memory.c: (dbus_free_string_array):
1428         * dbus/dbus-memory.h:
1429         New function for freeing NULL-terminated string arrays.
1430         
1431         * dbus/dbus-message-builder.c: (append_quoted_string),
1432         (_dbus_message_data_load):
1433         Add support for array types.
1434         
1435         * dbus/dbus-message.c: (check_message_handling):
1436         Add more types as test cases.
1437         
1438         * dbus/dbus-sysdeps.c: (_dbus_string_parse_int),
1439         (_dbus_string_parse_double):
1440         Add the start offset to the end offset.
1441         
1442         * test/data/valid-messages/lots-of-arguments.message:
1443         New test message with lots of arguments.
1444         
1445 2003-02-21  Anders Carlsson  <andersca@codefactory.se>
1446
1447         * dbus/dbus-message.c: (dbus_message_append_nil),
1448         (dbus_message_append_int32), (dbus_message_append_uint32),
1449         (dbus_message_append_double), (dbus_message_append_string),
1450         (dbus_message_append_int32_array),
1451         (dbus_message_append_uint32_array),
1452         (dbus_message_append_double_array),
1453         (dbus_message_append_byte_array),
1454         (dbus_message_append_string_array):
1455         Fix all out-of-memory handling in these functions.
1456
1457 2003-02-21  Anders Carlsson  <andersca@codefactory.se>
1458
1459         * dbus/dbus-message.c: (dbus_message_append_nil):
1460         Fix a silly.
1461         
1462 2003-02-21  Anders Carlsson  <andersca@codefactory.se>
1463
1464         * dbus/dbus-message.c: (dbus_message_append_args_valist),
1465         (dbus_message_append_nil), (dbus_message_append_int32_array),
1466         (dbus_message_append_uint32_array),
1467         (dbus_message_append_double_array),
1468         (dbus_message_append_byte_array),
1469         (dbus_message_append_string_array), (dbus_message_get_args_valist),
1470         (dbus_message_iter_get_int32_array),
1471         (dbus_message_iter_get_uint32_array),
1472         (dbus_message_iter_get_double_array),
1473         (dbus_message_iter_get_byte_array),
1474         (dbus_message_iter_get_string_array):
1475
1476         * dbus/dbus-message.h:
1477         Add functions for appending and getting arrays.
1478         
1479 2003-02-21  Anders Carlsson  <andersca@codefactory.se>
1480
1481         * dbus/dbus-mempool.c (_dbus_mem_pool_new): Make the
1482         element size at least 8 bytes, fixes mempool tests on
1483         64-bit machines.
1484
1485 2003-02-20  Alexander Larsson  <alexl@redhat.com>
1486
1487         * dbus/dbus-transport-unix.c (unix_do_iteration):
1488         Unlock the connection mutex during a blocking select call.
1489         Add todo about how we need a way to wake up the select.
1490
1491         * dbus/dbus-connection-internal.h: 
1492         * dbus/dbus-connection.c:
1493         Add _dbus_connection_lock and _dbus_connection_unlock.
1494
1495 2003-02-19  Havoc Pennington  <hp@pobox.com>
1496
1497         * Doxyfile.in (PREDEFINED): put DOXYGEN_SHOULD_SKIP_THIS in
1498         Doxyfile.in, not Doxyfile
1499
1500         * dbus/dbus-keyring.c: do some hacking on this
1501
1502         * dbus/dbus-sysdeps.c (_dbus_delete_file): new
1503
1504         * dbus/dbus-errors.c (dbus_set_error_const): do not call
1505         dbus_error_init
1506         (dbus_set_error): remove dbus_error_init, check for message ==
1507         NULL *before* we sprintf into it, and add @todo about including 
1508         system headers in this file
1509
1510         * dbus/dbus-sysdeps.c (_dbus_create_file_exclusively): new
1511
1512         * dbus/dbus-errors.h (DBUS_ERROR_FAILED): add
1513
1514         * dbus/dbus-sysdeps.c (get_user_info): break this function out to
1515         get various bits of user information based on either username 
1516         or user ID
1517         (_dbus_homedir_from_username): new function
1518
1519 2003-02-19  Anders Carlsson  <andersca@codefactory.se>
1520
1521         * configure.in:
1522         Add check for nonposix getpwnam_r
1523         
1524         * dbus/dbus-mempool.c: (_dbus_mem_pool_new):
1525         Align the pool element size to a sizeof (void *) boundary.
1526         
1527         * dbus/dbus-sysdeps.c: (_dbus_setenv), (_dbus_connect_unix_socket),
1528         (_dbus_listen_unix_socket), (_dbus_credentials_from_username):
1529         General Solaris fixes.
1530         
1531         * test/data/valid-messages/simplest-manual.message:
1532         Explicitly state that we want little-endian packing.
1533         
1534 2003-02-19  Mikael Hallendal  <micke@codefactory.se>
1535
1536         * dbus/dbus-server.c (dbus_server_listen): Support tcp: addresses.
1537
1538         * dbus/dbus-transport-unix.c (_dbus_transport_new_for_tcp_socket): 
1539         Added to create a transport connecting using a tcp/ip socket.
1540
1541         * dbus/dbus-sysdeps.c (_dbus_connect_tcp_socket): Added to connect
1542         to a tcp socket at given host and port.
1543         (_dbus_listen_tcp_socket): added to listen on tcp socket for given
1544         hostname and port.
1545
1546         * dbus/dbus-server.c (dbus_server_listen): Support tcp: addresses.
1547
1548         * dbus/dbus-server-unix.c (_dbus_server_new_for_tcp_socket): 
1549         Added to create a server listening on a TCP/IP socket.
1550
1551 2003-02-19  Havoc Pennington  <hp@pobox.com>
1552
1553         Throughout: mop up all the Doxygen warnings and undocumented
1554         stuff.
1555         
1556         * dbus/dbus-sysdeps.c (do_exec): do not use execvp, we don't want
1557         to search any paths.
1558
1559         * dbus/dbus-threads.c: move global mutex initializers to
1560         dbus-internals.h, multiple prototypes was confusing doxygen
1561         besides being kind of ugly
1562
1563         * Doxyfile (PREDEFINED): have Doxygen define
1564         DOXYGEN_SHOULD_SKIP_THIS so we can exclude things from 
1565         docs with #ifndef DOXYGEN_SHOULD_SKIP_THIS
1566         (do not abuse the feature! it's for stuff like the autogenerated 
1567         macros in dbus-md5.c, not just for things you don't feel like 
1568         documenting...)
1569
1570 2003-02-18  Havoc Pennington  <hp@pobox.com>
1571
1572         * dbus/dbus-string.c (_dbus_string_zero): new function
1573
1574         * dbus/dbus-md5.c: include MD5 implementation by L. Peter Deutsch,
1575         wrap it in some dbus-friendly API
1576
1577         * dbus/dbus-types.h: add 16-bit types
1578
1579 2003-02-18  Joe Shaw  <joe@assbarn.com>
1580
1581         * dbus/dbus-auth.c (handle_server_data_stupid_test_mech): Just get
1582         credentials from our currently running process.
1583         (get_word): Fix a buglet where we were copying the entire length
1584         instead of relative to our position.
1585
1586         * dbus/dbus-hash.c (_dbus_hash_test): Don't try to allocate the
1587         keys on the stack... it's 640k of data.
1588
1589         * dbus/dbus-sysdeps.c (_dbus_read_credentials_unix_socket): Always
1590         read the credentials byte off the socket, even if we don't have
1591         SO_PEERCRED.
1592         (_dbus_poll): Implement poll() using select() for systems which
1593         don't have it.
1594
1595         * glib/test-dbus-glib.c (main): Print out an error if no
1596         parameters are given.
1597
1598         * test/data/auth/fallback.auth-script: Added.  Tests that a client
1599         can fallback to a secondary auth mechanism if the first fails.
1600
1601 2003-02-18  Havoc Pennington  <hp@pobox.com>
1602
1603         * AUTHORS: add Alex
1604
1605 2003-02-17  Havoc Pennington  <hp@pobox.com>
1606
1607         * doc/dbus-specification.sgml: lots of cosmetic
1608         cleanups/rearrangement, add assorted FIXME, change DBUS_ADDRESS
1609         env variable to DBUS_BUS_ADDRESS, s/client/application/,
1610         s/server/bus/ (except in authentication section). Add a section
1611         "Message Bus Message Routing"
1612
1613 2003-02-17  Anders Carlsson  <andersca@codefactory.se.>
1614
1615         Release 0.4
1616         
1617         * NEWS: Update
1618
1619 2003-02-17  Anders Carlsson  <andersca@codefactory.se>
1620
1621         * doc/dbus-specification.sgml:
1622         Specification updates.
1623         
1624 2003-02-17  Anders Carlsson  <andersca@codefactory.se>
1625
1626         * bus/activation.c: (bus_activation_init), (child_setup),
1627         (bus_activation_activate_service):
1628         * bus/activation.h:
1629         * bus/main.c: (main):
1630         Set DBUS_ADDRESS environment variable.
1631         
1632         * dbus/dbus-errors.c: (dbus_set_error):
1633         Don't use va_copy since that's a C99 feature.
1634         
1635         * dbus/dbus-sysdeps.c: (_dbus_setenv), (do_exec),
1636         (_dbus_spawn_async):
1637         * dbus/dbus-sysdeps.h:
1638         Add child_setup_func to _dbus_spawn_async.
1639         
1640         * doc/dbus-specification.sgml:
1641         Update specification.
1642         
1643         * test/spawn-test.c: (setup_func), (main):
1644         Fix test.
1645         
1646 2003-02-17  Alexander Larsson  <alexl@redhat.com>
1647
1648         * dbus/dbus-connection.c (_dbus_connection_handler_destroyed_locked):
1649         Added todo.
1650
1651 2003-02-17  Anders Carlsson  <andersca@codefactory.se>
1652
1653         * doc/.cvsignore:
1654         * doc/Makefile.am:
1655         * doc/dbus-test-plan.sgml:
1656         Add test plan document.
1657         
1658         * test/Makefile.am:
1659         Fix distcheck.
1660         
1661 2003-02-17  Anders Carlsson  <andersca@codefactory.se>
1662
1663         * dbus/dbus-message.c: (decode_header_data),
1664         (_dbus_message_loader_return_buffer):
1665         Set the header padding amount when loading a message.
1666
1667 2003-02-16  Anders Carlsson  <andersca@codefactory.se>
1668
1669         * bus/dispatch.c: (send_one_message):
1670         Only send broadcast messages to registered connections.
1671         
1672         * dbus/dbus-message.c: (dbus_message_name_is):
1673         * dbus/dbus-message.h:
1674         New convenience function.
1675         
1676         * dbus/dbus-transport-debug.c: (do_reading):
1677         Only dispatch one message per run.
1678
1679         * test/Makefile.am:
1680         * test/bus-test.c: (new_connection_callback), (die),
1681         (test_hello_client1_handler), (test_hello_client2_handler),
1682         (test_hello_replies), (main):
1683
1684         * test/bus-test-loop.[ch]:
1685         Add these.
1686         
1687 2003-02-16  Havoc Pennington  <hp@pobox.com>
1688
1689         * dbus/dbus-connection.c (dbus_connection_dispatch_message): fix
1690         backward conditional
1691
1692 2003-02-16  Alexander Larsson  <alexl@redhat.com>
1693
1694         * dbus/dbus-connection.c:
1695         Implement sent_message_with_reply. (with_reply_and block is still
1696         busted).
1697         Made dispatch_message not lose message if OOM.
1698         
1699         * dbus/dbus-errors.h:
1700         Add NoReply error (for reply timeouts).
1701
1702 2003-02-16  Alexander Larsson  <alexl@redhat.com>
1703
1704         * dbus/dbus-hash.c (_dbus_hash_table_unref):
1705         Actually free keys and values when destroying hashtable.
1706
1707 2003-02-16  Anders Carlsson  <andersca@codefactory.se>
1708
1709         * dbus/dbus-auth.c: (client_try_next_mechanism):
1710         Plug a leak.
1711         
1712         * dbus/dbus-threads.c: (dbus_condvar_wait_timeout):
1713         Return TRUE if there's no thread implementation around.
1714         
1715         * glib/dbus-gmain.c: (free_source),
1716         (dbus_connection_hookup_with_g_main):
1717         Make sure to remove the GSource when the connection is finalized.
1718         
1719 2003-02-16  Anders Carlsson  <andersca@codefactory.se>
1720
1721         * bus/dispatch.c: (bus_dispatch_message_handler):
1722         * dbus/dbus-errors.h:
1723         Return an error if someone tries to send a message to a service
1724         that doesn't exist.
1725         
1726 2003-02-16  Anders Carlsson  <andersca@codefactory.se>
1727
1728         * bus/activation.c: (load_directory), (bus_activation_init),
1729         (bus_activation_activate_service):
1730         * bus/activation.h:
1731         * bus/driver.c: 
1732         (bus_driver_handle_activate_service), (bus_driver_handle_message):
1733         More work on the activation handling.
1734         
1735         * dbus/dbus-errors.h:
1736         Add some error messages
1737         
1738         * dbus/dbus-message.c: (dbus_message_new_error_reply):
1739         * dbus/dbus-message.h:
1740         New function that creates an error message.
1741         
1742         * dbus/dbus-protocol.h:
1743         Add ACTIVATE_SERVER message.
1744         
1745         * dbus/dbus-server-unix.c: (unix_handle_watch),
1746         (_dbus_server_new_for_domain_socket):
1747         Call _dbus_fd_set_close_on_exec.
1748         
1749         * dbus/dbus-sysdeps.c: (make_pipe), (do_exec),
1750         (_dbus_spawn_async), (_dbus_disable_sigpipe),
1751         (_dbus_fd_set_close_on_exec):
1752         * dbus/dbus-sysdeps.h:
1753         Add _dbus_fd_set_close_on exec function. Also add function that checks
1754         that all open fds are set to close-on-exec and warns otherwise.
1755         
1756         * dbus/dbus-transport-unix.c:
1757         (_dbus_transport_new_for_domain_socket):
1758         Call _dbus_fd_set_close_on_exec.
1759
1760 2003-02-16  Havoc Pennington  <hp@pobox.com>
1761
1762         * dbus/dbus-connection.c (dbus_connection_set_change_sigpipe):
1763         allow people to avoid setting SIGPIPE to SIG_IGN
1764         (_dbus_connection_new_for_transport): disable SIGPIPE unless 
1765         we've been asked not to
1766
1767 2003-02-15  Anders Carlsson  <andersca@codefactory.se>
1768
1769         * dbus/dbus-list.c: (_dbus_list_append_link),
1770         (_dbus_list_prepend_link):
1771         * dbus/dbus-memory.c: (dbus_malloc), (dbus_malloc0),
1772         (dbus_realloc):
1773         Warning fixes.
1774
1775 2003-02-15  Anders Carlsson  <andersca@codefactory.se>
1776
1777         * bus/Makefile.am:
1778         * bus/activation.c: (bus_activation_entry_free),
1779         (add_desktop_file_entry), (load_directory), (bus_activation_init):
1780         * bus/activation.h:
1781         * bus/main.c: (main):
1782         Add simple activation support, doesn't work yet though.
1783
1784 2003-02-15   Zack Rusin  <zack@kde.org>
1785
1786         * qt/dbus-qthread.cpp:  small casting fix
1787
1788 2003-02-15  Anders Carlsson  <andersca@codefactory.se>
1789
1790         * dbus/dbus-errors.c: (dbus_set_error):
1791         * dbus/dbus-errors.h:
1792         Add a few errors and make dbus_set_error void.
1793         
1794         * dbus/dbus-sysdeps.c: 
1795         (_dbus_errno_to_string), (close_and_invalidate), (make_pipe),
1796         (write_err_and_exit), (read_ints), (do_exec), (_dbus_spawn_async):
1797         * dbus/dbus-sysdeps.h:
1798         Add _dbus_spawn_async.
1799         
1800         * test/spawn-test.c: (main):
1801         Test for _dbus_spawn_async.
1802         
1803 2003-02-15  Anders Carlsson  <andersca@codefactory.se>
1804
1805         * dbus/dbus-internals.h:
1806         Fix build without tests.
1807         
1808         * dbus/dbus-list.c: (alloc_link):
1809         Fix a segfault when a malloc fails.
1810         
1811         * dbus/dbus-memory.c: (initialize_malloc_debug), (dbus_malloc),
1812         (dbus_malloc0), (dbus_realloc):
1813         Add support for malloc debugging.
1814
1815 2003-02-15  Alexander Larsson  <alexl@redhat.com>
1816
1817         * dbus/dbus-threads.c:
1818         * dbus/dbus-threads.h:
1819         Add condvars. Remove static mutext from API.
1820         Implement static mutexes by initializing them from threads_init.
1821         
1822         * glib/dbus-gthread.c:
1823         * qt/dbus-qthread.cpp:
1824         Update with the thread api changes.
1825
1826                 
1827         * dbus/dbus-list.c:
1828         * dbus/dbus-list.h:
1829         Turn StaticMutex into normal mutex + init function.
1830         Export new functions _dbus_list_alloc_link, _dbus_list_free_link,
1831         _dbus_list_append_link, _dbus_list_prepend_link
1832
1833
1834         * dbus/dbus-sysdeps.c: 
1835         * dbus/dbus-sysdeps.h:
1836         New type dbus_atomic_t, and new functions _dbus_atomic_inc,
1837         _dbus_atomic_dec. Only slow fallback implementation at the moment.
1838         
1839         * dbus/dbus-protocol.h:
1840         Add DBUS_MESSAGE_LOCAL_DISCONNECT define
1841         
1842         * dbus/dbus-message.c:
1843         Make ref/unref atomic.
1844         Fix some docs.
1845         
1846         * dbus/dbus-connection-internal.h:
1847         * dbus/dbus-connection.c:
1848         * dbus/dbus-connection.h:
1849         Make threadsafe.
1850         Change _peek to _borrow,_return & _steal_borrowed.
1851         Change disconnect callback to event.
1852         Make dbus_connection_dispatch_messages reentrant.
1853         
1854         * dbus/dbus-transport.c:
1855         Don't ref the connection on calls to the transport
1856         implementation.
1857         
1858         * dbus/dbus-message-handler.c:
1859         Make threadsafe.
1860         
1861         * glib/dbus-gmain.c:
1862         Don't use peek_message anymore
1863         
1864         * test/Makefile.am:
1865         * test/debug-thread.c:
1866         * test/debug-thread.h:
1867         Simple thread implementation that asserts() on deadlocks in
1868         single-threaded code.
1869         
1870         * test/bus-test.c:
1871         (main) Call debug_threads_init.
1872
1873         * test/watch.c:
1874         Use disconnect message instead of disconnect callback.
1875
1876         * bus/connection.c:
1877         * bus/connection.h:
1878         Don't call dbus_connection_set_disconnect_function. Instead export
1879         bus_connection_disconnect.
1880         
1881         * bus/dispatch.c:
1882         Call bus_connection_disconnect when we get a disconnected message.
1883         
1884 2003-02-15  Havoc Pennington  <hp@pobox.com>
1885
1886         * dbus/dbus-message.c (dbus_message_new): fool around with the
1887         docs
1888
1889 2003-02-14  Havoc Pennington  <hp@pobox.com>
1890
1891         * dbus/dbus-mempool.c: fail if the debug functions so indicate
1892
1893         * dbus/dbus-memory.c: fail if the debug functions indicate we
1894         should
1895
1896         * dbus/dbus-internals.c (_dbus_set_fail_alloc_counter)
1897         (_dbus_decrement_fail_alloc_counter): debug functions to 
1898         simulate memory allocation failures
1899
1900 2003-02-14  Havoc Pennington  <hp@pobox.com>
1901
1902         * dbus/dbus-errors.h (struct DBusError): add a word of padding 
1903         to DBusError
1904
1905 2003-02-13  Anders Carlsson  <andersca@codefactory.se>
1906
1907         * bus/driver.c: (bus_driver_handle_hello):
1908         * bus/driver.h:
1909         * bus/services.c: (bus_service_lookup):
1910         Reorder message sending so we get a more sane order.
1911         
1912         * test/bus-test.c: (message_handler):
1913         Fix tyop.
1914         
1915 2003-02-13  Anders Carlsson  <andersca@codefactory.se>
1916
1917         * bus/driver.c: (bus_driver_send_service_deleted),
1918         (bus_driver_send_service_created), (bus_driver_send_service_lost),
1919         (bus_driver_send_service_acquired), (bus_driver_handle_hello),
1920         (bus_driver_send_welcome_message),
1921         (bus_driver_handle_list_services),
1922         (bus_driver_handle_acquire_service),
1923         (bus_driver_handle_service_exists):
1924         * dbus/dbus-bus.c: (dbus_bus_register_client),
1925         (dbus_bus_acquire_service), (dbus_bus_service_exists):
1926         * dbus/dbus-errors.c: (dbus_result_to_string):
1927         * dbus/dbus-errors.h:
1928         * dbus/dbus-message.c: (dbus_message_append_args),
1929         (dbus_message_append_args_valist), (dbus_message_get_args),
1930         (dbus_message_get_args_valist), (dbus_message_get_args_iter),
1931         (dbus_message_iter_get_arg_type), (dbus_message_iter_get_string),
1932         (dbus_message_iter_get_byte_array),
1933         (dbus_message_iter_get_string_array), (message_iter_test),
1934         (check_message_handling), (_dbus_message_test):
1935         * dbus/dbus-message.h:
1936         * test/bus-test.c: (main):
1937         Change fields to arguments in messages, so that they won't be
1938         confused with header fields.
1939         
1940         * glib/test-dbus-glib.c: (main):
1941         Remove append_fields from hello message.
1942         
1943 2003-02-13  Anders Carlsson  <andersca@codefactory.se>
1944
1945         * dbus/dbus-errors.c:
1946         * dbus/dbus-message.c:
1947         * dbus/dbus-string.c:
1948         Documentation fixes.
1949
1950 2003-02-13  Anders Carlsson  <andersca@codefactory.se>
1951
1952         * glib/dbus-gmain.c: (timeout_handler), (add_timeout),
1953         (remove_timeout):
1954         Implement support for timeouts in dbus-glib.
1955         
1956 2003-02-13  Anders Carlsson  <andersca@codefactory.se>
1957
1958         * dbus/dbus-message-builder.c: (_dbus_message_data_load):
1959         * dbus/dbus-message.c: (process_test_subdir):
1960         * test/break-loader.c: (find_breaks_based_on):
1961         Plug some memory leaks.
1962         
1963 2003-02-13  Richard Hult  <rhult@codefactory.se>
1964
1965         * bus/main.c: Fix build.
1966
1967         * dbus/dbus-errors.h: 
1968         * dbus/dbus-errors.c: Fix copyright for Anders.
1969
1970 2003-02-13  Anders Carlsson  <andersca@codefactory.se>
1971
1972         * bus/Makefile.am:
1973         Add utils.[ch]
1974         
1975         * bus/connection.c: (bus_connection_foreach):
1976         Fix a warning.
1977         
1978         * bus/desktop-file.c: (grow_lines_in_section), (grow_sections),
1979         (unescape_string), (new_section), (parse_section_start),
1980         (parse_key_value), (report_error), (bus_desktop_file_load),
1981         (bus_desktop_file_get_string):
1982         * bus/desktop-file.h:
1983         Use DBusError for error reporting.
1984         
1985         * bus/dispatch.c: (send_one_message),
1986         (bus_dispatch_message_handler):
1987         * bus/driver.c: (bus_driver_send_service_deleted),
1988         (bus_driver_send_service_created), (bus_driver_send_service_lost),
1989         (bus_driver_send_service_acquired), (bus_driver_handle_hello),
1990         (bus_driver_send_welcome_message),
1991         (bus_driver_handle_list_services),
1992         (bus_driver_handle_acquire_service),
1993         (bus_driver_handle_service_exists):
1994         * bus/loop.c: (bus_loop_run):
1995         * bus/main.c:
1996         Use BUS_HANDLE_OOM instead of _DBUS_HANDLE_OOM.
1997         
1998         * bus/utils.c: (bus_wait_for_memory):
1999         * bus/utils.h:
2000         New files with general utility functions.
2001         
2002         * dbus/dbus-internals.h:
2003         Remove _DBUS_HANDLE_OOM.
2004         
2005 2003-02-13  Anders Carlsson  <andersca@codefactory.se>
2006
2007         * dbus/dbus-errors.c: (dbus_result_to_string), (dbus_error_init),
2008         (dbus_error_free), (dbus_set_error_const), (dbus_set_error):
2009         * dbus/dbus-errors.h:
2010         Add DBusError structure.
2011         
2012 2003-02-13  Anders Carlsson  <andersca@codefactory.se>
2013
2014         * test/data/valid-messages/standard-acquire-service.message:
2015         * test/data/valid-messages/standard-hello.message:
2016         * test/data/valid-messages/standard-list-services.message:
2017         * test/data/valid-messages/standard-service-exists.message:
2018         Add some standard messages.
2019         
2020 2003-02-13  Anders Carlsson  <andersca@codefactory.se>
2021
2022         * bus/driver.c: (bus_driver_send_welcome_message),
2023         (bus_driver_handle_list_services),
2024         (bus_driver_handle_acquire_service),
2025         (bus_driver_handle_service_exists), (bus_driver_handle_message):
2026         Update for API changes in libdbus.
2027         
2028         * dbus/dbus-message.c: (dbus_message_new_reply):
2029         * dbus/dbus-message.h:
2030         Remove the name argument. The spec states that replies shouldn't
2031         have a name.
2032
2033 2003-02-13  Anders Carlsson  <andersca@codefactory.se>
2034
2035         * bus/desktop-file.c: (parse_section_start), (parse_key_value),
2036         (report_error), (bus_desktop_file_load), (lookup_section),
2037         (lookup_line), (bus_desktop_file_get_raw),
2038         (bus_desktop_file_get_string):
2039         * bus/desktop-file.h:
2040         Some fixes, and new functions for getting a key value from a section.
2041         
2042 2003-02-13  Havoc Pennington  <hp@pobox.com>
2043
2044         * test/data/auth/fail-after-n-attempts.auth-script: new test
2045
2046         * dbus/dbus-auth.c (send_rejected): shutdown_mech() when we
2047         reject the client.
2048
2049 2003-02-13  Havoc Pennington  <hp@pobox.com>
2050
2051         * dbus/dbus-auth.c (handle_server_data_external_mech): args to
2052         dbus_credentials_match were backward
2053
2054         * dbus/dbus-auth-script.c (_dbus_auth_script_run): support
2055         NO_CREDENTIALS and ROOT_CREDENTIALS
2056
2057         * dbus/dbus-auth.c (_dbus_auth_do_work): move get_state() routine 
2058         into here. Never process more commands after we've reached an 
2059         end state; store further data as unused bytes.
2060
2061         * test/data/auth/*: add more auth tests
2062         
2063         * dbus/dbus-auth-script.c (_dbus_auth_script_run): support EXPECT
2064         command to match exact string and EXPECT_UNUSED to match unused
2065         bytes
2066
2067         * test/Makefile.am (dist-hook): fix to dist all the test stuff
2068
2069 2003-02-12  Havoc Pennington  <hp@pobox.com>
2070
2071         * dbus/dbus-string.c (_dbus_string_pop_line): fix to also strip
2072         \r off of popped lines
2073
2074         * dbus/dbus-auth.c (_dbus_auth_test): write code to run auth
2075         scripts
2076
2077         * dbus/dbus-auth-script.c (_dbus_auth_script_run): when doing a
2078         SEND, append \r\n
2079
2080 2003-02-12  Havoc Pennington  <hp@pobox.com>
2081
2082         * dbus/Makefile.am: remove break-loader from the build, since it
2083         moved.
2084
2085         * configure.in: add --enable-gcov to turn on coverage profiling
2086         flags and disable optimization
2087
2088 2003-02-10  Havoc Pennington  <hp@pobox.com>
2089
2090         * dbus/dbus-auth-script.c, dbus/dbus-auth-script.h: sync 
2091         initial cut at test framework for DBusAuth from laptop.
2092         Doesn't quite work yet but it compiles and I need to get 
2093         it off the 266mhz laptop. ;-)
2094         
2095         * dbus/dbus-server-debug.c (_dbus_server_debug_accept_transport):
2096         fix a memleak in error case
2097
2098 2003-02-12  Anders Carlsson  <andersca@codefactory.se>
2099
2100         * bus/Makefile.am:
2101         * bus/desktop-file.c:
2102         * bus/desktop-file.h:
2103         Add a desktop file parser.
2104
2105 2003-02-11  Zack Rusin  <zack@kde.org>
2106
2107         * qt/message.[h|cpp]: sample implementation
2108         of the KDE wrapper for DBusMessage
2109
2110 2003-02-09  Zack Rusin  <zack@kde.org>
2111
2112         * test/bus-test.c: make_it_compile
2113         * doc/dbus-specification.sgml: minimal semantic fix
2114
2115 2003-02-06  Anders Carlsson  <andersca@codefactory.se>
2116
2117         Release 0.3
2118         
2119         * NEWS: Update
2120
2121 2003-02-06  Anders Carlsson  <andersca@codefactory.se>
2122
2123         * dbus/Makefile.am:
2124         * dbus/dbus-break-loader.c:
2125         * test/Makefile.am:
2126         * test/break-loader.c:
2127         Move dbus-break-loader to test/ and rename it to break-loader.
2128
2129 2003-02-02  Havoc Pennington  <hp@pobox.com>
2130
2131         * dbus/dbus-keyring.c, dbus/dbus-keyring.h: template files 
2132         for code to manage cookies in your home directory
2133
2134         * dbus/dbus-sysdeps.c (_dbus_generate_random_bytes): new function
2135
2136         * dbus/dbus-auth.c (get_state): impose a maximum number of tries
2137         to authenticate, then disconnect the client.
2138
2139 2003-02-03  Alexander Larsson  <alexl@redhat.com>
2140
2141         * dbus/dbus-message.c (dbus_message_append_fields):
2142         Correct docs.
2143
2144 2003-02-02  Anders Carlsson  <andersca@codefactory.se>
2145
2146         * doc/dbus-specification.sgml:
2147         Update address format section.
2148         
2149 2003-02-02  Anders Carlsson  <andersca@codefactory.se>
2150
2151         * test/Makefile.am:
2152         * test/bus-test.c: (get_time), (add_timeout), (remove_timeout),
2153         (message_handler), (new_connection_callback), (loop_quit),
2154         (loop_run), (main):
2155         Add bus test.
2156         
2157 2003-02-02  Anders Carlsson  <andersca@codefactory.se>
2158
2159         * bus/driver.c: (bus_driver_handle_service_exists):
2160         Simplify the code a bit.
2161         
2162         * dbus/dbus-bus.c: (dbus_bus_service_exists):
2163         Fix a silly. 
2164         
2165 2003-02-02  Anders Carlsson  <andersca@codefactory.se>
2166
2167         * bus/Makefile.am:
2168         Add libdbus-daemon.la and link to it.
2169
2170 2003-02-01  James Willcox  <jwillcox@gnome.org>
2171
2172         * bus/driver.c: (bus_driver_handle_own_service):
2173         Actually include the service reply code in the message.
2174
2175 2003-02-02  Anders Carlsson  <andersca@codefactory.se>
2176
2177         * bus/driver.c: (bus_driver_handle_service_exists):
2178         Don't unref the incoming message.
2179         
2180 2003-02-02  Anders Carlsson  <andersca@codefactory.se>
2181
2182         * dbus/dbus.h: Add dbus-address.h and dbus-bus.h
2183
2184 2003-02-02  Anders Carlsson  <andersca@codefactory.se>
2185
2186         * dbus/dbus-server.c: (dbus_server_listen):
2187         * dbus/dbus-transport.c: (_dbus_transport_open):
2188         ifdef out the calls to the debug transport and server.
2189         
2190 2003-02-02  Alexander Larsson  <alexl@redhat.com>
2191
2192         * dbus/dbus-watch.c (dbus_watch_get_flags):
2193         Add note in the docs that ERROR or HANGUP won't be returned
2194         and are assumed always on.
2195
2196         * glib/dbus-gmain.c (add_watch):
2197         Always add IO_ERR | IO_HUP
2198
2199         * dbus/dbus-message.h:
2200         Add semicolon after dbus_message_iter_get_string_array().
2201         Makes qt code build again
2202
2203 2003-02-01  Anders Carlsson  <andersca@codefactory.se>
2204
2205         * bus/driver.c: (create_unique_client_name),
2206         (bus_driver_handle_hello):
2207         Don't take a name, just use a numeric id to identify
2208         each client.
2209         
2210         * dbus/Makefile.am:
2211         * dbus/dbus-bus.c: (dbus_bus_register_client),
2212         (dbus_bus_acquire_service), (dbus_bus_service_exists):
2213         * dbus/dbus-bus.h:
2214         Add new convenience functions for communicating with the bus.
2215         
2216         * dbus/dbus-message.h:
2217         
2218         * dbus/dbus-protocol.h:
2219         Fix a typo.
2220         
2221 2003-02-01  Alexander Larsson  <alexl@redhat.com>
2222
2223         * dbus/dbus-message.c (dbus_message_append_fields):
2224         Add some more doc comments.
2225
2226 2003-02-01  Havoc Pennington  <hp@pobox.com>
2227
2228         * dbus/dbus-break-loader.c (randomly_modify_length): change 
2229         a 4-byte value in the message as if it were a length
2230
2231         * dbus/dbus-sysdeps.c (_dbus_string_save_to_file): don't set
2232         execute bit on saved files
2233
2234 2003-02-01  Havoc Pennington  <hp@pobox.com>
2235
2236         * dbus/dbus-break-loader.c (main): new program to find messages
2237         that break the loader.
2238
2239         * dbus/dbus-sysdeps.c (_dbus_string_append_uint): new function
2240         * dbus/dbus-sysdeps.c (_dbus_string_save_to_file): new function
2241
2242         * dbus/dbus-string.c (_dbus_string_set_byte): new
2243         
2244 2003-01-31  Havoc Pennington  <hp@pobox.com>
2245
2246         * dbus/dbus-message.c: refactor the test code to be more general, 
2247         in preparation for writing a "randomly permute test cases to 
2248         try to break the loader" program.
2249
2250 2003-01-31  Havoc Pennington  <hp@pobox.com>
2251         
2252         * doc/dbus-specification.sgml: work on the specification
2253
2254         * dbus/dbus-message.c (_dbus_message_loader_return_buffer): check 
2255         the protocol version of the message.
2256
2257         * dbus/dbus-protocol.h: drop special _REPLY names, the spec 
2258         no longer specifies that.
2259         (DBUS_SERVICE_REPLY_SERVICE_EXISTS): fix flags (1/2/4/8 not 
2260         1/2/3/4)
2261
2262         * dbus/dbus-marshal.c (_dbus_marshal_get_arg_end_pos): add missing
2263         "break" for DBUS_TYPE_NIL, remove @todo
2264
2265 2003-01-31  Havoc Pennington  <hp@pobox.com>
2266
2267         * dbus/dbus-message.c (dbus_message_set_is_error_reply): rename 
2268         just set_is_error/get_is_error as this is a commonly-used
2269         function, and write docs.
2270
2271 2003-01-31  Anders Carlsson  <andersca@codefactory.se>
2272
2273         * dbus/dbus-address.c: (dbus_address_entry_free):
2274         Free key and value lists.
2275         
2276         * dbus/dbus-internals.c: (_dbus_type_to_string):
2277         Add the types we didn't have.
2278         
2279         * dbus/dbus-marshal.c: (_dbus_marshal_get_arg_end_pos),
2280         (_dbus_marshal_validate_arg):
2281         Add NIL types.
2282         
2283         * dbus/dbus-message.c: (dbus_message_set_sender):
2284         Remove todo about being able to set sender to NULL.
2285         
2286         (dbus_message_set_is_error_reply),
2287         (dbus_message_get_is_error_reply):
2288         * dbus/dbus-message.h:
2289         New functions.
2290         
2291         * dbus/dbus-protocol.h:
2292         Add error reply flag.
2293         
2294         * test/data/valid-messages/opposite-endian.message:
2295         Add NIL type to test.
2296         
2297 2003-01-31  Havoc Pennington  <hp@pobox.com>
2298
2299         * doc/dbus-specification.sgml: fully specify the header.  Add
2300         flags and major protocol version, and change header/body len to
2301         unsigned.
2302
2303         * dbus/dbus-message-builder.c (append_saved_length): append length
2304         as uint32
2305
2306         * dbus/dbus-message.c (dbus_message_create_header): change header
2307         length and body length to unsigned. Add the new fields from the
2308         spec
2309         (_dbus_message_loader_return_buffer): unsigned header/body len
2310
2311 2003-01-30  Havoc Pennington  <hp@pobox.com>
2312
2313         * dbus/dbus-auth.c: rework to use only REJECTED, no 
2314         MECHANISMS
2315
2316         * doc/dbus-sasl-profile.txt: drop MECHANISMS and just 
2317         use REJECTED, suggested by Mark McLoughlin
2318
2319 2003-01-30  Havoc Pennington  <hp@pobox.com>
2320
2321         * dbus/dbus-server.c (dbus_server_listen): @todo about how we need
2322         a better way to report errors here. e.g.  "unix address lacks
2323         path" or something. also "no such file" when the path doesn't
2324         exist, etc.
2325
2326         * dbus/dbus-address.c (dbus_address_entries_free): add @todo about
2327         leaking list nodes
2328         (dbus_parse_address): add @todo about documenting address format, 
2329         and allowing , and ; to be escaped
2330
2331 2003-01-30  Anders Carlsson  <andersca@codefactory.se>
2332
2333         * dbus/Makefile.am:
2334         Add dbus-address.[ch]
2335         
2336         * dbus/dbus-address.c: (dbus_address_entry_free),
2337         (dbus_address_entries_free), (create_entry),
2338         (dbus_address_entry_get_method), (dbus_address_entry_get_value),
2339         (dbus_parse_address), (_dbus_address_test):
2340         * dbus/dbus-address.h:
2341         New files for dealing with address parsing.
2342         
2343         * dbus/dbus-connection.c:
2344         Document timeout functions.
2345         
2346         * dbus/dbus-message.c:
2347         Document dbus_message_new_from_message.
2348         
2349         * dbus/dbus-server-debug.c:
2350         Document.
2351         
2352         * dbus/dbus-server.c: (dbus_server_listen):
2353         Parse address and use correct server implementation.
2354         
2355         * dbus/dbus-string.c: (_dbus_string_find_to), (_dbus_string_test):
2356         * dbus/dbus-string.h:
2357         New function with test.
2358         
2359         * dbus/dbus-test.c: (dbus_internal_symbol_do_not_use_run_tests):
2360         * dbus/dbus-test.h:
2361         Add address tests.
2362         
2363         * dbus/dbus-transport-debug.c:
2364         Document.
2365         
2366         * dbus/dbus-transport.c: (_dbus_transport_open):
2367         Parse address and use correct transport implementation. 
2368
2369 2003-01-30  Havoc Pennington  <hp@pobox.com>
2370
2371         * dbus/dbus-message.c: use message->byte_order instead of 
2372         DBUS_COMPILER_BYTE_ORDER throughout.
2373         (dbus_message_create_header): pad header to align the 
2374         start of the body of the message to 8-byte boundary
2375
2376         * dbus/dbus-marshal.h: make all the demarshalers take const 
2377         DBusString arguments.
2378
2379         * dbus/dbus-message.c (_dbus_message_loader_return_buffer):
2380         validate message args here, so we don't have to do slow validation
2381         later, and so we catch bad messages as they are incoming. Also add
2382         better checks on header_len and body_len. Also fill in
2383         message->byte_order
2384
2385         * dbus/dbus-string.c (_dbus_string_validate_utf8): new (not
2386         implemented properly)
2387         (_dbus_string_validate_nul): new function to check all-nul
2388
2389         * dbus/dbus-marshal.c (_dbus_marshal_get_field_end_pos): rename 
2390         get_arg_end_pos and remove all validation
2391         (_dbus_marshal_validate_arg): actually do validation here.
2392
2393 2003-01-29  Havoc Pennington  <hp@pobox.com>
2394
2395         * dbus/dbus-message.c (check_message_handling): fix assertion
2396         failure on set_client_serial
2397
2398 2003-01-28  Havoc Pennington  <hp@pobox.com>
2399
2400         * dbus/dbus-server-debug.c: Add doc section comments
2401         
2402         * dbus/dbus-transport-debug.c: add doc section comments
2403         
2404 2003-01-28  Havoc Pennington  <hp@redhat.com>
2405
2406         * dbus/dbus-string.c (_dbus_string_base64_decode): append bytes in
2407         the reverse order from how I had it
2408         (_dbus_string_base64_encode): reverse encoding order. I was
2409         basically byteswapping everything during encoding.
2410
2411 2003-01-28  Anders Carlsson  <andersca@codefactory.se>
2412
2413         * dbus/dbus-connection-internal.h:
2414         * dbus/dbus-connection.c: (_dbus_connection_add_timeout),
2415         (_dbus_connection_remove_timeout):
2416         Add functions for adding and removing timeouts.
2417         
2418         * dbus/dbus-message.c: (dbus_message_new_from_message):
2419         Add new function that takes a message and creates an exact
2420         copy of it, but with the refcount set to 1.
2421         (check_message_handling):
2422         Fix build error.
2423         
2424         * dbus/dbus-server-protected.h:
2425         * dbus/dbus-server.c: (_dbus_server_init_base),
2426         (_dbus_server_finalize_base), (_dbus_server_add_timeout),
2427         (dbus_server_set_timeout_functions):
2428         (_dbus_server_remove_timeout):
2429         New functions so that a server can add and remove timeouts.
2430
2431         (dbus_server_listen):
2432         Add commented out call to dbus_server_debug_new.
2433
2434         * dbus/dbus-timeout.c: (_dbus_timeout_new):
2435         Actually set the handler, doh.
2436         
2437         * dbus/dbus-transport.c: (_dbus_transport_open):
2438         Add commented out call to dbus_transport_debug_client_new.
2439         
2440         * dbus/Makefile.am:
2441         Add dbus-transport-debug.[ch] and dbus-server-debug.[ch]
2442         
2443 2003-01-28  Havoc Pennington  <hp@pobox.com>
2444
2445         * dbus/dbus-message.c (check_message_handling): function to check 
2446         on the loaded message, iterates over it etc.
2447
2448 2003-01-28  Havoc Pennington  <hp@pobox.com>
2449
2450         * test/Makefile.am (dist-hook): fix make distdir
2451
2452         * dbus/Makefile.am (TESTS_ENVIRONMENT): fix make check
2453
2454 2003-01-27  Havoc Pennington  <hp@pobox.com>
2455
2456         * dbus/dbus-mempool.c (time_for_size): replace printf with 
2457         _dbus_verbose
2458
2459         * dbus/dbus-message-builder.c (_dbus_message_data_load): allow
2460         empty lines; fix the SAVE_LENGTH stuff to be
2461         START_LENGTH/END_LENGTH so it actually works; couple other 
2462         bugfixes
2463         
2464         * test/Makefile.am (dist-hook): add dist-hook for .message files
2465
2466         * dbus/dbus-string.c (DBUS_STRING_COPY_PREAMBLE): source of a copy
2467         can be constant or locked.
2468         (_dbus_string_free): allow freeing a const string as
2469         documented/intended
2470
2471         * dbus/dbus-sysdeps.c (_dbus_concat_dir_and_file): utility
2472
2473         * dbus/dbus-test-main.c (main): take an argument which is the 
2474         directory containing test data
2475
2476         * dbus/dbus-message.c (_dbus_message_test): pass a test_data_dir
2477         argument to this and load all the messages in test/data/
2478         checking that they can be loaded or not loaded as appropriate.
2479
2480 2003-01-27  Anders Carlsson  <andersca@codefactory.se>
2481
2482         * bus/dispatch.c: (bus_dispatch_message_handler):
2483         Dispatch messages sent to services.
2484         
2485         * bus/driver.c: (bus_driver_send_service_deleted),
2486         (bus_driver_send_service_created), (bus_driver_send_service_lost),
2487         (bus_driver_send_service_acquired):
2488         Add helper functions for sending service related messages.
2489
2490         (bus_driver_send_welcome_message):
2491         Send HELLO_REPLY instead of WELCOME.
2492         
2493         (bus_driver_handle_list_services):
2494         Send LIST_SERVICES_REPLY instead of SERVICES.
2495         
2496         (bus_driver_handle_own_service),
2497         (bus_driver_handle_service_exists):
2498         New message handlers.
2499         
2500         (bus_driver_handle_message):
2501         Invoke new message handlers.
2502         
2503         (bus_driver_remove_connection):
2504         Don't remove any services here since that's done automatically
2505         by bus_service_remove_owner now.
2506         
2507         * bus/driver.h:
2508         New function signatures.
2509         
2510         * bus/services.c: (bus_service_add_owner):
2511         Send ServiceAcquired message if we're the only primary owner.
2512         
2513         (bus_service_remove_owner):
2514         Send ServiceAcquired/ServiceLost messages.
2515         
2516         (bus_service_set_prohibit_replacement),
2517         (bus_service_get_prohibit_replacement):
2518         Functions for setting prohibit replacement.
2519         
2520         (bus_service_has_owner):
2521         New function that checks if a connection is in the owner queue of 
2522         a certain service.
2523         
2524         * bus/services.h:
2525         Add new function signatures.
2526         
2527         * dbus/dbus-list.c: (_dbus_list_test):
2528         Add tests for _dbus_list_remove_last and traversing the list backwards.
2529         
2530         * dbus/dbus-list.h:
2531         Fix a typo in _dbus_list_get_prev_link, if we're at the first element we can't
2532         go any further, so return NULL then.
2533         
2534         * dbus/dbus-protocol.h:
2535         Add new messages, service flags and service replies.
2536         
2537 2003-01-26  Havoc Pennington  <hp@pobox.com>
2538
2539         * dbus/dbus-message-builder.c: implement, completely untested.
2540
2541         * test/data/*: add data to be used in testing. 
2542         ".message" files are our simple loadable text format.
2543         ".message-raw" will be binary dumps of messages.
2544
2545         * dbus/dbus-string.c (_dbus_string_starts_with_c_str): new
2546
2547 2003-01-26  Havoc Pennington  <hp@pobox.com>
2548
2549         * dbus/dbus-sysdeps.c (_dbus_file_get_contents): new function
2550
2551         * dbus/dbus-errors.c (dbus_result_to_string): add
2552         file errors
2553
2554         * dbus/dbus-message-builder.c: new file, will contain code to load
2555         up messages from files. Not implemented yet.
2556
2557 2003-01-26  Havoc Pennington  <hp@pobox.com>
2558
2559         * dbus/dbus-message.c (dbus_message_set_sender): support deleting
2560         the sender by setting to NULL
2561
2562 2003-01-26  Havoc Pennington  <hp@pobox.com>
2563
2564         The unit tests pass, but otherwise untested.  If it breaks, the
2565         tests should have been better. ;-)
2566         
2567         * bus/driver.c (bus_driver_handle_hello): return if we disconnect
2568         the connection.
2569
2570         * dbus/dbus-message.c: redo everything so we maintain 
2571         message->header as the only copy of the various fields.
2572         This avoids the possibility of out-of-memory in some cases,
2573         for example dbus_message_lock() can't run out of memory anymore,
2574         and avoids extra copying. Figured I may as well go ahead and do 
2575         this since it was busted for dbus_message_lock to not return 
2576         failure on OOM, and dbus_message_write_header was totally
2577         unchecked for OOM. Also fixed some random other bugs.
2578
2579         * dbus/dbus-marshal.c (_dbus_marshal_get_field_end_pos): verify
2580         that strings are nul-terminated. Also, end_pos can be equal 
2581         to string length just not greater than, I think.
2582         (_dbus_marshal_set_int32): new function
2583         (_dbus_marshal_set_uint32): new function
2584         (_dbus_marshal_set_string): new function
2585
2586         * dbus/dbus-connection.c (_dbus_connection_new_for_transport): fix
2587         a warning, init timeout_list to NULL
2588         (dbus_connection_send_message): don't use uninitialized variable
2589         "serial"
2590
2591         * dbus/dbus-string.c (_dbus_string_replace_len): new function
2592
2593 2003-01-26  Anders Carlsson  <andersca@codefactory.se>
2594
2595         * bus/driver.c: (bus_driver_handle_hello),
2596         (bus_driver_send_welcome_message):
2597         Plug leaks
2598         
2599 2003-01-26  Anders Carlsson  <andersca@codefactory.se>
2600
2601         * dbus/dbus-auth.c: (process_auth), (_dbus_auth_unref):
2602         * dbus/dbus-connection.c: (_dbus_connection_new_for_transport),
2603         (dbus_connection_unref):
2604         * dbus/dbus-marshal.c: (_dbus_marshal_test):
2605         * dbus/dbus-message.c: (dbus_message_unref),
2606         Plug memory leaks.
2607         
2608         (dbus_message_get_fields): 
2609         Remove debugging printout.
2610
2611         (_dbus_message_loader_return_buffer):
2612         Don't store the header string.
2613         
2614         (_dbus_message_test):
2615         Plug leaks.
2616
2617 2003-01-26  Richard Hult  <rhult@codefactory.se>
2618
2619         * glib/dbus-gmain.c (dbus_connection_dispatch): Traverse a copy of
2620         the file descriptor list, since it can change under us.
2621
2622 2003-01-25  Anders Carlsson  <andersca@codefactory.se>
2623
2624         * glib/dbus-gmain.c: (dbus_connection_prepare),
2625         (dbus_connection_check), (dbus_connection_dispatch), (add_watch),
2626         (remove_watch), (dbus_connection_hookup_with_g_main):
2627         Rewrite the glib handling to use its own GSource instead of a 
2628         GIOChannel so we can catch messages put in the queue while waiting
2629         for a reply.
2630         
2631 2003-01-25  Anders Carlsson  <andersca@codefactory.se>
2632
2633         * bus/Makefile.am:
2634         * bus/connection.c: (connection_disconnect_handler),
2635         (connection_watch_callback), (bus_connection_setup):
2636         * bus/dispatch.c: (send_one_message),
2637         (bus_dispatch_broadcast_message), (bus_dispatch_message_handler),
2638         (bus_dispatch_add_connection), (bus_dispatch_remove_connection):
2639         * bus/dispatch.h:
2640         * bus/driver.c: (bus_driver_send_service_deleted),
2641         (bus_driver_send_service_created), (bus_driver_handle_hello),
2642         (bus_driver_send_welcome_message),
2643         (bus_driver_handle_list_services), (bus_driver_remove_connection),
2644         (bus_driver_handle_message):
2645         * bus/driver.h:
2646         Refactor code, put the message dispatching in its own file. Use 
2647         _DBUS_HANDLE_OOM. Also send ServiceDeleted messages when a client
2648         is disconnected.
2649         
2650 2003-01-25  Anders Carlsson  <andersca@codefactory.se>
2651
2652         * dbus/dbus-internals.h:
2653         Add _DBUS_HANDLE_OOM macro, it doesn't do anything currently.
2654         
2655         * dbus/dbus-message.c: (dbus_message_get_sender):
2656         * dbus/dbus-message.h:
2657         Implement dbus_message_get_sender.
2658         
2659         * dbus/dbus-protocol.h:
2660         Add message and service defines.
2661         
2662 2003-01-25  Anders Carlsson  <andersca@codefactory.se>
2663
2664         * dbus/dbus-connection.c: (dbus_connection_send_message):
2665         * dbus/dbus-message-internal.h:
2666         * dbus/dbus-message.c: (_dbus_message_get_client_serial),
2667         (dbus_message_write_header):
2668         Remove _dbus_messag_unlock and don't set the client serial on a 
2669         message if one already exists.
2670         
2671 2003-01-24  Havoc Pennington  <hp@pobox.com>
2672
2673         * dbus/dbus-list.c (alloc_link): put a thread lock on the global
2674         list_pool
2675
2676         * bus/driver.c (bus_driver_handle_list_services): fix a leak 
2677         on OOM
2678
2679 2003-01-25  Anders Carlsson  <andersca@codefactory.se>
2680
2681         * dbus/dbus-list.c: (alloc_link), (free_link):
2682         Use a memory pool for the links.
2683         
2684 2003-01-25  Anders Carlsson  <andersca@codefactory.se>
2685
2686         * bus/connection.c: (bus_connection_foreach):
2687         * bus/connection.h:
2688         Add new bus_connection_foreach function.
2689         
2690         * bus/driver.c: (send_one_message), (bus_driver_broadcast_message):
2691         Add function that broadcasts a message to all clients.
2692         
2693         (bus_driver_send_service_created), (bus_driver_handle_hello),
2694         (bus_driver_send_welcome_message),
2695         (bus_driver_handle_list_services), (bus_driver_message_handler):
2696         Implement functions that take care of listing services, and notifying
2697         clients when new services are created.
2698         
2699         * bus/services.c: (bus_services_list):
2700         * bus/services.h:
2701         Add new function that returns an array of strings with the currently
2702         registered services.
2703         
2704         * glib/dbus-glib.h:
2705         * glib/dbus-gmain.c:
2706         Update copyright year.
2707         
2708 2003-01-25  Anders Carlsson  <andersca@codefactory.se>
2709
2710         * dbus/dbus-connection.c: (dbus_connection_send_message):
2711         Unlock the message in case it was sent earlier.
2712         
2713         (dbus_connection_send_message_with_reply_and_block):
2714         Remove the reply message from the list.
2715         
2716         * dbus/dbus-marshal.c: (_dbus_demarshal_string_array):
2717         Set array_len and new_pos correctly.
2718         
2719         (_dbus_marshal_test):
2720         Remove debug output.
2721         
2722         * dbus/dbus-message-internal.h:
2723         * dbus/dbus-message.c: (_dbus_message_get_reply_serial):
2724         New function that returns the reply serial.
2725         
2726         (_dbus_message_unlock):
2727         New function that unlocks a message and resets its header.
2728
2729         (dbus_message_append_string_array), 
2730         (dbus_message_get_fields_valist),
2731         (dbus_message_iter_get_field_type),
2732         (dbus_message_iter_get_string_array),   
2733         (dbus_message_get_fields),      
2734         (dbus_message_append_fields_valist):
2735         Handle string arrays.
2736         
2737         (dbus_message_set_sender):
2738         Make this function public since the bus daemon needs it.
2739         
2740         (decode_header_data):
2741         Set the reply serial to -1 initially.
2742
2743         * dbus/dbus-message.h:
2744         Add dbus_message_set_sender.    
2745
2746 2003-01-24  Havoc Pennington  <hp@pobox.com>
2747
2748         * doc/dbus-specification.sgml: add some stuff
2749
2750 2003-01-22  Havoc Pennington  <hp@pobox.com>
2751
2752         * doc/dbus-specification.sgml: Start to document the protocol.
2753
2754 2003-01-22  Havoc Pennington  <hp@pobox.com>
2755
2756         * dbus/dbus-connection.c
2757         (dbus_connection_send_message_with_reply_and_block): add some @todo
2758
2759         * bus/driver.c (bus_driver_add_connection): add a FIXME about memleak
2760
2761 2003-01-21  Havoc Pennington  <hp@pobox.com>
2762
2763         (patch untested because can't compile)
2764         
2765         * bus/driver.c (create_unique_client_name): make this function
2766         never recycle client names. Also, caller should initialize 
2767         the DBusString.
2768
2769         * dbus/dbus-sysdeps.c (_dbus_get_current_time): new function
2770
2771 2003-01-21  Anders Carlsson  <andersca@codefactory.se>
2772
2773         * dbus/dbus-marshal.c: (_dbus_marshal_double),
2774         (_dbus_marshal_int32), (_dbus_marshal_uint32),
2775         (_dbus_marshal_int32_array), (_dbus_marshal_uint32_array),
2776         (_dbus_marshal_double_array), (_dbus_marshal_string_array),
2777         (_dbus_demarshal_int32_array), (_dbus_demarshal_uint32_array),
2778         (_dbus_demarshal_double_array), (_dbus_demarshal_string_array),
2779         (_dbus_marshal_get_field_end_pos), (_dbus_marshal_test):
2780         * dbus/dbus-marshal.h:
2781         * dbus/dbus-protocol.h:
2782         Add support for marshalling and demarshalling integer, double
2783         and string arrays.
2784         
2785 2003-01-21  Anders Carlsson  <andersca@codefactory.se>
2786
2787         * bus/Makefile.am:
2788         Add driver.[ch]
2789         
2790         * bus/connection.c: (connection_disconnect_handler):
2791         Remove the connection from the bus driver's list.
2792         
2793         (connection_watch_callback): Dispatch messages.
2794
2795         (free_connection_data): Free connection name.
2796         
2797         (bus_connection_setup): Add connection to the bus driver's list.
2798         (bus_connection_remove_owned_service): 
2799         (bus_connection_set_name), (bus_connection_get_name):
2800         Add functions for setting and getting the connection's name.
2801         
2802         * bus/connection.h:
2803         Add function headers.
2804         
2805         * bus/driver.c: (create_unique_client_name),
2806         (bus_driver_handle_hello_message),
2807         (bus_driver_send_welcome_message), (bus_driver_message_handler),
2808         (bus_driver_add_connection), (bus_driver_remove_connection):
2809         * bus/driver.h:
2810         * bus/main.c:
2811         * bus/services.c: (bus_service_free):
2812         * bus/services.h:
2813         New file that handles communication and registreation with the bus
2814         itself. 
2815         
2816 2003-01-21  Anders Carlsson  <andersca@codefactory.se>
2817
2818         * dbus/dbus-connection.c: (dbus_connection_send_message):
2819         Add a new client_serial parameter.
2820         
2821         (dbus_connection_send_message_with_reply):
2822         Remove a @todo since we've implemented the blocking function.
2823         
2824         (dbus_connection_send_message_with_reply_and_block):
2825         New function that sends a message and waits for a reply and
2826         then returns the reply.
2827         
2828         * dbus/dbus-connection.h:
2829         Add new functions.
2830         
2831         * dbus/dbus-errors.c: (dbus_result_to_string):
2832         * dbus/dbus-errors.h:
2833         Add new DBUS_RESULT.
2834         
2835         * dbus/dbus-message-internal.h:
2836         * dbus/dbus-message.c: (_dbus_message_get_reply_serial),
2837         (_dbus_message_set_sender), (dbus_message_write_header),
2838         (dbus_message_new_reply), (decode_header_data),
2839         (_dbus_message_loader_return_buffer), (_dbus_message_test):
2840         * dbus/dbus-message.h:
2841         Add new functions that set the reply serial and sender.
2842         Also marshal and demarshal them correctly and add test.
2843         
2844         * dbus/dbus-protocol.h:
2845         Add new DBUS_MESSAGE_TYPE_SENDER.
2846         
2847         * glib/dbus-glib.h:
2848         * glib/dbus-gmain.c: (watch_callback), (free_callback_data),
2849         (add_watch), (remove_watch), (add_timeout), (remove_timeout),
2850         (dbus_connection_hookup_with_g_main):
2851         * glib/test-dbus-glib.c: (main):
2852         Rewrite to use GIOChannel and remove the GSource crack.
2853         
2854         * test/echo-client.c: (main):
2855         * test/watch.c: (check_messages):
2856         Update for changed APIs
2857         
2858 2003-01-19  Anders Carlsson  <andersca@codefactory.se>
2859
2860         * dbus/Makefile.am: Add dbus-timeout.[cħ]
2861         
2862         * dbus/dbus-connection.c: (_dbus_connection_new_for_transport):
2863         Create a DBusTimeoutList.       
2864         (dbus_connection_set_timeout_functions): Add new function to
2865         set timeout callbacks
2866         
2867         * dbus/dbus-connection.h: Add public DBusTimeout API.
2868         
2869         * dbus/dbus-message.c: (dbus_message_get_service):
2870         * dbus/dbus-message.h:  New function.
2871
2872         * dbus/dbus-server.c: Fix small doc typo.
2873         
2874         * dbus/dbus-timeout.[ch]: New files for mainloop timeouts.
2875
2876 2003-01-19  Anders Carlsson  <andersca@codefactory.se>
2877
2878         * dbus/dbus-string.c (_dbus_string_move_len): Don't delete all
2879         of the string, just as long as specified.
2880
2881 2003-01-19  Havoc Pennington  <hp@pobox.com>
2882
2883         * dbus/dbus-connection.c (dbus_connection_get_is_authenticated):
2884         new function
2885
2886         * dbus/dbus-server.c (dbus_server_set_max_connections)
2887         (dbus_server_get_max_connections, dbus_server_get_n_connections):
2888         keep track of current number of connections, and add API for
2889         setting a max (but haven't implemented enforcing the max yet)
2890
2891 2003-01-18  Havoc Pennington  <hp@pobox.com>
2892
2893         * dbus/dbus-transport-unix.c (unix_do_iteration): only do the
2894         reading/writing if read_watch != NULL or write_watch != NULL.
2895
2896         * dbus/dbus-message.c (_dbus_message_loader_return_buffer): fix
2897         the message loader code to actually load message->header and
2898         message->body into the newly-created message.
2899
2900         * dbus/dbus-transport-unix.c (check_write_watch): fix a mem leak
2901         in OOM case
2902
2903         * dbus/dbus-connection.c (dbus_connection_set_max_message_size) 
2904         (dbus_connection_get_max_message_size) 
2905         (dbus_connection_set_max_live_messages_size) 
2906         (dbus_connection_get_max_live_messages_size): implement some
2907         resource limitation functions
2908
2909         * dbus/dbus-resources.c: new file implementing some of the
2910         resource limits stuff
2911
2912         * dbus/dbus-message.c (dbus_message_iter_get_byte_array): add
2913         missing docs, add @todo to handle OOM etc.
2914
2915         * dbus/dbus-marshal.c (_dbus_demarshal_byte_array): add missing
2916         docs
2917         
2918 2003-01-18  Havoc Pennington  <hp@pobox.com>
2919
2920         * dbus/dbus-connection.c (dbus_connection_unref): disconnect the 
2921         connection if it hasn't been already.
2922
2923         * dbus/dbus-connection.h: kill off the idea of an ErrorFunction,
2924         replace with DisconnectFunction.
2925
2926 2003-01-18  Havoc Pennington  <hp@pobox.com>
2927
2928         Building --disable-verbose-mode --disable-asserts --disable-tests
2929         cuts the library from 112K to 45K or so
2930         
2931         * configure.in: check for varargs macro support, 
2932         add --enable-verbose-mode, --enable-asserts. 
2933
2934         * dbus/dbus-internals.h (_dbus_assert): support
2935         DBUS_DISABLE_ASSERT
2936         (_dbus_verbose): support DBUS_ENABLE_VERBOSE_MODE
2937
2938 2003-01-18  Havoc Pennington  <hp@pobox.com>
2939
2940         * dbus/dbus-test.c: include config.h so that tests actually run
2941
2942         * dbus/dbus-string.c: add assertions that stuff is 8-byte aligned,
2943         so the failure mode when that assumption fails will be plenty
2944         obvious.
2945
2946 2003-01-18  Havoc Pennington  <hp@pobox.com>
2947
2948         * configure.in: default --enable-tests to $USE_MAINTAINER_MODE
2949
2950         * dbus/Makefile.am: fix it up so dubs-test-main.c is included in
2951         the distribution
2952
2953         * test/Makefile.am: don't use special variable "TESTS" for echo-*
2954         since we don't want to use those in make check
2955
2956 2003-01-15  Havoc Pennington  <hp@redhat.com>
2957
2958         Release 0.2
2959         
2960         * NEWS: update
2961
2962 2003-01-15  Havoc Pennington  <hp@redhat.com>
2963
2964         * test/Makefile.am: fix so that test source code ends up in the
2965         distribution on make distcheck
2966
2967 2003-01-15  Havoc Pennington  <hp@redhat.com>
2968
2969         Release 0.1.
2970         
2971         * NEWS: update  
2972
2973 2003-01-15  Havoc Pennington  <hp@redhat.com>
2974
2975         * dbus/dbus-test.c (dbus_internal_symbol_do_not_use_run_tests):
2976         fix build when --disable-tests
2977
2978         * Makefile.am (EXTRA_DIST): put HACKING in here
2979
2980         * HACKING: document procedure for making a tarball release.
2981
2982 2003-01-14  Anders Carlsson  <andersca@codefactory.se>
2983
2984         * bus/connection.c: (connection_error_handler),
2985         (bus_connection_setup):
2986         * bus/main.c: (main):
2987         Make sure that the DBusConnectionData struct is NULLed
2988         out to prevent a segfault.
2989         
2990         * dbus/dbus-errors.c: (dbus_result_to_string):
2991         * dbus/dbus-errors.h:
2992         * dbus/dbus-message.c: (dbus_message_get_fields),
2993         (dbus_message_get_fields_valist), (_dbus_message_test):
2994         * dbus/dbus-message.h:
2995         Make dbus_message_get_fields return a result code so we can
2996         track invalid fields as well as oom.
2997         
2998 2003-01-11  Havoc Pennington  <hp@pobox.com>
2999
3000         * configure.in: change --enable-test/--enable-ansi action-if-given
3001         to enable_foo=$enableval instead of enable_foo=yes
3002
3003 2003-01-08  Havoc Pennington  <hp@pobox.com>
3004
3005         * dbus/dbus-string.c (_dbus_string_align_length): new function
3006
3007         * dbus/dbus-test-main.c: move main() for test app here
3008         * dbus/dbus-test.c
3009         (dbus_internal_symbol_do_not_use_run_tests): we have to export a
3010         symbol to run tests, because dbus-test isn't in the main 
3011         library
3012
3013         Code review nitpicks.
3014         
3015         * dbus/dbus-message.c (dbus_message_write_header): add newlines
3016         for people with narrow emacs ;-). Assert client_serial was filled
3017         in. Assert message->name != NULL.
3018         (dbus_message_append_fields): have "first_field_type" arg separate
3019         from va list, needed for C++ binding that also uses varargs IIRC
3020         and helps with type safety
3021         (dbus_message_new): add @todo about using DBusString to store
3022         service/name internally
3023         (dbus_message_new): don't leak ->service and ->name on OOM later
3024         in the function
3025         (dbus_message_unref): free the service name
3026         (dbus_message_get_fields): same change to varargs
3027         i.e. first_field_type
3028         (_dbus_message_loader_return_buffer): assert that the message data
3029         is aligned (if not it's a bug in our code). Put in verbose griping
3030         about why we set corrupted = TRUE.
3031         (decode_header_data): add FIXME that char* is evil.  Was going to
3032         add FIXME about evil locale-specific string.h strncmp, but just
3033         switched to wacky string-as-uint32 optimization. Move check for
3034         "no room for field name" above get_const_data_len() to avoid
3035         assertion failure in get_const_data_len if we have trailing 2
3036         bytes or the like. Check for service and name fields being
3037         provided twice. Don't leak service/name on error. Require field
3038         names to be aligned to 4 bytes.
3039
3040         * dbus/dbus-marshal.c: move byte swap stuff to header
3041         (_dbus_pack_int32): uscore-prefix
3042         (_dbus_unpack_int32): uscore-prefix
3043         (_dbus_unpack_uint32): export
3044         (_dbus_demarshal_string): add @todo complaining about use of
3045         memcpy()
3046         (_dbus_marshal_get_field_end_pos): add @todo about bad error
3047         handling allowing corrupt data to go unchecked
3048
3049 2003-01-08  Havoc Pennington  <hp@redhat.com>
3050
3051         * dbus/dbus-transport-unix.c (unix_do_iteration): add read/write 
3052         to the select() as needed for authentication. (should be using
3053         _dbus_poll() not select, but for another day)
3054
3055         * dbus/dbus.h: include dbus/dbus-protocol.h
3056
3057 2003-01-08  Anders Carlsson  <andersca@codefactory.se>
3058
3059         * dbus/Makefile.am (dbusinclude_HEADERS): Install
3060         dbus-connection.h
3061
3062 2003-01-08  Anders Carlsson  <andersca@codefactory.se>
3063
3064         * dbus/dbus-internals.c: (_dbus_type_to_string):
3065         New function that returns a string describing a type.
3066         
3067         * dbus/dbus-marshal.c: (_dbus_demarshal_byte_array):
3068         * dbus/dbus-marshal.h:
3069         * dbus/dbus-message.c: (dbus_message_get_fields_valist),
3070         (dbus_message_iter_get_field_type), (dbus_message_iter_get_double),
3071         (dbus_message_iter_get_byte_array):
3072         * dbus/dbus-message.h:
3073         Add new convenience functions for appending and getting message fields.
3074         Also add demarshalling routines for byte arrays.
3075
3076 2003-01-07  Anders Carlsson  <andersca@codefactory.se>
3077
3078         * dbus/dbus-connection-internal.h:
3079         * dbus/dbus-connection.c: (_dbus_connection_new_for_transport),
3080         (_dbus_connection_get_next_client_serial),
3081         (dbus_connection_send_message):
3082         * dbus/dbus-internals.h:
3083         * dbus/dbus-marshal.c: (unpack_uint32), (dbus_unpack_int32),
3084         (dbus_pack_int32), (_dbus_marshal_double), (_dbus_marshal_int32),
3085         (_dbus_marshal_uint32), (_dbus_demarshal_double),
3086         (_dbus_demarshal_int32), (_dbus_demarshal_uint32),
3087         (_dbus_demarshal_string), (_dbus_marshal_get_field_end_pos),
3088         (_dbus_verbose_bytes), (_dbus_marshal_test):
3089         * dbus/dbus-marshal.h:
3090         * dbus/dbus-message-internal.h:
3091         * dbus/dbus-message.c: (_dbus_message_set_client_serial),
3092         (dbus_message_write_header), (_dbus_message_lock),
3093         (dbus_message_new), (dbus_message_ref), (dbus_message_unref),
3094         (dbus_message_get_name), (dbus_message_append_int32),
3095         (dbus_message_append_uint32), (dbus_message_append_double),
3096         (dbus_message_append_string), (dbus_message_append_byte_array),
3097         (dbus_message_get_fields_iter), (dbus_message_iter_ref),
3098         (dbus_message_iter_unref), (dbus_message_iter_has_next),
3099         (dbus_message_iter_next), (dbus_message_iter_get_field_type),
3100         (dbus_message_iter_get_string), (dbus_message_iter_get_int32),
3101         (dbus_message_iter_get_uint32), (dbus_message_iter_get_double),
3102         (decode_header_data), (_dbus_message_loader_return_buffer),
3103         (message_iter_test), (_dbus_message_test):
3104         * dbus/dbus-message.h:
3105         * dbus/dbus-protocol.h:
3106         * dbus/dbus-test.c: (main):
3107         * dbus/dbus-test.h:
3108         * glib/test-dbus-glib.c: (message_handler), (main):
3109         * test/echo-client.c: (main):
3110         * test/watch.c: (check_messages):
3111         Make messages sendable and receivable for real.
3112         
3113 2003-01-07  Anders Carlsson  <andersca@codefactory.se>
3114
3115         * dbus/dbus-marshal.c: (_dbus_marshal_double),
3116         (_dbus_marshal_string), (_dbus_marshal_byte_array):
3117         * dbus/dbus-message.c: (dbus_message_append_int32),
3118         (dbus_message_append_uint32), (dbus_message_append_double),
3119         (dbus_message_append_string), (dbus_message_append_byte_array):
3120         Handle OOM restoration.
3121         
3122 2003-01-07  Anders Carlsson  <andersca@codefactory.se>
3123
3124         * dbus/dbus-marshal.c: (_dbus_marshal_string),
3125         (_dbus_demarshal_string), (_dbus_marshal_test):
3126         * dbus/dbus-marshal.h:
3127         * dbus/dbus-message.c: (dbus_message_get_name),
3128         Document these functions.
3129         
3130         (dbus_message_append_int32), (dbus_message_append_uint32),
3131         (dbus_message_append_double), (dbus_message_append_string),
3132         (dbus_message_append_byte_array):
3133         * dbus/dbus-message.h:
3134         Add functions for adding message fields of different types.
3135         
3136         * dbus/dbus-protocol.h:
3137         Add the different types.
3138
3139 2003-01-05  Havoc Pennington  <hp@pobox.com>
3140
3141         * bus/connection.c: implement routines for handling connections,
3142         first thing is keeping a list of owned services on each connection
3143         and setting up watches etc.
3144
3145         * bus/services.c: implement a mapping from service names to lists
3146         of connections
3147
3148         * dbus/dbus-hash.c: add DBUS_HASH_POINTER
3149
3150         * dbus/dbus-threads.c (dbus_static_mutex_lock): add functions
3151         to use static mutexes for global data
3152
3153         * dbus/dbus-connection.c (dbus_connection_set_data): add new
3154         collection of functions to set/get application-specific data
3155         on the DBusConnection.
3156
3157 2003-01-04  Havoc Pennington  <hp@pobox.com>
3158
3159         * dbus/dbus-sysdeps.c (_dbus_sleep_milliseconds): new function
3160         (_dbus_poll): new function
3161
3162         * dbus/dbus-internals.h (_DBUS_STRUCT_OFFSET): new macro
3163         copied from GLib
3164
3165         * bus/loop.c: initial code for the daemon main loop
3166
3167 2003-01-04  Havoc Pennington  <hp@pobox.com>
3168
3169         * test/watch.c (error_handler): make it safe if the error handler 
3170         is called multiple times (if we s/error handler/disconnect
3171         handler/ we should just guarantee it's called only once)
3172
3173         * dbus/dbus-transport.c (_dbus_transport_disconnect): call the
3174         error handler on disconnect (it's quite possible we should
3175         just change the error handler to a "disconnect handler," I'm 
3176         not sure we have any other meaningful errors)
3177
3178         * configure.in: check for getpwnam_r
3179
3180         * dbus/dbus-transport.c, dbus/dbus-transport-unix.c,
3181         dbus/dbus-auth.c: add credentials support, add EXTERNAL auth
3182         mechanism as in SASL spec, using socket credentials
3183
3184         * dbus/dbus-sysdeps.c (_dbus_read_credentials_unix_socket): new function
3185         (_dbus_send_credentials_unix_socket): new function
3186
3187         * dbus/dbus-sysdeps.c (_dbus_accept_unix_socket): rename just
3188         dbus_accept()
3189         (_dbus_write): only check errno if <0 returned
3190         (_dbus_write_two): ditto
3191
3192 2003-01-02  Anders Carlsson  <andersca@codefactory.se>
3193
3194         * dbus/dbus-marshal.c: (_dbus_marshal_utf8_string),
3195         (_dbus_marshal_byte_array), (_dbus_demarshal_utf8_string),
3196         (_dbus_marshal_test):
3197         * dbus/dbus-marshal.h:
3198         Add _dbus_marshal_byte_array and rename _dbus_marshal_string
3199         to _dbus_marshal_utf8_string. Also fix some tests.
3200         
3201 2002-12-28  Harri Porten  <porten@kde.org>
3202
3203         * configure.in: added check for C++ compiler and a very cheesy
3204         check for the Qt integration
3205
3206         * Makefile.am (SUBDIRS): compile qt subdir if support is enabled
3207
3208         * qt/Makefile.am: added 
3209
3210         * qt/.cvsignore: added  
3211
3212         * qt/dbus-qthread.cc, qt/dbus-qthread.cpp: renamed former to
3213         latter, added #ifdef QT_THREAD_SUPPORT guard.
3214
3215         * dbus/Makefile.am: added missing headers for make dist
3216
3217 2002-12-28  Kristian Rietveld  <kris@gtk.org>
3218
3219         * dbus/Makefile.am: fixup export-symbols-regex.
3220
3221 2002-12-27  Anders Carlsson  <andersca@codefactory.se>
3222
3223         * acinclude.m4: Add this file and put the 
3224         PKG_CHECK_MODULE macro in it.
3225
3226 2002-12-27  Anders Carlsson  <andersca@codefactory.se>
3227
3228         * dbus/dbus-marshal.c: (_dbus_marshal_string),
3229         (_dbus_demarshal_double), (_dbus_demarshal_int32),
3230         (_dbus_demarshal_uint32), (_dbus_demarshal_string),
3231         (_dbus_marshal_test):
3232         Make the demarshalling routines align the pos argument.
3233         Add string marshalling tests and fix the obvious bugs 
3234         discovered.
3235         
3236 2002-12-26  Havoc Pennington  <hp@pobox.com>
3237
3238         * dbus/dbus-auth.c: fixes fixes fixes
3239
3240         * dbus/dbus-transport-unix.c: wire up support for
3241         encoding/decoding data on the wire
3242
3243         * dbus/dbus-auth.c (_dbus_auth_encode_data) 
3244         (_dbus_auth_decode_data): append to target string 
3245         instead of nuking it.
3246
3247 2002-12-26  Havoc Pennington  <hp@pobox.com>
3248
3249         * dbus/dbus-marshal.h (DBUS_COMPILER_BYTE_ORDER): #ifdef
3250         WORDS_BIGENDIAN then compiler byte order is DBUS_BIG_ENDIAN,
3251         doh
3252
3253         * dbus/dbus-marshal.c: Add macros to do int swapping in-place and
3254         avoid swap_bytes() overhead (ignoring possible assembly stuff for 
3255         now). Main point is because I wanted unpack_uint32 to implement
3256         _dbus_verbose_bytes
3257         (_dbus_verbose_bytes): new function
3258
3259         * dbus/dbus-string.c (_dbus_string_validate_ascii): new function
3260
3261         * dbus/dbus-message.c (_dbus_message_loader_get_is_corrupted): add
3262         mechanism to handle a corrupt message stream
3263         (_dbus_message_loader_new): fix preallocation to only prealloc, 
3264         not prelengthen
3265         
3266         * dbus/dbus-string.c (_dbus_string_skip_blank): fix this function
3267         (_dbus_string_test): enhance tests for copy/move and fix the
3268         functions
3269
3270         * dbus/dbus-transport-unix.c: Hold references in more places to 
3271         avoid reentrancy problems
3272
3273         * dbus/dbus-transport.c: ditto
3274
3275         * dbus/dbus-connection.c (dbus_connection_dispatch_message): don't
3276         leak reference count in no-message case
3277
3278         * test/watch.c (do_mainloop): handle adding/removing watches
3279         during iteration over the watches. Also, ref the connection/server
3280         stored on a watch, so we don't try to mangle a destroyed one.
3281
3282         * dbus/dbus-transport-unix.c (do_authentication): perform
3283         authentication
3284
3285         * dbus/dbus-auth.c (get_state): add a state
3286         AUTHENTICATED_WITH_UNUSED_BYTES and return it if required
3287         (_dbus_auth_get_unused_bytes): append the unused bytes
3288         to the passed in string, rather than prepend
3289
3290         * dbus/dbus-transport.c (_dbus_transport_init_base): create 
3291         the auth conversation DBusAuth
3292
3293         * dbus/dbus-transport-unix.c (_dbus_transport_new_for_fd)
3294         (_dbus_transport_new_for_domain_socket): when creating a
3295         transport, pass in whether it's a client-side or server-side
3296         transport so we know which DBusAuth to create
3297
3298 2002-12-03  Havoc Pennington  <hp@pobox.com>
3299
3300         * dbus/dbus-transport-unix.c (unix_finalize): finalize base
3301         _after_ finalizing the derived members
3302         (unix_connection_set): unref watch if we fail to add it
3303
3304         * dbus/dbus-connection.c (dbus_connection_unref): delete the
3305         transport first, so that the connection owned by the 
3306         transport will be valid as the transport finalizes.
3307
3308         * dbus/dbus-transport-unix.c (unix_finalize): free the write_watch
3309         if necessary, and remove watches from the connection.
3310         
3311         * dbus/dbus-watch.c (_dbus_watch_list_free): improve a comment
3312         
3313 2002-12-26  Anders Carlsson  <andersca@codefactory.se>
3314
3315         * dbus/dbus-marshal.c: (_dbus_marshal_string),
3316         (_dbus_demarshal_double), (_dbus_demarshal_int32),
3317         (_dbus_demarshal_uint32), (_dbus_demarshal_string),
3318         (_dbus_marshal_test):
3319         * dbus/dbus-marshal.h:
3320         Add string marshal functions and have the demarshal functions
3321         return the new position.
3322         
3323 2002-12-25  Havoc Pennington  <hp@pobox.com>
3324
3325         * doc/dbus-sasl-profile.txt: docs on the authentication protocol, 
3326         it is a simple protocol that just maps directly to SASL.
3327
3328         * dbus/dbus-auth.h, dbus/dbus-auth.c: authentication protocol
3329         initial implementation, not actually used yet.
3330         
3331         * dbus/dbus-string.c (_dbus_string_find): new function
3332         (_dbus_string_equal): new function
3333         (_dbus_string_base64_encode): new function
3334         (_dbus_string_base64_decode): new function
3335
3336 2002-12-25  Anders Carlsson  <andersca@codefactory.se>
3337
3338         * dbus/Makefile.am:
3339         * dbus/dbus-marshal.c: (swap_bytes), (_dbus_marshal_double),
3340         (_dbus_marshal_int32), (_dbus_marshal_uint32),
3341         (_dbus_demarshal_double), (_dbus_demarshal_int32),
3342         (_dbus_demarshal_uint32), (_dbus_marshal_test):
3343         * dbus/dbus-marshal.h:
3344         * dbus/dbus-protocol.h:
3345         * dbus/dbus-test.c: (main):
3346         * dbus/dbus-test.h:
3347         Add un-optimized marshalling/demarshalling routines.
3348         
3349 2002-12-25  Harri Porten  <porten@kde.org>
3350
3351         * qt/dbus-qt.h: adjusted ctor and getter to KDE/Qt conventions
3352
3353 2002-12-24  Zack Rusin  <zack@kde.org>
3354
3355         * qt/dbus-qthread.cc: adding - integrates QMutex into Dbus
3356         * qt/dbus-qt.h: skeleton with two sample implemenatation of the
3357         main loop stuff
3358
3359 2002-12-24  Havoc Pennington  <hp@pobox.com>
3360
3361         * glib/dbus-gthread.c: fix include
3362
3363         * glib/dbus-glib.h: rename DBusMessageHandler for now. 
3364         I think glib API needs to change, though, as you don't 
3365         want to use DBusMessageFunction, you want to use the 
3366         DBusMessageHandler object. Probably 
3367         dbus_connection_open_with_g_main_loop()
3368         and dbus_connection_setup_g_main_loop() or something like that
3369         (but think of better names...) that just create a connection 
3370         that has watch/timeout functions etc. already set up.
3371
3372         * dbus/dbus-connection.c
3373         (dbus_connection_send_message_with_reply): new function just to 
3374         show how the message handler helps us deal with replies.
3375
3376         * dbus/dbus-list.c (_dbus_list_remove_last): new function
3377
3378         * dbus/dbus-string.c (_dbus_string_test): free a string that
3379         wasn't
3380
3381         * dbus/dbus-hash.c: use memory pools for the hash entries
3382         (rebuild_table): be more paranoid about overflow, and 
3383         shrink table when we can
3384         (_dbus_hash_test): reduce number of sprintfs and write
3385         valid C89. Add tests for case where we grow and then 
3386         shrink the hash table.
3387
3388         * dbus/dbus-mempool.h, dbus/dbus-mempool.c: memory pools
3389
3390         * dbus/dbus-connection.c (dbus_connection_register_handler) 
3391         (dbus_connection_unregister_handler): new functions
3392
3393         * dbus/dbus-message.c (dbus_message_get_name): new
3394
3395         * dbus/dbus-list.c: fix docs typo
3396
3397         * dbus/dbus-message-handler.h, dbus/dbus-message-handler.c:
3398         an object representing a handler for messages.
3399
3400 2002-12-16  Anders Carlsson  <andersca@codefactory.se>
3401
3402         * glib/dbus-glib.h:
3403         * glib/dbus-gthread.c: (dbus_gthread_init):
3404         Don't use the gdbus prefix for public functions.
3405         
3406 2002-12-16  Anders Carlsson  <andersca@codefactory.se>
3407
3408         * Makefile.am:
3409         * configure.in:
3410         Add GLib checks and fixup .pc files
3411         
3412         * glib/Makefile.am:
3413         * glib/dbus-glib.h:
3414         * glib/dbus-gmain.c: (gdbus_connection_prepare),
3415         (gdbus_connection_check), (gdbus_connection_dispatch),
3416         (gdbus_add_connection_watch), (gdbus_remove_connection_watch),
3417         (dbus_connection_gsource_new):
3418         * glib/dbus-gthread.c: (dbus_gmutex_new), (dbus_gmutex_free),
3419         (dbus_gmutex_lock), (dbus_gmutex_unlock), (dbus_gthread_init):
3420         * glib/test-dbus-glib.c: (message_handler), (main):
3421         Add GLib support.
3422         
3423 2002-12-15  Harri Porten  <porten@kde.org>
3424
3425         * autogen.sh: check for libtoolize before attempting to use it 
3426         
3427         * dbus/dbus-transport-unix.c: include <sys/time.h> for timeval
3428         struct.
3429         
3430         * .cvsignore: ignore more stamp files
3431
3432         * dbus/dbus-watch.c (_dbus_watch_list_new): fixed doc error
3433
3434         * test/Makefile.am: added -I$(top_srcdir) to be able to compile
3435         without make install.
3436
3437 2002-12-15  Havoc Pennington  <hp@pobox.com>
3438
3439         * dbus/dbus-threads.c: add thread stubs that a higher library
3440         layer can fill in. e.g. the GLib wrapper might fill them in with
3441         GThread stuff. We still need to use this thread API to
3442         thread-safe-ize the library.
3443
3444 2002-12-12  Havoc Pennington  <hp@pobox.com>
3445
3446         * dbus/dbus-transport-unix.c, dbus/dbus-server-unix.c: use the
3447         below new interfaces and include fewer system headers.
3448
3449         * dbus/dbus-sysdeps.c (_dbus_read): new function
3450         (_dbus_write): new function
3451         (_dbus_write_two): new function
3452         (_dbus_connect_unix_socket): new function
3453         (_dbus_listen_unix_socket): new function
3454
3455         * dbus/dbus-message-internal.h: change interfaces to use
3456         DBusString
3457
3458 2002-12-11  Havoc Pennington  <hp@pobox.com>
3459
3460         * dbus/dbus-types.h: add dbus_unichar
3461
3462         * dbus/dbus-internals.c (_dbus_verbose): use _dbus_getenv
3463
3464         * dbus/dbus-connection.c (dbus_connection_send_message): return
3465         TRUE on success
3466
3467         * dbus/dbus-transport.c: include dbus-watch.h   
3468
3469         * dbus/dbus-connection.c: include dbus-message-internal.h
3470
3471         * HACKING: add file with coding guidelines stuff.
3472
3473         * dbus/dbus-string.h, dbus/dbus-string.c: Encapsulate all string
3474         handling here, for security purposes (as in vsftpd). Not actually
3475         using this class yet.
3476
3477         * dbus/dbus-sysdeps.h, dbus/dbus-sysdeps.c: Encapsulate all
3478         system/libc usage here, as in vsftpd, for ease of auditing (and
3479         should also simplify portability). Haven't actually moved all the
3480         system/libc usage into here yet.
3481         
3482 2002-11-25  Havoc Pennington  <hp@pobox.com>
3483
3484         * dbus/dbus-internals.c (_dbus_verbose): fix to not 
3485         always print the first verbose message.
3486
3487 2002-11-24  Havoc Pennington  <hp@pobox.com>
3488
3489         * test/echo-client.c, test/echo-server.c: cheesy test 
3490         clients.
3491         
3492         * configure.in (AC_CHECK_FUNCS): check for writev
3493
3494         * dbus/dbus-message.c (_dbus_message_get_network_data): new
3495         function
3496
3497         * dbus/dbus-list.c (_dbus_list_foreach): new function
3498
3499         * dbus/dbus-internals.c (_dbus_verbose): new function
3500
3501         * dbus/dbus-server.c, dbus/dbus-server.h: public object
3502         representing a server that listens for connections.
3503
3504         * dbus/.cvsignore: create
3505
3506         * dbus/dbus-errors.h, dbus/dbus-errors.c:
3507         public API for reporting errors
3508
3509         * dbus/dbus-connection.h, dbus/dbus-connection.c:
3510         public object representing a connection that 
3511         sends/receives messages. (Same object used for 
3512         both client and server.)
3513
3514         * dbus/dbus-transport.h, dbus/dbus-transport.c:
3515         Basic abstraction for different kinds of stream
3516         that we might read/write messages from.
3517
3518 2002-11-23  Havoc Pennington  <hp@pobox.com>
3519
3520         * dbus/dbus-internals.h (_DBUS_INT_MAX): add _DBUS_INT_MIN 
3521         _DBUS_INT_MAX
3522
3523         * dbus/dbus-test.c (main): add list test, and include 
3524         dbus-test.h as intended
3525
3526         * dbus/dbus-hash.c (_dbus_hash_table_remove_string) 
3527         (_dbus_hash_table_remove_int): return value indicates 
3528         whether the entry existed to remove
3529
3530         * dbus/dbus-list.c: add linked list utility class, 
3531         with docs and tests
3532
3533         * dbus/dbus-hash.c: add TODO item about shrinking the hash bucket 
3534         array sometimes.
3535
3536 2002-11-23  Havoc Pennington  <hp@pobox.com>
3537
3538         * Doxyfile.in (INCLUDE_FILE_PATTERNS): expand DBUS_BEGIN_DECLS/
3539         DBUS_END_DECLS to nothing, that should fix this once and for all
3540
3541         * Doxyfile.in (JAVADOC_AUTOBRIEF): set to YES
3542
3543         * dbus/dbus-message.c, dbus/dbus-hash.c: 
3544         add some missing @brief
3545
3546 2002-11-23  Havoc Pennington  <hp@pobox.com>
3547
3548         * dbus/dbus-message.h: put semicolons after DEBUG_BEGIN_DECLS 
3549         to avoid confusing Doxygen
3550
3551         * dbus/dbus-hash.c: @} not }@
3552
3553         * dbus/dbus-message.c (struct DBusMessage): split out 
3554         internals docs
3555
3556 2002-11-23  Havoc Pennington  <hp@pobox.com>
3557
3558         * configure.in: pile on more warning flags if using gcc
3559
3560         * Doxyfile.in (EXTRACT_STATIC): set to NO, so we don't have 
3561         to document static functions
3562
3563         * configure.in: add summary to end of configure so it 
3564         looks nice and attractive
3565
3566         * dbus/dbus-hash.c: finish implementation and write unit 
3567         tests and docs
3568
3569         * configure.in: add --enable-tests to enable unit tests
3570
3571         * dbus/dbus-test.c: test program to run unit tests 
3572         for all files in dbus/*, initially runs a test for 
3573         dbus-hash.c
3574         
3575         * dbus/dbus-internals.h: file to hold some internal utility stuff
3576
3577 2002-11-22  Havoc Pennington  <hp@redhat.com>
3578
3579         * dbus/dbus-hash.c: copy in Tcl hash table, not yet 
3580         "ported" away from Tcl
3581
3582         * dbus/dbus-types.h: header for types such as dbus_bool_t
3583
3584 2002-11-22  Havoc Pennington  <hp@redhat.com>
3585
3586         * dbus/dbus.h: fixups for doc warnings
3587
3588         * Doxyfile.in (FILE_PATTERNS): we need to scan .h to pick up 
3589         macros
3590         (QUIET): make it quiet so we can see warnings
3591
3592         * dbus/dbus-memory.c: teach D-BUS to allocate and free memory
3593
3594 2002-11-22  Havoc Pennington  <hp@redhat.com>
3595
3596         * Makefile.am: include "Doxyfile" target in all-local
3597
3598         * configure.in: generate the Doxyfile
3599
3600         * Doxyfile.in: move Doxyfile here, so we can use 
3601         configure to generate a Doxyfile with the right 
3602         version number etc.
3603
3604 2002-11-22  Havoc Pennington  <hp@redhat.com>
3605
3606         * dbus/dbus-message.c: move inline docs into .c file
3607
3608         * Doxyfile (OUTPUT_DIRECTORY): move output to doc/api
3609         so all docs are under doc/
3610         (MAN_EXTENSION): generate man pages. Use extension 
3611         ".3dbus" which matches ".3qt" on my system, 
3612         I guess this is OK, I don't know really.
3613         (FILE_PATTERNS): look for .c files not .h, makes sense
3614         for plain C I think
3615
3616 2002-11-22  Havoc Pennington  <hp@pobox.com>
3617
3618         * Makefile.am (SUBDIRS): rename subdir "server" to "bus" 
3619         because any app can be a server, and any app can be a client, 
3620         the bus is a special kind of server.
3621
3622 Thu Nov 21 23:35:31 2002  Zack Rusin  <zack@kde.org>
3623
3624         * Doxyfile : adding. Still needs Makefile rules to be generated
3625         automatically (just run "doxygen" in the toplevel dir for now to
3626         generate docs)
3627         
3628         * dbus/dbus-message.h : Adding sample docs (javadoc since
3629         resembles gtk-doc a little more)
3630
3631         * dbus/dbus.h : Adding sample docs
3632
3633 2002-11-21  Havoc Pennington  <hp@redhat.com>
3634
3635         * dbus/Makefile.am (INCLUDES): define DBUS_COMPILATION 
3636         so we can allow ourselves to include files directly, 
3637         instead of having to use dbus.h
3638
3639         * dbus/dbus.h: fill in
3640
3641         * dbus/dbus-message.h: sketch out a sample header file.
3642         Include griping if you include it directly instead of 
3643         via dbus.h
3644
3645         * dbus/dbus-macros.h: new file with macros for extern "C", 
3646         TRUE/FALSE, NULL, etc.
3647
3648         * doc/file-boilerplate.c: put include guards in here
3649
3650 2002-11-21  Havoc Pennington  <hp@redhat.com>
3651
3652         * doc/file-boilerplate.c: include both AFL and GPL boilerplate.
3653
3654         * COPYING: include the GPL as well, and license code 
3655         under both AFL and GPL.
3656
3657 2002-11-21  Havoc Pennington  <hp@redhat.com>
3658
3659         * acconfig.h: get rid of this
3660
3661         * autogen.sh (run_configure): add --no-configure option
3662
3663         * configure.in: remove AC_ARG_PROGRAM to make
3664         autoconf complain less. add AC_PREREQ. 
3665         add AC_DEFINE third arg.
3666         
3667 2002-11-21  Anders Carlsson  <andersca@codefactory.se>
3668
3669         * doc/Makefile.am:
3670         Fix references so we can distcheck.
3671
3672 2002-11-21  Havoc Pennington  <hp@redhat.com>
3673
3674         * Initial module creation
3675