2003-01-31 Havoc Pennington <hp@pobox.com>
[platform/upstream/dbus.git] / ChangeLog
1 2003-01-31  Havoc Pennington  <hp@pobox.com>
2
3         * doc/dbus-specification.sgml: work on the specification
4
5         * dbus/dbus-message.c (_dbus_message_loader_return_buffer): check 
6         the protocol version of the message.
7
8         * dbus/dbus-protocol.h: drop special _REPLY names, the spec 
9         no longer specifies that.
10         (DBUS_SERVICE_REPLY_SERVICE_EXISTS): fix flags (1/2/4/8 not 
11         1/2/3/4)
12
13         * dbus/dbus-marshal.c (_dbus_marshal_get_arg_end_pos): add missing
14         "break" for DBUS_TYPE_NIL, remove @todo
15
16 2003-01-31  Havoc Pennington  <hp@pobox.com>
17
18         * dbus/dbus-message.c (dbus_message_set_is_error_reply): rename 
19         just set_is_error/get_is_error as this is a commonly-used
20         function, and write docs.
21
22 2003-01-31  Anders Carlsson  <andersca@codefactory.se>
23
24         * dbus/dbus-address.c: (dbus_address_entry_free):
25         Free key and value lists.
26         
27         * dbus/dbus-internals.c: (_dbus_type_to_string):
28         Add the types we didn't have.
29         
30         * dbus/dbus-marshal.c: (_dbus_marshal_get_arg_end_pos),
31         (_dbus_marshal_validate_arg):
32         Add NIL types.
33         
34         * dbus/dbus-message.c: (dbus_message_set_sender):
35         Remove todo about being able to set sender to NULL.
36         
37         (dbus_message_set_is_error_reply),
38         (dbus_message_get_is_error_reply):
39         * dbus/dbus-message.h:
40         New functions.
41         
42         * dbus/dbus-protocol.h:
43         Add error reply flag.
44         
45         * test/data/valid-messages/opposite-endian.message:
46         Add NIL type to test.
47         
48 2003-01-31  Havoc Pennington  <hp@pobox.com>
49
50         * doc/dbus-specification.sgml: fully specify the header.  Add
51         flags and major protocol version, and change header/body len to
52         unsigned.
53
54         * dbus/dbus-message-builder.c (append_saved_length): append length
55         as uint32
56
57         * dbus/dbus-message.c (dbus_message_create_header): change header
58         length and body length to unsigned. Add the new fields from the
59         spec
60         (_dbus_message_loader_return_buffer): unsigned header/body len
61
62 2003-01-30  Havoc Pennington  <hp@pobox.com>
63
64         * dbus/dbus-auth.c: rework to use only REJECTED, no 
65         MECHANISMS
66
67         * doc/dbus-sasl-profile.txt: drop MECHANISMS and just 
68         use REJECTED, suggested by Mark McLoughlin
69
70 2003-01-30  Havoc Pennington  <hp@pobox.com>
71
72         * dbus/dbus-server.c (dbus_server_listen): @todo about how we need
73         a better way to report errors here. e.g.  "unix address lacks
74         path" or something. also "no such file" when the path doesn't
75         exist, etc.
76
77         * dbus/dbus-address.c (dbus_address_entries_free): add @todo about
78         leaking list nodes
79         (dbus_parse_address): add @todo about documenting address format, 
80         and allowing , and ; to be escaped
81
82 2003-01-30  Anders Carlsson  <andersca@codefactory.se>
83
84         * dbus/Makefile.am:
85         Add dbus-address.[ch]
86         
87         * dbus/dbus-address.c: (dbus_address_entry_free),
88         (dbus_address_entries_free), (create_entry),
89         (dbus_address_entry_get_method), (dbus_address_entry_get_value),
90         (dbus_parse_address), (_dbus_address_test):
91         * dbus/dbus-address.h:
92         New files for dealing with address parsing.
93         
94         * dbus/dbus-connection.c:
95         Document timeout functions.
96         
97         * dbus/dbus-message.c:
98         Document dbus_message_new_from_message.
99         
100         * dbus/dbus-server-debug.c:
101         Document.
102         
103         * dbus/dbus-server.c: (dbus_server_listen):
104         Parse address and use correct server implementation.
105         
106         * dbus/dbus-string.c: (_dbus_string_find_to), (_dbus_string_test):
107         * dbus/dbus-string.h:
108         New function with test.
109         
110         * dbus/dbus-test.c: (dbus_internal_symbol_do_not_use_run_tests):
111         * dbus/dbus-test.h:
112         Add address tests.
113         
114         * dbus/dbus-transport-debug.c:
115         Document.
116         
117         * dbus/dbus-transport.c: (_dbus_transport_open):
118         Parse address and use correct transport implementation. 
119
120 2003-01-30  Havoc Pennington  <hp@pobox.com>
121
122         * dbus/dbus-message.c: use message->byte_order instead of 
123         DBUS_COMPILER_BYTE_ORDER throughout.
124         (dbus_message_create_header): pad header to align the 
125         start of the body of the message to 8-byte boundary
126
127         * dbus/dbus-marshal.h: make all the demarshalers take const 
128         DBusString arguments.
129
130         * dbus/dbus-message.c (_dbus_message_loader_return_buffer):
131         validate message args here, so we don't have to do slow validation
132         later, and so we catch bad messages as they are incoming. Also add
133         better checks on header_len and body_len. Also fill in
134         message->byte_order
135
136         * dbus/dbus-string.c (_dbus_string_validate_utf8): new (not
137         implemented properly)
138         (_dbus_string_validate_nul): new function to check all-nul
139
140         * dbus/dbus-marshal.c (_dbus_marshal_get_field_end_pos): rename 
141         get_arg_end_pos and remove all validation
142         (_dbus_marshal_validate_arg): actually do validation here.
143
144 2003-01-29  Havoc Pennington  <hp@pobox.com>
145
146         * dbus/dbus-message.c (check_message_handling): fix assertion
147         failure on set_client_serial
148
149 2003-01-28  Havoc Pennington  <hp@pobox.com>
150
151         * dbus/dbus-server-debug.c: Add doc section comments
152         
153         * dbus/dbus-transport-debug.c: add doc section comments
154         
155 2003-01-28  Havoc Pennington  <hp@redhat.com>
156
157         * dbus/dbus-string.c (_dbus_string_base64_decode): append bytes in
158         the reverse order from how I had it
159         (_dbus_string_base64_encode): reverse encoding order. I was
160         basically byteswapping everything during encoding.
161
162 2003-01-28  Anders Carlsson  <andersca@codefactory.se>
163
164         * dbus/dbus-connection-internal.h:
165         * dbus/dbus-connection.c: (_dbus_connection_add_timeout),
166         (_dbus_connection_remove_timeout):
167         Add functions for adding and removing timeouts.
168         
169         * dbus/dbus-message.c: (dbus_message_new_from_message):
170         Add new function that takes a message and creates an exact
171         copy of it, but with the refcount set to 1.
172         (check_message_handling):
173         Fix build error.
174         
175         * dbus/dbus-server-protected.h:
176         * dbus/dbus-server.c: (_dbus_server_init_base),
177         (_dbus_server_finalize_base), (_dbus_server_add_timeout),
178         (dbus_server_set_timeout_functions):
179         (_dbus_server_remove_timeout):
180         New functions so that a server can add and remove timeouts.
181
182         (dbus_server_listen):
183         Add commented out call to dbus_server_debug_new.
184
185         * dbus/dbus-timeout.c: (_dbus_timeout_new):
186         Actually set the handler, doh.
187         
188         * dbus/dbus-transport.c: (_dbus_transport_open):
189         Add commented out call to dbus_transport_debug_client_new.
190         
191         * dbus/Makefile.am:
192         Add dbus-transport-debug.[ch] and dbus-server-debug.[ch]
193         
194 2003-01-28  Havoc Pennington  <hp@pobox.com>
195
196         * dbus/dbus-message.c (check_message_handling): function to check 
197         on the loaded message, iterates over it etc.
198
199 2003-01-28  Havoc Pennington  <hp@pobox.com>
200
201         * test/Makefile.am (dist-hook): fix make distdir
202
203         * dbus/Makefile.am (TESTS_ENVIRONMENT): fix make check
204
205 2003-01-27  Havoc Pennington  <hp@pobox.com>
206
207         * dbus/dbus-mempool.c (time_for_size): replace printf with 
208         _dbus_verbose
209
210         * dbus/dbus-message-builder.c (_dbus_message_data_load): allow
211         empty lines; fix the SAVE_LENGTH stuff to be
212         START_LENGTH/END_LENGTH so it actually works; couple other 
213         bugfixes
214         
215         * test/Makefile.am (dist-hook): add dist-hook for .message files
216
217         * dbus/dbus-string.c (DBUS_STRING_COPY_PREAMBLE): source of a copy
218         can be constant or locked.
219         (_dbus_string_free): allow freeing a const string as
220         documented/intended
221
222         * dbus/dbus-sysdeps.c (_dbus_concat_dir_and_file): utility
223
224         * dbus/dbus-test-main.c (main): take an argument which is the 
225         directory containing test data
226
227         * dbus/dbus-message.c (_dbus_message_test): pass a test_data_dir
228         argument to this and load all the messages in test/data/
229         checking that they can be loaded or not loaded as appropriate.
230
231 2003-01-27  Anders Carlsson  <andersca@codefactory.se>
232
233         * bus/dispatch.c: (bus_dispatch_message_handler):
234         Dispatch messages sent to services.
235         
236         * bus/driver.c: (bus_driver_send_service_deleted),
237         (bus_driver_send_service_created), (bus_driver_send_service_lost),
238         (bus_driver_send_service_acquired):
239         Add helper functions for sending service related messages.
240
241         (bus_driver_send_welcome_message):
242         Send HELLO_REPLY instead of WELCOME.
243         
244         (bus_driver_handle_list_services):
245         Send LIST_SERVICES_REPLY instead of SERVICES.
246         
247         (bus_driver_handle_own_service),
248         (bus_driver_handle_service_exists):
249         New message handlers.
250         
251         (bus_driver_handle_message):
252         Invoke new message handlers.
253         
254         (bus_driver_remove_connection):
255         Don't remove any services here since that's done automatically
256         by bus_service_remove_owner now.
257         
258         * bus/driver.h:
259         New function signatures.
260         
261         * bus/services.c: (bus_service_add_owner):
262         Send ServiceAcquired message if we're the only primary owner.
263         
264         (bus_service_remove_owner):
265         Send ServiceAcquired/ServiceLost messages.
266         
267         (bus_service_set_prohibit_replacement),
268         (bus_service_get_prohibit_replacement):
269         Functions for setting prohibit replacement.
270         
271         (bus_service_has_owner):
272         New function that checks if a connection is in the owner queue of 
273         a certain service.
274         
275         * bus/services.h:
276         Add new function signatures.
277         
278         * dbus/dbus-list.c: (_dbus_list_test):
279         Add tests for _dbus_list_remove_last and traversing the list backwards.
280         
281         * dbus/dbus-list.h:
282         Fix a typo in _dbus_list_get_prev_link, if we're at the first element we can't
283         go any further, so return NULL then.
284         
285         * dbus/dbus-protocol.h:
286         Add new messages, service flags and service replies.
287         
288 2003-01-26  Havoc Pennington  <hp@pobox.com>
289
290         * dbus/dbus-message-builder.c: implement, completely untested.
291
292         * test/data/*: add data to be used in testing. 
293         ".message" files are our simple loadable text format.
294         ".message-raw" will be binary dumps of messages.
295
296         * dbus/dbus-string.c (_dbus_string_starts_with_c_str): new
297
298 2003-01-26  Havoc Pennington  <hp@pobox.com>
299
300         * dbus/dbus-sysdeps.c (_dbus_file_get_contents): new function
301
302         * dbus/dbus-errors.c (dbus_result_to_string): add
303         file errors
304
305         * dbus/dbus-message-builder.c: new file, will contain code to load
306         up messages from files. Not implemented yet.
307
308 2003-01-26  Havoc Pennington  <hp@pobox.com>
309
310         * dbus/dbus-message.c (dbus_message_set_sender): support deleting
311         the sender by setting to NULL
312
313 2003-01-26  Havoc Pennington  <hp@pobox.com>
314
315         The unit tests pass, but otherwise untested.  If it breaks, the
316         tests should have been better. ;-)
317         
318         * bus/driver.c (bus_driver_handle_hello): return if we disconnect
319         the connection.
320
321         * dbus/dbus-message.c: redo everything so we maintain 
322         message->header as the only copy of the various fields.
323         This avoids the possibility of out-of-memory in some cases,
324         for example dbus_message_lock() can't run out of memory anymore,
325         and avoids extra copying. Figured I may as well go ahead and do 
326         this since it was busted for dbus_message_lock to not return 
327         failure on OOM, and dbus_message_write_header was totally
328         unchecked for OOM. Also fixed some random other bugs.
329
330         * dbus/dbus-marshal.c (_dbus_marshal_get_field_end_pos): verify
331         that strings are nul-terminated. Also, end_pos can be equal 
332         to string length just not greater than, I think.
333         (_dbus_marshal_set_int32): new function
334         (_dbus_marshal_set_uint32): new function
335         (_dbus_marshal_set_string): new function
336
337         * dbus/dbus-connection.c (_dbus_connection_new_for_transport): fix
338         a warning, init timeout_list to NULL
339         (dbus_connection_send_message): don't use uninitialized variable
340         "serial"
341
342         * dbus/dbus-string.c (_dbus_string_replace_len): new function
343
344 2003-01-26  Anders Carlsson  <andersca@codefactory.se>
345
346         * bus/driver.c: (bus_driver_handle_hello),
347         (bus_driver_send_welcome_message):
348         Plug leaks
349         
350 2003-01-26  Anders Carlsson  <andersca@codefactory.se>
351
352         * dbus/dbus-auth.c: (process_auth), (_dbus_auth_unref):
353         * dbus/dbus-connection.c: (_dbus_connection_new_for_transport),
354         (dbus_connection_unref):
355         * dbus/dbus-marshal.c: (_dbus_marshal_test):
356         * dbus/dbus-message.c: (dbus_message_unref),
357         Plug memory leaks.
358         
359         (dbus_message_get_fields): 
360         Remove debugging printout.
361
362         (_dbus_message_loader_return_buffer):
363         Don't store the header string.
364         
365         (_dbus_message_test):
366         Plug leaks.
367
368 2003-01-26  Richard Hult  <rhult@codefactory.se>
369
370         * glib/dbus-gmain.c (dbus_connection_dispatch): Traverse a copy of
371         the file descriptor list, since it can change under us.
372
373 2003-01-25  Anders Carlsson  <andersca@codefactory.se>
374
375         * glib/dbus-gmain.c: (dbus_connection_prepare),
376         (dbus_connection_check), (dbus_connection_dispatch), (add_watch),
377         (remove_watch), (dbus_connection_hookup_with_g_main):
378         Rewrite the glib handling to use its own GSource instead of a 
379         GIOChannel so we can catch messages put in the queue while waiting
380         for a reply.
381         
382 2003-01-25  Anders Carlsson  <andersca@codefactory.se>
383
384         * bus/Makefile.am:
385         * bus/connection.c: (connection_disconnect_handler),
386         (connection_watch_callback), (bus_connection_setup):
387         * bus/dispatch.c: (send_one_message),
388         (bus_dispatch_broadcast_message), (bus_dispatch_message_handler),
389         (bus_dispatch_add_connection), (bus_dispatch_remove_connection):
390         * bus/dispatch.h:
391         * bus/driver.c: (bus_driver_send_service_deleted),
392         (bus_driver_send_service_created), (bus_driver_handle_hello),
393         (bus_driver_send_welcome_message),
394         (bus_driver_handle_list_services), (bus_driver_remove_connection),
395         (bus_driver_handle_message):
396         * bus/driver.h:
397         Refactor code, put the message dispatching in its own file. Use 
398         _DBUS_HANDLE_OOM. Also send ServiceDeleted messages when a client
399         is disconnected.
400         
401 2003-01-25  Anders Carlsson  <andersca@codefactory.se>
402
403         * dbus/dbus-internals.h:
404         Add _DBUS_HANDLE_OOM macro, it doesn't do anything currently.
405         
406         * dbus/dbus-message.c: (dbus_message_get_sender):
407         * dbus/dbus-message.h:
408         Implement dbus_message_get_sender.
409         
410         * dbus/dbus-protocol.h:
411         Add message and service defines.
412         
413 2003-01-25  Anders Carlsson  <andersca@codefactory.se>
414
415         * dbus/dbus-connection.c: (dbus_connection_send_message):
416         * dbus/dbus-message-internal.h:
417         * dbus/dbus-message.c: (_dbus_message_get_client_serial),
418         (dbus_message_write_header):
419         Remove _dbus_messag_unlock and don't set the client serial on a 
420         message if one already exists.
421         
422 2003-01-24  Havoc Pennington  <hp@pobox.com>
423
424         * dbus/dbus-list.c (alloc_link): put a thread lock on the global
425         list_pool
426
427         * bus/driver.c (bus_driver_handle_list_services): fix a leak 
428         on OOM
429
430 2003-01-25  Anders Carlsson  <andersca@codefactory.se>
431
432         * dbus/dbus-list.c: (alloc_link), (free_link):
433         Use a memory pool for the links.
434         
435 2003-01-25  Anders Carlsson  <andersca@codefactory.se>
436
437         * bus/connection.c: (bus_connection_foreach):
438         * bus/connection.h:
439         Add new bus_connection_foreach function.
440         
441         * bus/driver.c: (send_one_message), (bus_driver_broadcast_message):
442         Add function that broadcasts a message to all clients.
443         
444         (bus_driver_send_service_created), (bus_driver_handle_hello),
445         (bus_driver_send_welcome_message),
446         (bus_driver_handle_list_services), (bus_driver_message_handler):
447         Implement functions that take care of listing services, and notifying
448         clients when new services are created.
449         
450         * bus/services.c: (bus_services_list):
451         * bus/services.h:
452         Add new function that returns an array of strings with the currently
453         registered services.
454         
455         * glib/dbus-glib.h:
456         * glib/dbus-gmain.c:
457         Update copyright year.
458         
459 2003-01-25  Anders Carlsson  <andersca@codefactory.se>
460
461         * dbus/dbus-connection.c: (dbus_connection_send_message):
462         Unlock the message in case it was sent earlier.
463         
464         (dbus_connection_send_message_with_reply_and_block):
465         Remove the reply message from the list.
466         
467         * dbus/dbus-marshal.c: (_dbus_demarshal_string_array):
468         Set array_len and new_pos correctly.
469         
470         (_dbus_marshal_test):
471         Remove debug output.
472         
473         * dbus/dbus-message-internal.h:
474         * dbus/dbus-message.c: (_dbus_message_get_reply_serial):
475         New function that returns the reply serial.
476         
477         (_dbus_message_unlock):
478         New function that unlocks a message and resets its header.
479
480         (dbus_message_append_string_array), 
481         (dbus_message_get_fields_valist),
482         (dbus_message_iter_get_field_type),
483         (dbus_message_iter_get_string_array),   
484         (dbus_message_get_fields),      
485         (dbus_message_append_fields_valist):
486         Handle string arrays.
487         
488         (dbus_message_set_sender):
489         Make this function public since the bus daemon needs it.
490         
491         (decode_header_data):
492         Set the reply serial to -1 initially.
493
494         * dbus/dbus-message.h:
495         Add dbus_message_set_sender.    
496
497 2003-01-24  Havoc Pennington  <hp@pobox.com>
498
499         * doc/dbus-specification.sgml: add some stuff
500
501 2003-01-22  Havoc Pennington  <hp@pobox.com>
502
503         * doc/dbus-specification.sgml: Start to document the protocol.
504
505 2003-01-22  Havoc Pennington  <hp@pobox.com>
506
507         * dbus/dbus-connection.c
508         (dbus_connection_send_message_with_reply_and_block): add some @todo
509
510         * bus/driver.c (bus_driver_add_connection): add a FIXME about memleak
511
512 2003-01-21  Havoc Pennington  <hp@pobox.com>
513
514         (patch untested because can't compile)
515         
516         * bus/driver.c (create_unique_client_name): make this function
517         never recycle client names. Also, caller should initialize 
518         the DBusString.
519
520         * dbus/dbus-sysdeps.c (_dbus_get_current_time): new function
521
522 2003-01-21  Anders Carlsson  <andersca@codefactory.se>
523
524         * dbus/dbus-marshal.c: (_dbus_marshal_double),
525         (_dbus_marshal_int32), (_dbus_marshal_uint32),
526         (_dbus_marshal_int32_array), (_dbus_marshal_uint32_array),
527         (_dbus_marshal_double_array), (_dbus_marshal_string_array),
528         (_dbus_demarshal_int32_array), (_dbus_demarshal_uint32_array),
529         (_dbus_demarshal_double_array), (_dbus_demarshal_string_array),
530         (_dbus_marshal_get_field_end_pos), (_dbus_marshal_test):
531         * dbus/dbus-marshal.h:
532         * dbus/dbus-protocol.h:
533         Add support for marshalling and demarshalling integer, double
534         and string arrays.
535         
536 2003-01-21  Anders Carlsson  <andersca@codefactory.se>
537
538         * bus/Makefile.am:
539         Add driver.[ch]
540         
541         * bus/connection.c: (connection_disconnect_handler):
542         Remove the connection from the bus driver's list.
543         
544         (connection_watch_callback): Dispatch messages.
545
546         (free_connection_data): Free connection name.
547         
548         (bus_connection_setup): Add connection to the bus driver's list.
549         (bus_connection_remove_owned_service): 
550         (bus_connection_set_name), (bus_connection_get_name):
551         Add functions for setting and getting the connection's name.
552         
553         * bus/connection.h:
554         Add function headers.
555         
556         * bus/driver.c: (create_unique_client_name),
557         (bus_driver_handle_hello_message),
558         (bus_driver_send_welcome_message), (bus_driver_message_handler),
559         (bus_driver_add_connection), (bus_driver_remove_connection):
560         * bus/driver.h:
561         * bus/main.c:
562         * bus/services.c: (bus_service_free):
563         * bus/services.h:
564         New file that handles communication and registreation with the bus
565         itself. 
566         
567 2003-01-21  Anders Carlsson  <andersca@codefactory.se>
568
569         * dbus/dbus-connection.c: (dbus_connection_send_message):
570         Add a new client_serial parameter.
571         
572         (dbus_connection_send_message_with_reply):
573         Remove a @todo since we've implemented the blocking function.
574         
575         (dbus_connection_send_message_with_reply_and_block):
576         New function that sends a message and waits for a reply and
577         then returns the reply.
578         
579         * dbus/dbus-connection.h:
580         Add new functions.
581         
582         * dbus/dbus-errors.c: (dbus_result_to_string):
583         * dbus/dbus-errors.h:
584         Add new DBUS_RESULT.
585         
586         * dbus/dbus-message-internal.h:
587         * dbus/dbus-message.c: (_dbus_message_get_reply_serial),
588         (_dbus_message_set_sender), (dbus_message_write_header),
589         (dbus_message_new_reply), (decode_header_data),
590         (_dbus_message_loader_return_buffer), (_dbus_message_test):
591         * dbus/dbus-message.h:
592         Add new functions that set the reply serial and sender.
593         Also marshal and demarshal them correctly and add test.
594         
595         * dbus/dbus-protocol.h:
596         Add new DBUS_MESSAGE_TYPE_SENDER.
597         
598         * glib/dbus-glib.h:
599         * glib/dbus-gmain.c: (watch_callback), (free_callback_data),
600         (add_watch), (remove_watch), (add_timeout), (remove_timeout),
601         (dbus_connection_hookup_with_g_main):
602         * glib/test-dbus-glib.c: (main):
603         Rewrite to use GIOChannel and remove the GSource crack.
604         
605         * test/echo-client.c: (main):
606         * test/watch.c: (check_messages):
607         Update for changed APIs
608         
609 2003-01-19  Anders Carlsson  <andersca@codefactory.se>
610
611         * dbus/Makefile.am: Add dbus-timeout.[cħ]
612         
613         * dbus/dbus-connection.c: (_dbus_connection_new_for_transport):
614         Create a DBusTimeoutList.       
615         (dbus_connection_set_timeout_functions): Add new function to
616         set timeout callbacks
617         
618         * dbus/dbus-connection.h: Add public DBusTimeout API.
619         
620         * dbus/dbus-message.c: (dbus_message_get_service):
621         * dbus/dbus-message.h:  New function.
622
623         * dbus/dbus-server.c: Fix small doc typo.
624         
625         * dbus/dbus-timeout.[ch]: New files for mainloop timeouts.
626
627 2003-01-19  Anders Carlsson  <andersca@codefactory.se>
628
629         * dbus/dbus-string.c (_dbus_string_move_len): Don't delete all
630         of the string, just as long as specified.
631
632 2003-01-19  Havoc Pennington  <hp@pobox.com>
633
634         * dbus/dbus-connection.c (dbus_connection_get_is_authenticated):
635         new function
636
637         * dbus/dbus-server.c (dbus_server_set_max_connections)
638         (dbus_server_get_max_connections, dbus_server_get_n_connections):
639         keep track of current number of connections, and add API for
640         setting a max (but haven't implemented enforcing the max yet)
641
642 2003-01-18  Havoc Pennington  <hp@pobox.com>
643
644         * dbus/dbus-transport-unix.c (unix_do_iteration): only do the
645         reading/writing if read_watch != NULL or write_watch != NULL.
646
647         * dbus/dbus-message.c (_dbus_message_loader_return_buffer): fix
648         the message loader code to actually load message->header and
649         message->body into the newly-created message.
650
651         * dbus/dbus-transport-unix.c (check_write_watch): fix a mem leak
652         in OOM case
653
654         * dbus/dbus-connection.c (dbus_connection_set_max_message_size) 
655         (dbus_connection_get_max_message_size) 
656         (dbus_connection_set_max_live_messages_size) 
657         (dbus_connection_get_max_live_messages_size): implement some
658         resource limitation functions
659
660         * dbus/dbus-resources.c: new file implementing some of the
661         resource limits stuff
662
663         * dbus/dbus-message.c (dbus_message_iter_get_byte_array): add
664         missing docs, add @todo to handle OOM etc.
665
666         * dbus/dbus-marshal.c (_dbus_demarshal_byte_array): add missing
667         docs
668         
669 2003-01-18  Havoc Pennington  <hp@pobox.com>
670
671         * dbus/dbus-connection.c (dbus_connection_unref): disconnect the 
672         connection if it hasn't been already.
673
674         * dbus/dbus-connection.h: kill off the idea of an ErrorFunction,
675         replace with DisconnectFunction.
676
677 2003-01-18  Havoc Pennington  <hp@pobox.com>
678
679         Building --disable-verbose-mode --disable-asserts --disable-tests
680         cuts the library from 112K to 45K or so
681         
682         * configure.in: check for varargs macro support, 
683         add --enable-verbose-mode, --enable-asserts. 
684
685         * dbus/dbus-internals.h (_dbus_assert): support
686         DBUS_DISABLE_ASSERT
687         (_dbus_verbose): support DBUS_ENABLE_VERBOSE_MODE
688
689 2003-01-18  Havoc Pennington  <hp@pobox.com>
690
691         * dbus/dbus-test.c: include config.h so that tests actually run
692
693         * dbus/dbus-string.c: add assertions that stuff is 8-byte aligned,
694         so the failure mode when that assumption fails will be plenty
695         obvious.
696
697 2003-01-18  Havoc Pennington  <hp@pobox.com>
698
699         * configure.in: default --enable-tests to $USE_MAINTAINER_MODE
700
701         * dbus/Makefile.am: fix it up so dubs-test-main.c is included in
702         the distribution
703
704         * test/Makefile.am: don't use special variable "TESTS" for echo-*
705         since we don't want to use those in make check
706
707 2003-01-15  Havoc Pennington  <hp@redhat.com>
708
709         Release 0.2
710         
711         * NEWS: update
712
713 2003-01-15  Havoc Pennington  <hp@redhat.com>
714
715         * test/Makefile.am: fix so that test source code ends up in the
716         distribution on make distcheck
717
718 2003-01-15  Havoc Pennington  <hp@redhat.com>
719
720         Release 0.1.
721         
722         * NEWS: update  
723
724 2003-01-15  Havoc Pennington  <hp@redhat.com>
725
726         * dbus/dbus-test.c (dbus_internal_symbol_do_not_use_run_tests):
727         fix build when --disable-tests
728
729         * Makefile.am (EXTRA_DIST): put HACKING in here
730
731         * HACKING: document procedure for making a tarball release.
732
733 2003-01-14  Anders Carlsson  <andersca@codefactory.se>
734
735         * bus/connection.c: (connection_error_handler),
736         (bus_connection_setup):
737         * bus/main.c: (main):
738         Make sure that the DBusConnectionData struct is NULLed
739         out to prevent a segfault.
740         
741         * dbus/dbus-errors.c: (dbus_result_to_string):
742         * dbus/dbus-errors.h:
743         * dbus/dbus-message.c: (dbus_message_get_fields),
744         (dbus_message_get_fields_valist), (_dbus_message_test):
745         * dbus/dbus-message.h:
746         Make dbus_message_get_fields return a result code so we can
747         track invalid fields as well as oom.
748         
749 2003-01-11  Havoc Pennington  <hp@pobox.com>
750
751         * configure.in: change --enable-test/--enable-ansi action-if-given
752         to enable_foo=$enableval instead of enable_foo=yes
753
754 2003-01-08  Havoc Pennington  <hp@pobox.com>
755
756         * dbus/dbus-string.c (_dbus_string_align_length): new function
757
758         * dbus/dbus-test-main.c: move main() for test app here
759         * dbus/dbus-test.c
760         (dbus_internal_symbol_do_not_use_run_tests): we have to export a
761         symbol to run tests, because dbus-test isn't in the main 
762         library
763
764         Code review nitpicks.
765         
766         * dbus/dbus-message.c (dbus_message_write_header): add newlines
767         for people with narrow emacs ;-). Assert client_serial was filled
768         in. Assert message->name != NULL.
769         (dbus_message_append_fields): have "first_field_type" arg separate
770         from va list, needed for C++ binding that also uses varargs IIRC
771         and helps with type safety
772         (dbus_message_new): add @todo about using DBusString to store
773         service/name internally
774         (dbus_message_new): don't leak ->service and ->name on OOM later
775         in the function
776         (dbus_message_unref): free the service name
777         (dbus_message_get_fields): same change to varargs
778         i.e. first_field_type
779         (_dbus_message_loader_return_buffer): assert that the message data
780         is aligned (if not it's a bug in our code). Put in verbose griping
781         about why we set corrupted = TRUE.
782         (decode_header_data): add FIXME that char* is evil.  Was going to
783         add FIXME about evil locale-specific string.h strncmp, but just
784         switched to wacky string-as-uint32 optimization. Move check for
785         "no room for field name" above get_const_data_len() to avoid
786         assertion failure in get_const_data_len if we have trailing 2
787         bytes or the like. Check for service and name fields being
788         provided twice. Don't leak service/name on error. Require field
789         names to be aligned to 4 bytes.
790
791         * dbus/dbus-marshal.c: move byte swap stuff to header
792         (_dbus_pack_int32): uscore-prefix
793         (_dbus_unpack_int32): uscore-prefix
794         (_dbus_unpack_uint32): export
795         (_dbus_demarshal_string): add @todo complaining about use of
796         memcpy()
797         (_dbus_marshal_get_field_end_pos): add @todo about bad error
798         handling allowing corrupt data to go unchecked
799
800 2003-01-08  Havoc Pennington  <hp@redhat.com>
801
802         * dbus/dbus-transport-unix.c (unix_do_iteration): add read/write 
803         to the select() as needed for authentication. (should be using
804         _dbus_poll() not select, but for another day)
805
806         * dbus/dbus.h: include dbus/dbus-protocol.h
807
808 2003-01-08  Anders Carlsson  <andersca@codefactory.se>
809
810         * dbus/Makefile.am (dbusinclude_HEADERS): Install
811         dbus-connection.h
812
813 2003-01-08  Anders Carlsson  <andersca@codefactory.se>
814
815         * dbus/dbus-internals.c: (_dbus_type_to_string):
816         New function that returns a string describing a type.
817         
818         * dbus/dbus-marshal.c: (_dbus_demarshal_byte_array):
819         * dbus/dbus-marshal.h:
820         * dbus/dbus-message.c: (dbus_message_get_fields_valist),
821         (dbus_message_iter_get_field_type), (dbus_message_iter_get_double),
822         (dbus_message_iter_get_byte_array):
823         * dbus/dbus-message.h:
824         Add new convenience functions for appending and getting message fields.
825         Also add demarshalling routines for byte arrays.
826
827 2003-01-07  Anders Carlsson  <andersca@codefactory.se>
828
829         * dbus/dbus-connection-internal.h:
830         * dbus/dbus-connection.c: (_dbus_connection_new_for_transport),
831         (_dbus_connection_get_next_client_serial),
832         (dbus_connection_send_message):
833         * dbus/dbus-internals.h:
834         * dbus/dbus-marshal.c: (unpack_uint32), (dbus_unpack_int32),
835         (dbus_pack_int32), (_dbus_marshal_double), (_dbus_marshal_int32),
836         (_dbus_marshal_uint32), (_dbus_demarshal_double),
837         (_dbus_demarshal_int32), (_dbus_demarshal_uint32),
838         (_dbus_demarshal_string), (_dbus_marshal_get_field_end_pos),
839         (_dbus_verbose_bytes), (_dbus_marshal_test):
840         * dbus/dbus-marshal.h:
841         * dbus/dbus-message-internal.h:
842         * dbus/dbus-message.c: (_dbus_message_set_client_serial),
843         (dbus_message_write_header), (_dbus_message_lock),
844         (dbus_message_new), (dbus_message_ref), (dbus_message_unref),
845         (dbus_message_get_name), (dbus_message_append_int32),
846         (dbus_message_append_uint32), (dbus_message_append_double),
847         (dbus_message_append_string), (dbus_message_append_byte_array),
848         (dbus_message_get_fields_iter), (dbus_message_iter_ref),
849         (dbus_message_iter_unref), (dbus_message_iter_has_next),
850         (dbus_message_iter_next), (dbus_message_iter_get_field_type),
851         (dbus_message_iter_get_string), (dbus_message_iter_get_int32),
852         (dbus_message_iter_get_uint32), (dbus_message_iter_get_double),
853         (decode_header_data), (_dbus_message_loader_return_buffer),
854         (message_iter_test), (_dbus_message_test):
855         * dbus/dbus-message.h:
856         * dbus/dbus-protocol.h:
857         * dbus/dbus-test.c: (main):
858         * dbus/dbus-test.h:
859         * glib/test-dbus-glib.c: (message_handler), (main):
860         * test/echo-client.c: (main):
861         * test/watch.c: (check_messages):
862         Make messages sendable and receivable for real.
863         
864 2003-01-07  Anders Carlsson  <andersca@codefactory.se>
865
866         * dbus/dbus-marshal.c: (_dbus_marshal_double),
867         (_dbus_marshal_string), (_dbus_marshal_byte_array):
868         * dbus/dbus-message.c: (dbus_message_append_int32),
869         (dbus_message_append_uint32), (dbus_message_append_double),
870         (dbus_message_append_string), (dbus_message_append_byte_array):
871         Handle OOM restoration.
872         
873 2003-01-07  Anders Carlsson  <andersca@codefactory.se>
874
875         * dbus/dbus-marshal.c: (_dbus_marshal_string),
876         (_dbus_demarshal_string), (_dbus_marshal_test):
877         * dbus/dbus-marshal.h:
878         * dbus/dbus-message.c: (dbus_message_get_name),
879         Document these functions.
880         
881         (dbus_message_append_int32), (dbus_message_append_uint32),
882         (dbus_message_append_double), (dbus_message_append_string),
883         (dbus_message_append_byte_array):
884         * dbus/dbus-message.h:
885         Add functions for adding message fields of different types.
886         
887         * dbus/dbus-protocol.h:
888         Add the different types.
889
890 2003-01-05  Havoc Pennington  <hp@pobox.com>
891
892         * bus/connection.c: implement routines for handling connections,
893         first thing is keeping a list of owned services on each connection
894         and setting up watches etc.
895
896         * bus/services.c: implement a mapping from service names to lists
897         of connections
898
899         * dbus/dbus-hash.c: add DBUS_HASH_POINTER
900
901         * dbus/dbus-threads.c (dbus_static_mutex_lock): add functions
902         to use static mutexes for global data
903
904         * dbus/dbus-connection.c (dbus_connection_set_data): add new
905         collection of functions to set/get application-specific data
906         on the DBusConnection.
907
908 2003-01-04  Havoc Pennington  <hp@pobox.com>
909
910         * dbus/dbus-sysdeps.c (_dbus_sleep_milliseconds): new function
911         (_dbus_poll): new function
912
913         * dbus/dbus-internals.h (_DBUS_STRUCT_OFFSET): new macro
914         copied from GLib
915
916         * bus/loop.c: initial code for the daemon main loop
917
918 2003-01-04  Havoc Pennington  <hp@pobox.com>
919
920         * test/watch.c (error_handler): make it safe if the error handler 
921         is called multiple times (if we s/error handler/disconnect
922         handler/ we should just guarantee it's called only once)
923
924         * dbus/dbus-transport.c (_dbus_transport_disconnect): call the
925         error handler on disconnect (it's quite possible we should
926         just change the error handler to a "disconnect handler," I'm 
927         not sure we have any other meaningful errors)
928
929         * configure.in: check for getpwnam_r
930
931         * dbus/dbus-transport.c, dbus/dbus-transport-unix.c,
932         dbus/dbus-auth.c: add credentials support, add EXTERNAL auth
933         mechanism as in SASL spec, using socket credentials
934
935         * dbus/dbus-sysdeps.c (_dbus_read_credentials_unix_socket): new function
936         (_dbus_send_credentials_unix_socket): new function
937
938         * dbus/dbus-sysdeps.c (_dbus_accept_unix_socket): rename just
939         dbus_accept()
940         (_dbus_write): only check errno if <0 returned
941         (_dbus_write_two): ditto
942
943 2003-01-02  Anders Carlsson  <andersca@codefactory.se>
944
945         * dbus/dbus-marshal.c: (_dbus_marshal_utf8_string),
946         (_dbus_marshal_byte_array), (_dbus_demarshal_utf8_string),
947         (_dbus_marshal_test):
948         * dbus/dbus-marshal.h:
949         Add _dbus_marshal_byte_array and rename _dbus_marshal_string
950         to _dbus_marshal_utf8_string. Also fix some tests.
951         
952 2002-12-28  Harri Porten  <porten@kde.org>
953
954         * configure.in: added check for C++ compiler and a very cheesy
955         check for the Qt integration
956
957         * Makefile.am (SUBDIRS): compile qt subdir if support is enabled
958
959         * qt/Makefile.am: added 
960
961         * qt/.cvsignore: added  
962
963         * qt/dbus-qthread.cc, qt/dbus-qthread.cpp: renamed former to
964         latter, added #ifdef QT_THREAD_SUPPORT guard.
965
966         * dbus/Makefile.am: added missing headers for make dist
967
968 2002-12-28  Kristian Rietveld  <kris@gtk.org>
969
970         * dbus/Makefile.am: fixup export-symbols-regex.
971
972 2002-12-27  Anders Carlsson  <andersca@codefactory.se>
973
974         * acinclude.m4: Add this file and put the 
975         PKG_CHECK_MODULE macro in it.
976
977 2002-12-27  Anders Carlsson  <andersca@codefactory.se>
978
979         * dbus/dbus-marshal.c: (_dbus_marshal_string),
980         (_dbus_demarshal_double), (_dbus_demarshal_int32),
981         (_dbus_demarshal_uint32), (_dbus_demarshal_string),
982         (_dbus_marshal_test):
983         Make the demarshalling routines align the pos argument.
984         Add string marshalling tests and fix the obvious bugs 
985         discovered.
986         
987 2002-12-26  Havoc Pennington  <hp@pobox.com>
988
989         * dbus/dbus-auth.c: fixes fixes fixes
990
991         * dbus/dbus-transport-unix.c: wire up support for
992         encoding/decoding data on the wire
993
994         * dbus/dbus-auth.c (_dbus_auth_encode_data) 
995         (_dbus_auth_decode_data): append to target string 
996         instead of nuking it.
997
998 2002-12-26  Havoc Pennington  <hp@pobox.com>
999
1000         * dbus/dbus-marshal.h (DBUS_COMPILER_BYTE_ORDER): #ifdef
1001         WORDS_BIGENDIAN then compiler byte order is DBUS_BIG_ENDIAN,
1002         doh
1003
1004         * dbus/dbus-marshal.c: Add macros to do int swapping in-place and
1005         avoid swap_bytes() overhead (ignoring possible assembly stuff for 
1006         now). Main point is because I wanted unpack_uint32 to implement
1007         _dbus_verbose_bytes
1008         (_dbus_verbose_bytes): new function
1009
1010         * dbus/dbus-string.c (_dbus_string_validate_ascii): new function
1011
1012         * dbus/dbus-message.c (_dbus_message_loader_get_is_corrupted): add
1013         mechanism to handle a corrupt message stream
1014         (_dbus_message_loader_new): fix preallocation to only prealloc, 
1015         not prelengthen
1016         
1017         * dbus/dbus-string.c (_dbus_string_skip_blank): fix this function
1018         (_dbus_string_test): enhance tests for copy/move and fix the
1019         functions
1020
1021         * dbus/dbus-transport-unix.c: Hold references in more places to 
1022         avoid reentrancy problems
1023
1024         * dbus/dbus-transport.c: ditto
1025
1026         * dbus/dbus-connection.c (dbus_connection_dispatch_message): don't
1027         leak reference count in no-message case
1028
1029         * test/watch.c (do_mainloop): handle adding/removing watches
1030         during iteration over the watches. Also, ref the connection/server
1031         stored on a watch, so we don't try to mangle a destroyed one.
1032
1033         * dbus/dbus-transport-unix.c (do_authentication): perform
1034         authentication
1035
1036         * dbus/dbus-auth.c (get_state): add a state
1037         AUTHENTICATED_WITH_UNUSED_BYTES and return it if required
1038         (_dbus_auth_get_unused_bytes): append the unused bytes
1039         to the passed in string, rather than prepend
1040
1041         * dbus/dbus-transport.c (_dbus_transport_init_base): create 
1042         the auth conversation DBusAuth
1043
1044         * dbus/dbus-transport-unix.c (_dbus_transport_new_for_fd)
1045         (_dbus_transport_new_for_domain_socket): when creating a
1046         transport, pass in whether it's a client-side or server-side
1047         transport so we know which DBusAuth to create
1048
1049 2002-12-03  Havoc Pennington  <hp@pobox.com>
1050
1051         * dbus/dbus-transport-unix.c (unix_finalize): finalize base
1052         _after_ finalizing the derived members
1053         (unix_connection_set): unref watch if we fail to add it
1054
1055         * dbus/dbus-connection.c (dbus_connection_unref): delete the
1056         transport first, so that the connection owned by the 
1057         transport will be valid as the transport finalizes.
1058
1059         * dbus/dbus-transport-unix.c (unix_finalize): free the write_watch
1060         if necessary, and remove watches from the connection.
1061         
1062         * dbus/dbus-watch.c (_dbus_watch_list_free): improve a comment
1063         
1064 2002-12-26  Anders Carlsson  <andersca@codefactory.se>
1065
1066         * dbus/dbus-marshal.c: (_dbus_marshal_string),
1067         (_dbus_demarshal_double), (_dbus_demarshal_int32),
1068         (_dbus_demarshal_uint32), (_dbus_demarshal_string),
1069         (_dbus_marshal_test):
1070         * dbus/dbus-marshal.h:
1071         Add string marshal functions and have the demarshal functions
1072         return the new position.
1073         
1074 2002-12-25  Havoc Pennington  <hp@pobox.com>
1075
1076         * doc/dbus-sasl-profile.txt: docs on the authentication protocol, 
1077         it is a simple protocol that just maps directly to SASL.
1078
1079         * dbus/dbus-auth.h, dbus/dbus-auth.c: authentication protocol
1080         initial implementation, not actually used yet.
1081         
1082         * dbus/dbus-string.c (_dbus_string_find): new function
1083         (_dbus_string_equal): new function
1084         (_dbus_string_base64_encode): new function
1085         (_dbus_string_base64_decode): new function
1086
1087 2002-12-25  Anders Carlsson  <andersca@codefactory.se>
1088
1089         * dbus/Makefile.am:
1090         * dbus/dbus-marshal.c: (swap_bytes), (_dbus_marshal_double),
1091         (_dbus_marshal_int32), (_dbus_marshal_uint32),
1092         (_dbus_demarshal_double), (_dbus_demarshal_int32),
1093         (_dbus_demarshal_uint32), (_dbus_marshal_test):
1094         * dbus/dbus-marshal.h:
1095         * dbus/dbus-protocol.h:
1096         * dbus/dbus-test.c: (main):
1097         * dbus/dbus-test.h:
1098         Add un-optimized marshalling/demarshalling routines.
1099         
1100 2002-12-25  Harri Porten  <porten@kde.org>
1101
1102         * qt/dbus-qt.h: adjusted ctor and getter to KDE/Qt conventions
1103
1104 2002-12-24  Zack Rusin  <zack@kde.org>
1105
1106         * qt/dbus-qthread.cc: adding - integrates QMutex into Dbus
1107         * qt/dbus-qt.h: skeleton with two sample implemenatation of the
1108         main loop stuff
1109
1110 2002-12-24  Havoc Pennington  <hp@pobox.com>
1111
1112         * glib/dbus-gthread.c: fix include
1113
1114         * glib/dbus-glib.h: rename DBusMessageHandler for now. 
1115         I think glib API needs to change, though, as you don't 
1116         want to use DBusMessageFunction, you want to use the 
1117         DBusMessageHandler object. Probably 
1118         dbus_connection_open_with_g_main_loop()
1119         and dbus_connection_setup_g_main_loop() or something like that
1120         (but think of better names...) that just create a connection 
1121         that has watch/timeout functions etc. already set up.
1122
1123         * dbus/dbus-connection.c
1124         (dbus_connection_send_message_with_reply): new function just to 
1125         show how the message handler helps us deal with replies.
1126
1127         * dbus/dbus-list.c (_dbus_list_remove_last): new function
1128
1129         * dbus/dbus-string.c (_dbus_string_test): free a string that
1130         wasn't
1131
1132         * dbus/dbus-hash.c: use memory pools for the hash entries
1133         (rebuild_table): be more paranoid about overflow, and 
1134         shrink table when we can
1135         (_dbus_hash_test): reduce number of sprintfs and write
1136         valid C89. Add tests for case where we grow and then 
1137         shrink the hash table.
1138
1139         * dbus/dbus-mempool.h, dbus/dbus-mempool.c: memory pools
1140
1141         * dbus/dbus-connection.c (dbus_connection_register_handler) 
1142         (dbus_connection_unregister_handler): new functions
1143
1144         * dbus/dbus-message.c (dbus_message_get_name): new
1145
1146         * dbus/dbus-list.c: fix docs typo
1147
1148         * dbus/dbus-message-handler.h, dbus/dbus-message-handler.c:
1149         an object representing a handler for messages.
1150
1151 2002-12-16  Anders Carlsson  <andersca@codefactory.se>
1152
1153         * glib/dbus-glib.h:
1154         * glib/dbus-gthread.c: (dbus_gthread_init):
1155         Don't use the gdbus prefix for public functions.
1156         
1157 2002-12-16  Anders Carlsson  <andersca@codefactory.se>
1158
1159         * Makefile.am:
1160         * configure.in:
1161         Add GLib checks and fixup .pc files
1162         
1163         * glib/Makefile.am:
1164         * glib/dbus-glib.h:
1165         * glib/dbus-gmain.c: (gdbus_connection_prepare),
1166         (gdbus_connection_check), (gdbus_connection_dispatch),
1167         (gdbus_add_connection_watch), (gdbus_remove_connection_watch),
1168         (dbus_connection_gsource_new):
1169         * glib/dbus-gthread.c: (dbus_gmutex_new), (dbus_gmutex_free),
1170         (dbus_gmutex_lock), (dbus_gmutex_unlock), (dbus_gthread_init):
1171         * glib/test-dbus-glib.c: (message_handler), (main):
1172         Add GLib support.
1173         
1174 2002-12-15  Harri Porten  <porten@kde.org>
1175
1176         * autogen.sh: check for libtoolize before attempting to use it 
1177         
1178         * dbus/dbus-transport-unix.c: include <sys/time.h> for timeval
1179         struct.
1180         
1181         * .cvsignore: ignore more stamp files
1182
1183         * dbus/dbus-watch.c (_dbus_watch_list_new): fixed doc error
1184
1185         * test/Makefile.am: added -I$(top_srcdir) to be able to compile
1186         without make install.
1187
1188 2002-12-15  Havoc Pennington  <hp@pobox.com>
1189
1190         * dbus/dbus-threads.c: add thread stubs that a higher library
1191         layer can fill in. e.g. the GLib wrapper might fill them in with
1192         GThread stuff. We still need to use this thread API to
1193         thread-safe-ize the library.
1194
1195 2002-12-12  Havoc Pennington  <hp@pobox.com>
1196
1197         * dbus/dbus-transport-unix.c, dbus/dbus-server-unix.c: use the
1198         below new interfaces and include fewer system headers.
1199
1200         * dbus/dbus-sysdeps.c (_dbus_read): new function
1201         (_dbus_write): new function
1202         (_dbus_write_two): new function
1203         (_dbus_connect_unix_socket): new function
1204         (_dbus_listen_unix_socket): new function
1205
1206         * dbus/dbus-message-internal.h: change interfaces to use
1207         DBusString
1208
1209 2002-12-11  Havoc Pennington  <hp@pobox.com>
1210
1211         * dbus/dbus-types.h: add dbus_unichar
1212
1213         * dbus/dbus-internals.c (_dbus_verbose): use _dbus_getenv
1214
1215         * dbus/dbus-connection.c (dbus_connection_send_message): return
1216         TRUE on success
1217
1218         * dbus/dbus-transport.c: include dbus-watch.h   
1219
1220         * dbus/dbus-connection.c: include dbus-message-internal.h
1221
1222         * HACKING: add file with coding guidelines stuff.
1223
1224         * dbus/dbus-string.h, dbus/dbus-string.c: Encapsulate all string
1225         handling here, for security purposes (as in vsftpd). Not actually
1226         using this class yet.
1227
1228         * dbus/dbus-sysdeps.h, dbus/dbus-sysdeps.c: Encapsulate all
1229         system/libc usage here, as in vsftpd, for ease of auditing (and
1230         should also simplify portability). Haven't actually moved all the
1231         system/libc usage into here yet.
1232         
1233 2002-11-25  Havoc Pennington  <hp@pobox.com>
1234
1235         * dbus/dbus-internals.c (_dbus_verbose): fix to not 
1236         always print the first verbose message.
1237
1238 2002-11-24  Havoc Pennington  <hp@pobox.com>
1239
1240         * test/echo-client.c, test/echo-server.c: cheesy test 
1241         clients.
1242         
1243         * configure.in (AC_CHECK_FUNCS): check for writev
1244
1245         * dbus/dbus-message.c (_dbus_message_get_network_data): new
1246         function
1247
1248         * dbus/dbus-list.c (_dbus_list_foreach): new function
1249
1250         * dbus/dbus-internals.c (_dbus_verbose): new function
1251
1252         * dbus/dbus-server.c, dbus/dbus-server.h: public object
1253         representing a server that listens for connections.
1254
1255         * dbus/.cvsignore: create
1256
1257         * dbus/dbus-errors.h, dbus/dbus-errors.c:
1258         public API for reporting errors
1259
1260         * dbus/dbus-connection.h, dbus/dbus-connection.c:
1261         public object representing a connection that 
1262         sends/receives messages. (Same object used for 
1263         both client and server.)
1264
1265         * dbus/dbus-transport.h, dbus/dbus-transport.c:
1266         Basic abstraction for different kinds of stream
1267         that we might read/write messages from.
1268
1269 2002-11-23  Havoc Pennington  <hp@pobox.com>
1270
1271         * dbus/dbus-internals.h (_DBUS_INT_MAX): add _DBUS_INT_MIN 
1272         _DBUS_INT_MAX
1273
1274         * dbus/dbus-test.c (main): add list test, and include 
1275         dbus-test.h as intended
1276
1277         * dbus/dbus-hash.c (_dbus_hash_table_remove_string) 
1278         (_dbus_hash_table_remove_int): return value indicates 
1279         whether the entry existed to remove
1280
1281         * dbus/dbus-list.c: add linked list utility class, 
1282         with docs and tests
1283
1284         * dbus/dbus-hash.c: add TODO item about shrinking the hash bucket 
1285         array sometimes.
1286
1287 2002-11-23  Havoc Pennington  <hp@pobox.com>
1288
1289         * Doxyfile.in (INCLUDE_FILE_PATTERNS): expand DBUS_BEGIN_DECLS/
1290         DBUS_END_DECLS to nothing, that should fix this once and for all
1291
1292         * Doxyfile.in (JAVADOC_AUTOBRIEF): set to YES
1293
1294         * dbus/dbus-message.c, dbus/dbus-hash.c: 
1295         add some missing @brief
1296
1297 2002-11-23  Havoc Pennington  <hp@pobox.com>
1298
1299         * dbus/dbus-message.h: put semicolons after DEBUG_BEGIN_DECLS 
1300         to avoid confusing Doxygen
1301
1302         * dbus/dbus-hash.c: @} not }@
1303
1304         * dbus/dbus-message.c (struct DBusMessage): split out 
1305         internals docs
1306
1307 2002-11-23  Havoc Pennington  <hp@pobox.com>
1308
1309         * configure.in: pile on more warning flags if using gcc
1310
1311         * Doxyfile.in (EXTRACT_STATIC): set to NO, so we don't have 
1312         to document static functions
1313
1314         * configure.in: add summary to end of configure so it 
1315         looks nice and attractive
1316
1317         * dbus/dbus-hash.c: finish implementation and write unit 
1318         tests and docs
1319
1320         * configure.in: add --enable-tests to enable unit tests
1321
1322         * dbus/dbus-test.c: test program to run unit tests 
1323         for all files in dbus/*, initially runs a test for 
1324         dbus-hash.c
1325         
1326         * dbus/dbus-internals.h: file to hold some internal utility stuff
1327
1328 2002-11-22  Havoc Pennington  <hp@redhat.com>
1329
1330         * dbus/dbus-hash.c: copy in Tcl hash table, not yet 
1331         "ported" away from Tcl
1332
1333         * dbus/dbus-types.h: header for types such as dbus_bool_t
1334
1335 2002-11-22  Havoc Pennington  <hp@redhat.com>
1336
1337         * dbus/dbus.h: fixups for doc warnings
1338
1339         * Doxyfile.in (FILE_PATTERNS): we need to scan .h to pick up 
1340         macros
1341         (QUIET): make it quiet so we can see warnings
1342
1343         * dbus/dbus-memory.c: teach D-BUS to allocate and free memory
1344
1345 2002-11-22  Havoc Pennington  <hp@redhat.com>
1346
1347         * Makefile.am: include "Doxyfile" target in all-local
1348
1349         * configure.in: generate the Doxyfile
1350
1351         * Doxyfile.in: move Doxyfile here, so we can use 
1352         configure to generate a Doxyfile with the right 
1353         version number etc.
1354
1355 2002-11-22  Havoc Pennington  <hp@redhat.com>
1356
1357         * dbus/dbus-message.c: move inline docs into .c file
1358
1359         * Doxyfile (OUTPUT_DIRECTORY): move output to doc/api
1360         so all docs are under doc/
1361         (MAN_EXTENSION): generate man pages. Use extension 
1362         ".3dbus" which matches ".3qt" on my system, 
1363         I guess this is OK, I don't know really.
1364         (FILE_PATTERNS): look for .c files not .h, makes sense
1365         for plain C I think
1366
1367 2002-11-22  Havoc Pennington  <hp@pobox.com>
1368
1369         * Makefile.am (SUBDIRS): rename subdir "server" to "bus" 
1370         because any app can be a server, and any app can be a client, 
1371         the bus is a special kind of server.
1372
1373 Thu Nov 21 23:35:31 2002  Zack Rusin  <zack@kde.org>
1374
1375         * Doxyfile : adding. Still needs Makefile rules to be generated
1376         automatically (just run "doxygen" in the toplevel dir for now to
1377         generate docs)
1378         
1379         * dbus/dbus-message.h : Adding sample docs (javadoc since
1380         resembles gtk-doc a little more)
1381
1382         * dbus/dbus.h : Adding sample docs
1383
1384 2002-11-21  Havoc Pennington  <hp@redhat.com>
1385
1386         * dbus/Makefile.am (INCLUDES): define DBUS_COMPILATION 
1387         so we can allow ourselves to include files directly, 
1388         instead of having to use dbus.h
1389
1390         * dbus/dbus.h: fill in
1391
1392         * dbus/dbus-message.h: sketch out a sample header file.
1393         Include griping if you include it directly instead of 
1394         via dbus.h
1395
1396         * dbus/dbus-macros.h: new file with macros for extern "C", 
1397         TRUE/FALSE, NULL, etc.
1398
1399         * doc/file-boilerplate.c: put include guards in here
1400
1401 2002-11-21  Havoc Pennington  <hp@redhat.com>
1402
1403         * doc/file-boilerplate.c: include both AFL and GPL boilerplate.
1404
1405         * COPYING: include the GPL as well, and license code 
1406         under both AFL and GPL.
1407
1408 2002-11-21  Havoc Pennington  <hp@redhat.com>
1409
1410         * acconfig.h: get rid of this
1411
1412         * autogen.sh (run_configure): add --no-configure option
1413
1414         * configure.in: remove AC_ARG_PROGRAM to make
1415         autoconf complain less. add AC_PREREQ. 
1416         add AC_DEFINE third arg.
1417         
1418 2002-11-21  Anders Carlsson  <andersca@codefactory.se>
1419
1420         * doc/Makefile.am:
1421         Fix references so we can distcheck.
1422
1423 2002-11-21  Havoc Pennington  <hp@redhat.com>
1424
1425         * Initial module creation
1426