1 2003-02-02 Havoc Pennington <hp@pobox.com>
3 * dbus/dbus-keyring.c, dbus/dbus-keyring.h: template files
4 for code to manage cookies in your home directory
6 * dbus/dbus-sysdeps.c (_dbus_generate_random_bytes): new function
8 * dbus/dbus-auth.c (get_state): impose a maximum number of tries
9 to authenticate, then disconnect the client.
11 2003-02-03 Alexander Larsson <alexl@redhat.com>
13 * dbus/dbus-message.c (dbus_message_append_fields):
16 2003-02-02 Anders Carlsson <andersca@codefactory.se>
18 * doc/dbus-specification.sgml:
19 Update address format section.
21 2003-02-02 Anders Carlsson <andersca@codefactory.se>
24 * test/bus-test.c: (get_time), (add_timeout), (remove_timeout),
25 (message_handler), (new_connection_callback), (loop_quit),
29 2003-02-02 Anders Carlsson <andersca@codefactory.se>
31 * bus/driver.c: (bus_driver_handle_service_exists):
32 Simplify the code a bit.
34 * dbus/dbus-bus.c: (dbus_bus_service_exists):
37 2003-02-02 Anders Carlsson <andersca@codefactory.se>
40 Add libdbus-daemon.la and link to it.
42 2003-02-01 James Willcox <jwillcox@gnome.org>
44 * bus/driver.c: (bus_driver_handle_own_service):
45 Actually include the service reply code in the message.
47 2003-02-02 Anders Carlsson <andersca@codefactory.se>
49 * bus/driver.c: (bus_driver_handle_service_exists):
50 Don't unref the incoming message.
52 2003-02-02 Anders Carlsson <andersca@codefactory.se>
54 * dbus/dbus.h: Add dbus-address.h and dbus-bus.h
56 2003-02-02 Anders Carlsson <andersca@codefactory.se>
58 * dbus/dbus-server.c: (dbus_server_listen):
59 * dbus/dbus-transport.c: (_dbus_transport_open):
60 ifdef out the calls to the debug transport and server.
62 2003-02-02 Alexander Larsson <alexl@redhat.com>
64 * dbus/dbus-watch.c (dbus_watch_get_flags):
65 Add note in the docs that ERROR or HANGUP won't be returned
66 and are assumed always on.
68 * glib/dbus-gmain.c (add_watch):
69 Always add IO_ERR | IO_HUP
71 * dbus/dbus-message.h:
72 Add semicolon after dbus_message_iter_get_string_array().
73 Makes qt code build again
75 2003-02-01 Anders Carlsson <andersca@codefactory.se>
77 * bus/driver.c: (create_unique_client_name),
78 (bus_driver_handle_hello):
79 Don't take a name, just use a numeric id to identify
83 * dbus/dbus-bus.c: (dbus_bus_register_client),
84 (dbus_bus_acquire_service), (dbus_bus_service_exists):
86 Add new convenience functions for communicating with the bus.
88 * dbus/dbus-message.h:
90 * dbus/dbus-protocol.h:
93 2003-02-01 Alexander Larsson <alexl@redhat.com>
95 * dbus/dbus-message.c (dbus_message_append_fields):
96 Add some more doc comments.
98 2003-02-01 Havoc Pennington <hp@pobox.com>
100 * dbus/dbus-break-loader.c (randomly_modify_length): change
101 a 4-byte value in the message as if it were a length
103 * dbus/dbus-sysdeps.c (_dbus_string_save_to_file): don't set
104 execute bit on saved files
106 2003-02-01 Havoc Pennington <hp@pobox.com>
108 * dbus/dbus-break-loader.c (main): new program to find messages
109 that break the loader.
111 * dbus/dbus-sysdeps.c (_dbus_string_append_uint): new function
112 * dbus/dbus-sysdeps.c (_dbus_string_save_to_file): new function
114 * dbus/dbus-string.c (_dbus_string_set_byte): new
116 2003-01-31 Havoc Pennington <hp@pobox.com>
118 * dbus/dbus-message.c: refactor the test code to be more general,
119 in preparation for writing a "randomly permute test cases to
120 try to break the loader" program.
122 2003-01-31 Havoc Pennington <hp@pobox.com>
124 * doc/dbus-specification.sgml: work on the specification
126 * dbus/dbus-message.c (_dbus_message_loader_return_buffer): check
127 the protocol version of the message.
129 * dbus/dbus-protocol.h: drop special _REPLY names, the spec
130 no longer specifies that.
131 (DBUS_SERVICE_REPLY_SERVICE_EXISTS): fix flags (1/2/4/8 not
134 * dbus/dbus-marshal.c (_dbus_marshal_get_arg_end_pos): add missing
135 "break" for DBUS_TYPE_NIL, remove @todo
137 2003-01-31 Havoc Pennington <hp@pobox.com>
139 * dbus/dbus-message.c (dbus_message_set_is_error_reply): rename
140 just set_is_error/get_is_error as this is a commonly-used
141 function, and write docs.
143 2003-01-31 Anders Carlsson <andersca@codefactory.se>
145 * dbus/dbus-address.c: (dbus_address_entry_free):
146 Free key and value lists.
148 * dbus/dbus-internals.c: (_dbus_type_to_string):
149 Add the types we didn't have.
151 * dbus/dbus-marshal.c: (_dbus_marshal_get_arg_end_pos),
152 (_dbus_marshal_validate_arg):
155 * dbus/dbus-message.c: (dbus_message_set_sender):
156 Remove todo about being able to set sender to NULL.
158 (dbus_message_set_is_error_reply),
159 (dbus_message_get_is_error_reply):
160 * dbus/dbus-message.h:
163 * dbus/dbus-protocol.h:
164 Add error reply flag.
166 * test/data/valid-messages/opposite-endian.message:
167 Add NIL type to test.
169 2003-01-31 Havoc Pennington <hp@pobox.com>
171 * doc/dbus-specification.sgml: fully specify the header. Add
172 flags and major protocol version, and change header/body len to
175 * dbus/dbus-message-builder.c (append_saved_length): append length
178 * dbus/dbus-message.c (dbus_message_create_header): change header
179 length and body length to unsigned. Add the new fields from the
181 (_dbus_message_loader_return_buffer): unsigned header/body len
183 2003-01-30 Havoc Pennington <hp@pobox.com>
185 * dbus/dbus-auth.c: rework to use only REJECTED, no
188 * doc/dbus-sasl-profile.txt: drop MECHANISMS and just
189 use REJECTED, suggested by Mark McLoughlin
191 2003-01-30 Havoc Pennington <hp@pobox.com>
193 * dbus/dbus-server.c (dbus_server_listen): @todo about how we need
194 a better way to report errors here. e.g. "unix address lacks
195 path" or something. also "no such file" when the path doesn't
198 * dbus/dbus-address.c (dbus_address_entries_free): add @todo about
200 (dbus_parse_address): add @todo about documenting address format,
201 and allowing , and ; to be escaped
203 2003-01-30 Anders Carlsson <andersca@codefactory.se>
206 Add dbus-address.[ch]
208 * dbus/dbus-address.c: (dbus_address_entry_free),
209 (dbus_address_entries_free), (create_entry),
210 (dbus_address_entry_get_method), (dbus_address_entry_get_value),
211 (dbus_parse_address), (_dbus_address_test):
212 * dbus/dbus-address.h:
213 New files for dealing with address parsing.
215 * dbus/dbus-connection.c:
216 Document timeout functions.
218 * dbus/dbus-message.c:
219 Document dbus_message_new_from_message.
221 * dbus/dbus-server-debug.c:
224 * dbus/dbus-server.c: (dbus_server_listen):
225 Parse address and use correct server implementation.
227 * dbus/dbus-string.c: (_dbus_string_find_to), (_dbus_string_test):
228 * dbus/dbus-string.h:
229 New function with test.
231 * dbus/dbus-test.c: (dbus_internal_symbol_do_not_use_run_tests):
235 * dbus/dbus-transport-debug.c:
238 * dbus/dbus-transport.c: (_dbus_transport_open):
239 Parse address and use correct transport implementation.
241 2003-01-30 Havoc Pennington <hp@pobox.com>
243 * dbus/dbus-message.c: use message->byte_order instead of
244 DBUS_COMPILER_BYTE_ORDER throughout.
245 (dbus_message_create_header): pad header to align the
246 start of the body of the message to 8-byte boundary
248 * dbus/dbus-marshal.h: make all the demarshalers take const
249 DBusString arguments.
251 * dbus/dbus-message.c (_dbus_message_loader_return_buffer):
252 validate message args here, so we don't have to do slow validation
253 later, and so we catch bad messages as they are incoming. Also add
254 better checks on header_len and body_len. Also fill in
257 * dbus/dbus-string.c (_dbus_string_validate_utf8): new (not
258 implemented properly)
259 (_dbus_string_validate_nul): new function to check all-nul
261 * dbus/dbus-marshal.c (_dbus_marshal_get_field_end_pos): rename
262 get_arg_end_pos and remove all validation
263 (_dbus_marshal_validate_arg): actually do validation here.
265 2003-01-29 Havoc Pennington <hp@pobox.com>
267 * dbus/dbus-message.c (check_message_handling): fix assertion
268 failure on set_client_serial
270 2003-01-28 Havoc Pennington <hp@pobox.com>
272 * dbus/dbus-server-debug.c: Add doc section comments
274 * dbus/dbus-transport-debug.c: add doc section comments
276 2003-01-28 Havoc Pennington <hp@redhat.com>
278 * dbus/dbus-string.c (_dbus_string_base64_decode): append bytes in
279 the reverse order from how I had it
280 (_dbus_string_base64_encode): reverse encoding order. I was
281 basically byteswapping everything during encoding.
283 2003-01-28 Anders Carlsson <andersca@codefactory.se>
285 * dbus/dbus-connection-internal.h:
286 * dbus/dbus-connection.c: (_dbus_connection_add_timeout),
287 (_dbus_connection_remove_timeout):
288 Add functions for adding and removing timeouts.
290 * dbus/dbus-message.c: (dbus_message_new_from_message):
291 Add new function that takes a message and creates an exact
292 copy of it, but with the refcount set to 1.
293 (check_message_handling):
296 * dbus/dbus-server-protected.h:
297 * dbus/dbus-server.c: (_dbus_server_init_base),
298 (_dbus_server_finalize_base), (_dbus_server_add_timeout),
299 (dbus_server_set_timeout_functions):
300 (_dbus_server_remove_timeout):
301 New functions so that a server can add and remove timeouts.
303 (dbus_server_listen):
304 Add commented out call to dbus_server_debug_new.
306 * dbus/dbus-timeout.c: (_dbus_timeout_new):
307 Actually set the handler, doh.
309 * dbus/dbus-transport.c: (_dbus_transport_open):
310 Add commented out call to dbus_transport_debug_client_new.
313 Add dbus-transport-debug.[ch] and dbus-server-debug.[ch]
315 2003-01-28 Havoc Pennington <hp@pobox.com>
317 * dbus/dbus-message.c (check_message_handling): function to check
318 on the loaded message, iterates over it etc.
320 2003-01-28 Havoc Pennington <hp@pobox.com>
322 * test/Makefile.am (dist-hook): fix make distdir
324 * dbus/Makefile.am (TESTS_ENVIRONMENT): fix make check
326 2003-01-27 Havoc Pennington <hp@pobox.com>
328 * dbus/dbus-mempool.c (time_for_size): replace printf with
331 * dbus/dbus-message-builder.c (_dbus_message_data_load): allow
332 empty lines; fix the SAVE_LENGTH stuff to be
333 START_LENGTH/END_LENGTH so it actually works; couple other
336 * test/Makefile.am (dist-hook): add dist-hook for .message files
338 * dbus/dbus-string.c (DBUS_STRING_COPY_PREAMBLE): source of a copy
339 can be constant or locked.
340 (_dbus_string_free): allow freeing a const string as
343 * dbus/dbus-sysdeps.c (_dbus_concat_dir_and_file): utility
345 * dbus/dbus-test-main.c (main): take an argument which is the
346 directory containing test data
348 * dbus/dbus-message.c (_dbus_message_test): pass a test_data_dir
349 argument to this and load all the messages in test/data/
350 checking that they can be loaded or not loaded as appropriate.
352 2003-01-27 Anders Carlsson <andersca@codefactory.se>
354 * bus/dispatch.c: (bus_dispatch_message_handler):
355 Dispatch messages sent to services.
357 * bus/driver.c: (bus_driver_send_service_deleted),
358 (bus_driver_send_service_created), (bus_driver_send_service_lost),
359 (bus_driver_send_service_acquired):
360 Add helper functions for sending service related messages.
362 (bus_driver_send_welcome_message):
363 Send HELLO_REPLY instead of WELCOME.
365 (bus_driver_handle_list_services):
366 Send LIST_SERVICES_REPLY instead of SERVICES.
368 (bus_driver_handle_own_service),
369 (bus_driver_handle_service_exists):
370 New message handlers.
372 (bus_driver_handle_message):
373 Invoke new message handlers.
375 (bus_driver_remove_connection):
376 Don't remove any services here since that's done automatically
377 by bus_service_remove_owner now.
380 New function signatures.
382 * bus/services.c: (bus_service_add_owner):
383 Send ServiceAcquired message if we're the only primary owner.
385 (bus_service_remove_owner):
386 Send ServiceAcquired/ServiceLost messages.
388 (bus_service_set_prohibit_replacement),
389 (bus_service_get_prohibit_replacement):
390 Functions for setting prohibit replacement.
392 (bus_service_has_owner):
393 New function that checks if a connection is in the owner queue of
397 Add new function signatures.
399 * dbus/dbus-list.c: (_dbus_list_test):
400 Add tests for _dbus_list_remove_last and traversing the list backwards.
403 Fix a typo in _dbus_list_get_prev_link, if we're at the first element we can't
404 go any further, so return NULL then.
406 * dbus/dbus-protocol.h:
407 Add new messages, service flags and service replies.
409 2003-01-26 Havoc Pennington <hp@pobox.com>
411 * dbus/dbus-message-builder.c: implement, completely untested.
413 * test/data/*: add data to be used in testing.
414 ".message" files are our simple loadable text format.
415 ".message-raw" will be binary dumps of messages.
417 * dbus/dbus-string.c (_dbus_string_starts_with_c_str): new
419 2003-01-26 Havoc Pennington <hp@pobox.com>
421 * dbus/dbus-sysdeps.c (_dbus_file_get_contents): new function
423 * dbus/dbus-errors.c (dbus_result_to_string): add
426 * dbus/dbus-message-builder.c: new file, will contain code to load
427 up messages from files. Not implemented yet.
429 2003-01-26 Havoc Pennington <hp@pobox.com>
431 * dbus/dbus-message.c (dbus_message_set_sender): support deleting
432 the sender by setting to NULL
434 2003-01-26 Havoc Pennington <hp@pobox.com>
436 The unit tests pass, but otherwise untested. If it breaks, the
437 tests should have been better. ;-)
439 * bus/driver.c (bus_driver_handle_hello): return if we disconnect
442 * dbus/dbus-message.c: redo everything so we maintain
443 message->header as the only copy of the various fields.
444 This avoids the possibility of out-of-memory in some cases,
445 for example dbus_message_lock() can't run out of memory anymore,
446 and avoids extra copying. Figured I may as well go ahead and do
447 this since it was busted for dbus_message_lock to not return
448 failure on OOM, and dbus_message_write_header was totally
449 unchecked for OOM. Also fixed some random other bugs.
451 * dbus/dbus-marshal.c (_dbus_marshal_get_field_end_pos): verify
452 that strings are nul-terminated. Also, end_pos can be equal
453 to string length just not greater than, I think.
454 (_dbus_marshal_set_int32): new function
455 (_dbus_marshal_set_uint32): new function
456 (_dbus_marshal_set_string): new function
458 * dbus/dbus-connection.c (_dbus_connection_new_for_transport): fix
459 a warning, init timeout_list to NULL
460 (dbus_connection_send_message): don't use uninitialized variable
463 * dbus/dbus-string.c (_dbus_string_replace_len): new function
465 2003-01-26 Anders Carlsson <andersca@codefactory.se>
467 * bus/driver.c: (bus_driver_handle_hello),
468 (bus_driver_send_welcome_message):
471 2003-01-26 Anders Carlsson <andersca@codefactory.se>
473 * dbus/dbus-auth.c: (process_auth), (_dbus_auth_unref):
474 * dbus/dbus-connection.c: (_dbus_connection_new_for_transport),
475 (dbus_connection_unref):
476 * dbus/dbus-marshal.c: (_dbus_marshal_test):
477 * dbus/dbus-message.c: (dbus_message_unref),
480 (dbus_message_get_fields):
481 Remove debugging printout.
483 (_dbus_message_loader_return_buffer):
484 Don't store the header string.
486 (_dbus_message_test):
489 2003-01-26 Richard Hult <rhult@codefactory.se>
491 * glib/dbus-gmain.c (dbus_connection_dispatch): Traverse a copy of
492 the file descriptor list, since it can change under us.
494 2003-01-25 Anders Carlsson <andersca@codefactory.se>
496 * glib/dbus-gmain.c: (dbus_connection_prepare),
497 (dbus_connection_check), (dbus_connection_dispatch), (add_watch),
498 (remove_watch), (dbus_connection_hookup_with_g_main):
499 Rewrite the glib handling to use its own GSource instead of a
500 GIOChannel so we can catch messages put in the queue while waiting
503 2003-01-25 Anders Carlsson <andersca@codefactory.se>
506 * bus/connection.c: (connection_disconnect_handler),
507 (connection_watch_callback), (bus_connection_setup):
508 * bus/dispatch.c: (send_one_message),
509 (bus_dispatch_broadcast_message), (bus_dispatch_message_handler),
510 (bus_dispatch_add_connection), (bus_dispatch_remove_connection):
512 * bus/driver.c: (bus_driver_send_service_deleted),
513 (bus_driver_send_service_created), (bus_driver_handle_hello),
514 (bus_driver_send_welcome_message),
515 (bus_driver_handle_list_services), (bus_driver_remove_connection),
516 (bus_driver_handle_message):
518 Refactor code, put the message dispatching in its own file. Use
519 _DBUS_HANDLE_OOM. Also send ServiceDeleted messages when a client
522 2003-01-25 Anders Carlsson <andersca@codefactory.se>
524 * dbus/dbus-internals.h:
525 Add _DBUS_HANDLE_OOM macro, it doesn't do anything currently.
527 * dbus/dbus-message.c: (dbus_message_get_sender):
528 * dbus/dbus-message.h:
529 Implement dbus_message_get_sender.
531 * dbus/dbus-protocol.h:
532 Add message and service defines.
534 2003-01-25 Anders Carlsson <andersca@codefactory.se>
536 * dbus/dbus-connection.c: (dbus_connection_send_message):
537 * dbus/dbus-message-internal.h:
538 * dbus/dbus-message.c: (_dbus_message_get_client_serial),
539 (dbus_message_write_header):
540 Remove _dbus_messag_unlock and don't set the client serial on a
541 message if one already exists.
543 2003-01-24 Havoc Pennington <hp@pobox.com>
545 * dbus/dbus-list.c (alloc_link): put a thread lock on the global
548 * bus/driver.c (bus_driver_handle_list_services): fix a leak
551 2003-01-25 Anders Carlsson <andersca@codefactory.se>
553 * dbus/dbus-list.c: (alloc_link), (free_link):
554 Use a memory pool for the links.
556 2003-01-25 Anders Carlsson <andersca@codefactory.se>
558 * bus/connection.c: (bus_connection_foreach):
560 Add new bus_connection_foreach function.
562 * bus/driver.c: (send_one_message), (bus_driver_broadcast_message):
563 Add function that broadcasts a message to all clients.
565 (bus_driver_send_service_created), (bus_driver_handle_hello),
566 (bus_driver_send_welcome_message),
567 (bus_driver_handle_list_services), (bus_driver_message_handler):
568 Implement functions that take care of listing services, and notifying
569 clients when new services are created.
571 * bus/services.c: (bus_services_list):
573 Add new function that returns an array of strings with the currently
578 Update copyright year.
580 2003-01-25 Anders Carlsson <andersca@codefactory.se>
582 * dbus/dbus-connection.c: (dbus_connection_send_message):
583 Unlock the message in case it was sent earlier.
585 (dbus_connection_send_message_with_reply_and_block):
586 Remove the reply message from the list.
588 * dbus/dbus-marshal.c: (_dbus_demarshal_string_array):
589 Set array_len and new_pos correctly.
591 (_dbus_marshal_test):
594 * dbus/dbus-message-internal.h:
595 * dbus/dbus-message.c: (_dbus_message_get_reply_serial):
596 New function that returns the reply serial.
598 (_dbus_message_unlock):
599 New function that unlocks a message and resets its header.
601 (dbus_message_append_string_array),
602 (dbus_message_get_fields_valist),
603 (dbus_message_iter_get_field_type),
604 (dbus_message_iter_get_string_array),
605 (dbus_message_get_fields),
606 (dbus_message_append_fields_valist):
607 Handle string arrays.
609 (dbus_message_set_sender):
610 Make this function public since the bus daemon needs it.
612 (decode_header_data):
613 Set the reply serial to -1 initially.
615 * dbus/dbus-message.h:
616 Add dbus_message_set_sender.
618 2003-01-24 Havoc Pennington <hp@pobox.com>
620 * doc/dbus-specification.sgml: add some stuff
622 2003-01-22 Havoc Pennington <hp@pobox.com>
624 * doc/dbus-specification.sgml: Start to document the protocol.
626 2003-01-22 Havoc Pennington <hp@pobox.com>
628 * dbus/dbus-connection.c
629 (dbus_connection_send_message_with_reply_and_block): add some @todo
631 * bus/driver.c (bus_driver_add_connection): add a FIXME about memleak
633 2003-01-21 Havoc Pennington <hp@pobox.com>
635 (patch untested because can't compile)
637 * bus/driver.c (create_unique_client_name): make this function
638 never recycle client names. Also, caller should initialize
641 * dbus/dbus-sysdeps.c (_dbus_get_current_time): new function
643 2003-01-21 Anders Carlsson <andersca@codefactory.se>
645 * dbus/dbus-marshal.c: (_dbus_marshal_double),
646 (_dbus_marshal_int32), (_dbus_marshal_uint32),
647 (_dbus_marshal_int32_array), (_dbus_marshal_uint32_array),
648 (_dbus_marshal_double_array), (_dbus_marshal_string_array),
649 (_dbus_demarshal_int32_array), (_dbus_demarshal_uint32_array),
650 (_dbus_demarshal_double_array), (_dbus_demarshal_string_array),
651 (_dbus_marshal_get_field_end_pos), (_dbus_marshal_test):
652 * dbus/dbus-marshal.h:
653 * dbus/dbus-protocol.h:
654 Add support for marshalling and demarshalling integer, double
657 2003-01-21 Anders Carlsson <andersca@codefactory.se>
662 * bus/connection.c: (connection_disconnect_handler):
663 Remove the connection from the bus driver's list.
665 (connection_watch_callback): Dispatch messages.
667 (free_connection_data): Free connection name.
669 (bus_connection_setup): Add connection to the bus driver's list.
670 (bus_connection_remove_owned_service):
671 (bus_connection_set_name), (bus_connection_get_name):
672 Add functions for setting and getting the connection's name.
675 Add function headers.
677 * bus/driver.c: (create_unique_client_name),
678 (bus_driver_handle_hello_message),
679 (bus_driver_send_welcome_message), (bus_driver_message_handler),
680 (bus_driver_add_connection), (bus_driver_remove_connection):
683 * bus/services.c: (bus_service_free):
685 New file that handles communication and registreation with the bus
688 2003-01-21 Anders Carlsson <andersca@codefactory.se>
690 * dbus/dbus-connection.c: (dbus_connection_send_message):
691 Add a new client_serial parameter.
693 (dbus_connection_send_message_with_reply):
694 Remove a @todo since we've implemented the blocking function.
696 (dbus_connection_send_message_with_reply_and_block):
697 New function that sends a message and waits for a reply and
698 then returns the reply.
700 * dbus/dbus-connection.h:
703 * dbus/dbus-errors.c: (dbus_result_to_string):
704 * dbus/dbus-errors.h:
707 * dbus/dbus-message-internal.h:
708 * dbus/dbus-message.c: (_dbus_message_get_reply_serial),
709 (_dbus_message_set_sender), (dbus_message_write_header),
710 (dbus_message_new_reply), (decode_header_data),
711 (_dbus_message_loader_return_buffer), (_dbus_message_test):
712 * dbus/dbus-message.h:
713 Add new functions that set the reply serial and sender.
714 Also marshal and demarshal them correctly and add test.
716 * dbus/dbus-protocol.h:
717 Add new DBUS_MESSAGE_TYPE_SENDER.
720 * glib/dbus-gmain.c: (watch_callback), (free_callback_data),
721 (add_watch), (remove_watch), (add_timeout), (remove_timeout),
722 (dbus_connection_hookup_with_g_main):
723 * glib/test-dbus-glib.c: (main):
724 Rewrite to use GIOChannel and remove the GSource crack.
726 * test/echo-client.c: (main):
727 * test/watch.c: (check_messages):
728 Update for changed APIs
730 2003-01-19 Anders Carlsson <andersca@codefactory.se>
732 * dbus/Makefile.am: Add dbus-timeout.[cħ]
734 * dbus/dbus-connection.c: (_dbus_connection_new_for_transport):
735 Create a DBusTimeoutList.
736 (dbus_connection_set_timeout_functions): Add new function to
737 set timeout callbacks
739 * dbus/dbus-connection.h: Add public DBusTimeout API.
741 * dbus/dbus-message.c: (dbus_message_get_service):
742 * dbus/dbus-message.h: New function.
744 * dbus/dbus-server.c: Fix small doc typo.
746 * dbus/dbus-timeout.[ch]: New files for mainloop timeouts.
748 2003-01-19 Anders Carlsson <andersca@codefactory.se>
750 * dbus/dbus-string.c (_dbus_string_move_len): Don't delete all
751 of the string, just as long as specified.
753 2003-01-19 Havoc Pennington <hp@pobox.com>
755 * dbus/dbus-connection.c (dbus_connection_get_is_authenticated):
758 * dbus/dbus-server.c (dbus_server_set_max_connections)
759 (dbus_server_get_max_connections, dbus_server_get_n_connections):
760 keep track of current number of connections, and add API for
761 setting a max (but haven't implemented enforcing the max yet)
763 2003-01-18 Havoc Pennington <hp@pobox.com>
765 * dbus/dbus-transport-unix.c (unix_do_iteration): only do the
766 reading/writing if read_watch != NULL or write_watch != NULL.
768 * dbus/dbus-message.c (_dbus_message_loader_return_buffer): fix
769 the message loader code to actually load message->header and
770 message->body into the newly-created message.
772 * dbus/dbus-transport-unix.c (check_write_watch): fix a mem leak
775 * dbus/dbus-connection.c (dbus_connection_set_max_message_size)
776 (dbus_connection_get_max_message_size)
777 (dbus_connection_set_max_live_messages_size)
778 (dbus_connection_get_max_live_messages_size): implement some
779 resource limitation functions
781 * dbus/dbus-resources.c: new file implementing some of the
782 resource limits stuff
784 * dbus/dbus-message.c (dbus_message_iter_get_byte_array): add
785 missing docs, add @todo to handle OOM etc.
787 * dbus/dbus-marshal.c (_dbus_demarshal_byte_array): add missing
790 2003-01-18 Havoc Pennington <hp@pobox.com>
792 * dbus/dbus-connection.c (dbus_connection_unref): disconnect the
793 connection if it hasn't been already.
795 * dbus/dbus-connection.h: kill off the idea of an ErrorFunction,
796 replace with DisconnectFunction.
798 2003-01-18 Havoc Pennington <hp@pobox.com>
800 Building --disable-verbose-mode --disable-asserts --disable-tests
801 cuts the library from 112K to 45K or so
803 * configure.in: check for varargs macro support,
804 add --enable-verbose-mode, --enable-asserts.
806 * dbus/dbus-internals.h (_dbus_assert): support
808 (_dbus_verbose): support DBUS_ENABLE_VERBOSE_MODE
810 2003-01-18 Havoc Pennington <hp@pobox.com>
812 * dbus/dbus-test.c: include config.h so that tests actually run
814 * dbus/dbus-string.c: add assertions that stuff is 8-byte aligned,
815 so the failure mode when that assumption fails will be plenty
818 2003-01-18 Havoc Pennington <hp@pobox.com>
820 * configure.in: default --enable-tests to $USE_MAINTAINER_MODE
822 * dbus/Makefile.am: fix it up so dubs-test-main.c is included in
825 * test/Makefile.am: don't use special variable "TESTS" for echo-*
826 since we don't want to use those in make check
828 2003-01-15 Havoc Pennington <hp@redhat.com>
834 2003-01-15 Havoc Pennington <hp@redhat.com>
836 * test/Makefile.am: fix so that test source code ends up in the
837 distribution on make distcheck
839 2003-01-15 Havoc Pennington <hp@redhat.com>
845 2003-01-15 Havoc Pennington <hp@redhat.com>
847 * dbus/dbus-test.c (dbus_internal_symbol_do_not_use_run_tests):
848 fix build when --disable-tests
850 * Makefile.am (EXTRA_DIST): put HACKING in here
852 * HACKING: document procedure for making a tarball release.
854 2003-01-14 Anders Carlsson <andersca@codefactory.se>
856 * bus/connection.c: (connection_error_handler),
857 (bus_connection_setup):
858 * bus/main.c: (main):
859 Make sure that the DBusConnectionData struct is NULLed
860 out to prevent a segfault.
862 * dbus/dbus-errors.c: (dbus_result_to_string):
863 * dbus/dbus-errors.h:
864 * dbus/dbus-message.c: (dbus_message_get_fields),
865 (dbus_message_get_fields_valist), (_dbus_message_test):
866 * dbus/dbus-message.h:
867 Make dbus_message_get_fields return a result code so we can
868 track invalid fields as well as oom.
870 2003-01-11 Havoc Pennington <hp@pobox.com>
872 * configure.in: change --enable-test/--enable-ansi action-if-given
873 to enable_foo=$enableval instead of enable_foo=yes
875 2003-01-08 Havoc Pennington <hp@pobox.com>
877 * dbus/dbus-string.c (_dbus_string_align_length): new function
879 * dbus/dbus-test-main.c: move main() for test app here
881 (dbus_internal_symbol_do_not_use_run_tests): we have to export a
882 symbol to run tests, because dbus-test isn't in the main
885 Code review nitpicks.
887 * dbus/dbus-message.c (dbus_message_write_header): add newlines
888 for people with narrow emacs ;-). Assert client_serial was filled
889 in. Assert message->name != NULL.
890 (dbus_message_append_fields): have "first_field_type" arg separate
891 from va list, needed for C++ binding that also uses varargs IIRC
892 and helps with type safety
893 (dbus_message_new): add @todo about using DBusString to store
894 service/name internally
895 (dbus_message_new): don't leak ->service and ->name on OOM later
897 (dbus_message_unref): free the service name
898 (dbus_message_get_fields): same change to varargs
899 i.e. first_field_type
900 (_dbus_message_loader_return_buffer): assert that the message data
901 is aligned (if not it's a bug in our code). Put in verbose griping
902 about why we set corrupted = TRUE.
903 (decode_header_data): add FIXME that char* is evil. Was going to
904 add FIXME about evil locale-specific string.h strncmp, but just
905 switched to wacky string-as-uint32 optimization. Move check for
906 "no room for field name" above get_const_data_len() to avoid
907 assertion failure in get_const_data_len if we have trailing 2
908 bytes or the like. Check for service and name fields being
909 provided twice. Don't leak service/name on error. Require field
910 names to be aligned to 4 bytes.
912 * dbus/dbus-marshal.c: move byte swap stuff to header
913 (_dbus_pack_int32): uscore-prefix
914 (_dbus_unpack_int32): uscore-prefix
915 (_dbus_unpack_uint32): export
916 (_dbus_demarshal_string): add @todo complaining about use of
918 (_dbus_marshal_get_field_end_pos): add @todo about bad error
919 handling allowing corrupt data to go unchecked
921 2003-01-08 Havoc Pennington <hp@redhat.com>
923 * dbus/dbus-transport-unix.c (unix_do_iteration): add read/write
924 to the select() as needed for authentication. (should be using
925 _dbus_poll() not select, but for another day)
927 * dbus/dbus.h: include dbus/dbus-protocol.h
929 2003-01-08 Anders Carlsson <andersca@codefactory.se>
931 * dbus/Makefile.am (dbusinclude_HEADERS): Install
934 2003-01-08 Anders Carlsson <andersca@codefactory.se>
936 * dbus/dbus-internals.c: (_dbus_type_to_string):
937 New function that returns a string describing a type.
939 * dbus/dbus-marshal.c: (_dbus_demarshal_byte_array):
940 * dbus/dbus-marshal.h:
941 * dbus/dbus-message.c: (dbus_message_get_fields_valist),
942 (dbus_message_iter_get_field_type), (dbus_message_iter_get_double),
943 (dbus_message_iter_get_byte_array):
944 * dbus/dbus-message.h:
945 Add new convenience functions for appending and getting message fields.
946 Also add demarshalling routines for byte arrays.
948 2003-01-07 Anders Carlsson <andersca@codefactory.se>
950 * dbus/dbus-connection-internal.h:
951 * dbus/dbus-connection.c: (_dbus_connection_new_for_transport),
952 (_dbus_connection_get_next_client_serial),
953 (dbus_connection_send_message):
954 * dbus/dbus-internals.h:
955 * dbus/dbus-marshal.c: (unpack_uint32), (dbus_unpack_int32),
956 (dbus_pack_int32), (_dbus_marshal_double), (_dbus_marshal_int32),
957 (_dbus_marshal_uint32), (_dbus_demarshal_double),
958 (_dbus_demarshal_int32), (_dbus_demarshal_uint32),
959 (_dbus_demarshal_string), (_dbus_marshal_get_field_end_pos),
960 (_dbus_verbose_bytes), (_dbus_marshal_test):
961 * dbus/dbus-marshal.h:
962 * dbus/dbus-message-internal.h:
963 * dbus/dbus-message.c: (_dbus_message_set_client_serial),
964 (dbus_message_write_header), (_dbus_message_lock),
965 (dbus_message_new), (dbus_message_ref), (dbus_message_unref),
966 (dbus_message_get_name), (dbus_message_append_int32),
967 (dbus_message_append_uint32), (dbus_message_append_double),
968 (dbus_message_append_string), (dbus_message_append_byte_array),
969 (dbus_message_get_fields_iter), (dbus_message_iter_ref),
970 (dbus_message_iter_unref), (dbus_message_iter_has_next),
971 (dbus_message_iter_next), (dbus_message_iter_get_field_type),
972 (dbus_message_iter_get_string), (dbus_message_iter_get_int32),
973 (dbus_message_iter_get_uint32), (dbus_message_iter_get_double),
974 (decode_header_data), (_dbus_message_loader_return_buffer),
975 (message_iter_test), (_dbus_message_test):
976 * dbus/dbus-message.h:
977 * dbus/dbus-protocol.h:
978 * dbus/dbus-test.c: (main):
980 * glib/test-dbus-glib.c: (message_handler), (main):
981 * test/echo-client.c: (main):
982 * test/watch.c: (check_messages):
983 Make messages sendable and receivable for real.
985 2003-01-07 Anders Carlsson <andersca@codefactory.se>
987 * dbus/dbus-marshal.c: (_dbus_marshal_double),
988 (_dbus_marshal_string), (_dbus_marshal_byte_array):
989 * dbus/dbus-message.c: (dbus_message_append_int32),
990 (dbus_message_append_uint32), (dbus_message_append_double),
991 (dbus_message_append_string), (dbus_message_append_byte_array):
992 Handle OOM restoration.
994 2003-01-07 Anders Carlsson <andersca@codefactory.se>
996 * dbus/dbus-marshal.c: (_dbus_marshal_string),
997 (_dbus_demarshal_string), (_dbus_marshal_test):
998 * dbus/dbus-marshal.h:
999 * dbus/dbus-message.c: (dbus_message_get_name),
1000 Document these functions.
1002 (dbus_message_append_int32), (dbus_message_append_uint32),
1003 (dbus_message_append_double), (dbus_message_append_string),
1004 (dbus_message_append_byte_array):
1005 * dbus/dbus-message.h:
1006 Add functions for adding message fields of different types.
1008 * dbus/dbus-protocol.h:
1009 Add the different types.
1011 2003-01-05 Havoc Pennington <hp@pobox.com>
1013 * bus/connection.c: implement routines for handling connections,
1014 first thing is keeping a list of owned services on each connection
1015 and setting up watches etc.
1017 * bus/services.c: implement a mapping from service names to lists
1020 * dbus/dbus-hash.c: add DBUS_HASH_POINTER
1022 * dbus/dbus-threads.c (dbus_static_mutex_lock): add functions
1023 to use static mutexes for global data
1025 * dbus/dbus-connection.c (dbus_connection_set_data): add new
1026 collection of functions to set/get application-specific data
1027 on the DBusConnection.
1029 2003-01-04 Havoc Pennington <hp@pobox.com>
1031 * dbus/dbus-sysdeps.c (_dbus_sleep_milliseconds): new function
1032 (_dbus_poll): new function
1034 * dbus/dbus-internals.h (_DBUS_STRUCT_OFFSET): new macro
1037 * bus/loop.c: initial code for the daemon main loop
1039 2003-01-04 Havoc Pennington <hp@pobox.com>
1041 * test/watch.c (error_handler): make it safe if the error handler
1042 is called multiple times (if we s/error handler/disconnect
1043 handler/ we should just guarantee it's called only once)
1045 * dbus/dbus-transport.c (_dbus_transport_disconnect): call the
1046 error handler on disconnect (it's quite possible we should
1047 just change the error handler to a "disconnect handler," I'm
1048 not sure we have any other meaningful errors)
1050 * configure.in: check for getpwnam_r
1052 * dbus/dbus-transport.c, dbus/dbus-transport-unix.c,
1053 dbus/dbus-auth.c: add credentials support, add EXTERNAL auth
1054 mechanism as in SASL spec, using socket credentials
1056 * dbus/dbus-sysdeps.c (_dbus_read_credentials_unix_socket): new function
1057 (_dbus_send_credentials_unix_socket): new function
1059 * dbus/dbus-sysdeps.c (_dbus_accept_unix_socket): rename just
1061 (_dbus_write): only check errno if <0 returned
1062 (_dbus_write_two): ditto
1064 2003-01-02 Anders Carlsson <andersca@codefactory.se>
1066 * dbus/dbus-marshal.c: (_dbus_marshal_utf8_string),
1067 (_dbus_marshal_byte_array), (_dbus_demarshal_utf8_string),
1068 (_dbus_marshal_test):
1069 * dbus/dbus-marshal.h:
1070 Add _dbus_marshal_byte_array and rename _dbus_marshal_string
1071 to _dbus_marshal_utf8_string. Also fix some tests.
1073 2002-12-28 Harri Porten <porten@kde.org>
1075 * configure.in: added check for C++ compiler and a very cheesy
1076 check for the Qt integration
1078 * Makefile.am (SUBDIRS): compile qt subdir if support is enabled
1080 * qt/Makefile.am: added
1082 * qt/.cvsignore: added
1084 * qt/dbus-qthread.cc, qt/dbus-qthread.cpp: renamed former to
1085 latter, added #ifdef QT_THREAD_SUPPORT guard.
1087 * dbus/Makefile.am: added missing headers for make dist
1089 2002-12-28 Kristian Rietveld <kris@gtk.org>
1091 * dbus/Makefile.am: fixup export-symbols-regex.
1093 2002-12-27 Anders Carlsson <andersca@codefactory.se>
1095 * acinclude.m4: Add this file and put the
1096 PKG_CHECK_MODULE macro in it.
1098 2002-12-27 Anders Carlsson <andersca@codefactory.se>
1100 * dbus/dbus-marshal.c: (_dbus_marshal_string),
1101 (_dbus_demarshal_double), (_dbus_demarshal_int32),
1102 (_dbus_demarshal_uint32), (_dbus_demarshal_string),
1103 (_dbus_marshal_test):
1104 Make the demarshalling routines align the pos argument.
1105 Add string marshalling tests and fix the obvious bugs
1108 2002-12-26 Havoc Pennington <hp@pobox.com>
1110 * dbus/dbus-auth.c: fixes fixes fixes
1112 * dbus/dbus-transport-unix.c: wire up support for
1113 encoding/decoding data on the wire
1115 * dbus/dbus-auth.c (_dbus_auth_encode_data)
1116 (_dbus_auth_decode_data): append to target string
1117 instead of nuking it.
1119 2002-12-26 Havoc Pennington <hp@pobox.com>
1121 * dbus/dbus-marshal.h (DBUS_COMPILER_BYTE_ORDER): #ifdef
1122 WORDS_BIGENDIAN then compiler byte order is DBUS_BIG_ENDIAN,
1125 * dbus/dbus-marshal.c: Add macros to do int swapping in-place and
1126 avoid swap_bytes() overhead (ignoring possible assembly stuff for
1127 now). Main point is because I wanted unpack_uint32 to implement
1129 (_dbus_verbose_bytes): new function
1131 * dbus/dbus-string.c (_dbus_string_validate_ascii): new function
1133 * dbus/dbus-message.c (_dbus_message_loader_get_is_corrupted): add
1134 mechanism to handle a corrupt message stream
1135 (_dbus_message_loader_new): fix preallocation to only prealloc,
1138 * dbus/dbus-string.c (_dbus_string_skip_blank): fix this function
1139 (_dbus_string_test): enhance tests for copy/move and fix the
1142 * dbus/dbus-transport-unix.c: Hold references in more places to
1143 avoid reentrancy problems
1145 * dbus/dbus-transport.c: ditto
1147 * dbus/dbus-connection.c (dbus_connection_dispatch_message): don't
1148 leak reference count in no-message case
1150 * test/watch.c (do_mainloop): handle adding/removing watches
1151 during iteration over the watches. Also, ref the connection/server
1152 stored on a watch, so we don't try to mangle a destroyed one.
1154 * dbus/dbus-transport-unix.c (do_authentication): perform
1157 * dbus/dbus-auth.c (get_state): add a state
1158 AUTHENTICATED_WITH_UNUSED_BYTES and return it if required
1159 (_dbus_auth_get_unused_bytes): append the unused bytes
1160 to the passed in string, rather than prepend
1162 * dbus/dbus-transport.c (_dbus_transport_init_base): create
1163 the auth conversation DBusAuth
1165 * dbus/dbus-transport-unix.c (_dbus_transport_new_for_fd)
1166 (_dbus_transport_new_for_domain_socket): when creating a
1167 transport, pass in whether it's a client-side or server-side
1168 transport so we know which DBusAuth to create
1170 2002-12-03 Havoc Pennington <hp@pobox.com>
1172 * dbus/dbus-transport-unix.c (unix_finalize): finalize base
1173 _after_ finalizing the derived members
1174 (unix_connection_set): unref watch if we fail to add it
1176 * dbus/dbus-connection.c (dbus_connection_unref): delete the
1177 transport first, so that the connection owned by the
1178 transport will be valid as the transport finalizes.
1180 * dbus/dbus-transport-unix.c (unix_finalize): free the write_watch
1181 if necessary, and remove watches from the connection.
1183 * dbus/dbus-watch.c (_dbus_watch_list_free): improve a comment
1185 2002-12-26 Anders Carlsson <andersca@codefactory.se>
1187 * dbus/dbus-marshal.c: (_dbus_marshal_string),
1188 (_dbus_demarshal_double), (_dbus_demarshal_int32),
1189 (_dbus_demarshal_uint32), (_dbus_demarshal_string),
1190 (_dbus_marshal_test):
1191 * dbus/dbus-marshal.h:
1192 Add string marshal functions and have the demarshal functions
1193 return the new position.
1195 2002-12-25 Havoc Pennington <hp@pobox.com>
1197 * doc/dbus-sasl-profile.txt: docs on the authentication protocol,
1198 it is a simple protocol that just maps directly to SASL.
1200 * dbus/dbus-auth.h, dbus/dbus-auth.c: authentication protocol
1201 initial implementation, not actually used yet.
1203 * dbus/dbus-string.c (_dbus_string_find): new function
1204 (_dbus_string_equal): new function
1205 (_dbus_string_base64_encode): new function
1206 (_dbus_string_base64_decode): new function
1208 2002-12-25 Anders Carlsson <andersca@codefactory.se>
1211 * dbus/dbus-marshal.c: (swap_bytes), (_dbus_marshal_double),
1212 (_dbus_marshal_int32), (_dbus_marshal_uint32),
1213 (_dbus_demarshal_double), (_dbus_demarshal_int32),
1214 (_dbus_demarshal_uint32), (_dbus_marshal_test):
1215 * dbus/dbus-marshal.h:
1216 * dbus/dbus-protocol.h:
1217 * dbus/dbus-test.c: (main):
1219 Add un-optimized marshalling/demarshalling routines.
1221 2002-12-25 Harri Porten <porten@kde.org>
1223 * qt/dbus-qt.h: adjusted ctor and getter to KDE/Qt conventions
1225 2002-12-24 Zack Rusin <zack@kde.org>
1227 * qt/dbus-qthread.cc: adding - integrates QMutex into Dbus
1228 * qt/dbus-qt.h: skeleton with two sample implemenatation of the
1231 2002-12-24 Havoc Pennington <hp@pobox.com>
1233 * glib/dbus-gthread.c: fix include
1235 * glib/dbus-glib.h: rename DBusMessageHandler for now.
1236 I think glib API needs to change, though, as you don't
1237 want to use DBusMessageFunction, you want to use the
1238 DBusMessageHandler object. Probably
1239 dbus_connection_open_with_g_main_loop()
1240 and dbus_connection_setup_g_main_loop() or something like that
1241 (but think of better names...) that just create a connection
1242 that has watch/timeout functions etc. already set up.
1244 * dbus/dbus-connection.c
1245 (dbus_connection_send_message_with_reply): new function just to
1246 show how the message handler helps us deal with replies.
1248 * dbus/dbus-list.c (_dbus_list_remove_last): new function
1250 * dbus/dbus-string.c (_dbus_string_test): free a string that
1253 * dbus/dbus-hash.c: use memory pools for the hash entries
1254 (rebuild_table): be more paranoid about overflow, and
1255 shrink table when we can
1256 (_dbus_hash_test): reduce number of sprintfs and write
1257 valid C89. Add tests for case where we grow and then
1258 shrink the hash table.
1260 * dbus/dbus-mempool.h, dbus/dbus-mempool.c: memory pools
1262 * dbus/dbus-connection.c (dbus_connection_register_handler)
1263 (dbus_connection_unregister_handler): new functions
1265 * dbus/dbus-message.c (dbus_message_get_name): new
1267 * dbus/dbus-list.c: fix docs typo
1269 * dbus/dbus-message-handler.h, dbus/dbus-message-handler.c:
1270 an object representing a handler for messages.
1272 2002-12-16 Anders Carlsson <andersca@codefactory.se>
1275 * glib/dbus-gthread.c: (dbus_gthread_init):
1276 Don't use the gdbus prefix for public functions.
1278 2002-12-16 Anders Carlsson <andersca@codefactory.se>
1282 Add GLib checks and fixup .pc files
1286 * glib/dbus-gmain.c: (gdbus_connection_prepare),
1287 (gdbus_connection_check), (gdbus_connection_dispatch),
1288 (gdbus_add_connection_watch), (gdbus_remove_connection_watch),
1289 (dbus_connection_gsource_new):
1290 * glib/dbus-gthread.c: (dbus_gmutex_new), (dbus_gmutex_free),
1291 (dbus_gmutex_lock), (dbus_gmutex_unlock), (dbus_gthread_init):
1292 * glib/test-dbus-glib.c: (message_handler), (main):
1295 2002-12-15 Harri Porten <porten@kde.org>
1297 * autogen.sh: check for libtoolize before attempting to use it
1299 * dbus/dbus-transport-unix.c: include <sys/time.h> for timeval
1302 * .cvsignore: ignore more stamp files
1304 * dbus/dbus-watch.c (_dbus_watch_list_new): fixed doc error
1306 * test/Makefile.am: added -I$(top_srcdir) to be able to compile
1307 without make install.
1309 2002-12-15 Havoc Pennington <hp@pobox.com>
1311 * dbus/dbus-threads.c: add thread stubs that a higher library
1312 layer can fill in. e.g. the GLib wrapper might fill them in with
1313 GThread stuff. We still need to use this thread API to
1314 thread-safe-ize the library.
1316 2002-12-12 Havoc Pennington <hp@pobox.com>
1318 * dbus/dbus-transport-unix.c, dbus/dbus-server-unix.c: use the
1319 below new interfaces and include fewer system headers.
1321 * dbus/dbus-sysdeps.c (_dbus_read): new function
1322 (_dbus_write): new function
1323 (_dbus_write_two): new function
1324 (_dbus_connect_unix_socket): new function
1325 (_dbus_listen_unix_socket): new function
1327 * dbus/dbus-message-internal.h: change interfaces to use
1330 2002-12-11 Havoc Pennington <hp@pobox.com>
1332 * dbus/dbus-types.h: add dbus_unichar
1334 * dbus/dbus-internals.c (_dbus_verbose): use _dbus_getenv
1336 * dbus/dbus-connection.c (dbus_connection_send_message): return
1339 * dbus/dbus-transport.c: include dbus-watch.h
1341 * dbus/dbus-connection.c: include dbus-message-internal.h
1343 * HACKING: add file with coding guidelines stuff.
1345 * dbus/dbus-string.h, dbus/dbus-string.c: Encapsulate all string
1346 handling here, for security purposes (as in vsftpd). Not actually
1347 using this class yet.
1349 * dbus/dbus-sysdeps.h, dbus/dbus-sysdeps.c: Encapsulate all
1350 system/libc usage here, as in vsftpd, for ease of auditing (and
1351 should also simplify portability). Haven't actually moved all the
1352 system/libc usage into here yet.
1354 2002-11-25 Havoc Pennington <hp@pobox.com>
1356 * dbus/dbus-internals.c (_dbus_verbose): fix to not
1357 always print the first verbose message.
1359 2002-11-24 Havoc Pennington <hp@pobox.com>
1361 * test/echo-client.c, test/echo-server.c: cheesy test
1364 * configure.in (AC_CHECK_FUNCS): check for writev
1366 * dbus/dbus-message.c (_dbus_message_get_network_data): new
1369 * dbus/dbus-list.c (_dbus_list_foreach): new function
1371 * dbus/dbus-internals.c (_dbus_verbose): new function
1373 * dbus/dbus-server.c, dbus/dbus-server.h: public object
1374 representing a server that listens for connections.
1376 * dbus/.cvsignore: create
1378 * dbus/dbus-errors.h, dbus/dbus-errors.c:
1379 public API for reporting errors
1381 * dbus/dbus-connection.h, dbus/dbus-connection.c:
1382 public object representing a connection that
1383 sends/receives messages. (Same object used for
1384 both client and server.)
1386 * dbus/dbus-transport.h, dbus/dbus-transport.c:
1387 Basic abstraction for different kinds of stream
1388 that we might read/write messages from.
1390 2002-11-23 Havoc Pennington <hp@pobox.com>
1392 * dbus/dbus-internals.h (_DBUS_INT_MAX): add _DBUS_INT_MIN
1395 * dbus/dbus-test.c (main): add list test, and include
1396 dbus-test.h as intended
1398 * dbus/dbus-hash.c (_dbus_hash_table_remove_string)
1399 (_dbus_hash_table_remove_int): return value indicates
1400 whether the entry existed to remove
1402 * dbus/dbus-list.c: add linked list utility class,
1405 * dbus/dbus-hash.c: add TODO item about shrinking the hash bucket
1408 2002-11-23 Havoc Pennington <hp@pobox.com>
1410 * Doxyfile.in (INCLUDE_FILE_PATTERNS): expand DBUS_BEGIN_DECLS/
1411 DBUS_END_DECLS to nothing, that should fix this once and for all
1413 * Doxyfile.in (JAVADOC_AUTOBRIEF): set to YES
1415 * dbus/dbus-message.c, dbus/dbus-hash.c:
1416 add some missing @brief
1418 2002-11-23 Havoc Pennington <hp@pobox.com>
1420 * dbus/dbus-message.h: put semicolons after DEBUG_BEGIN_DECLS
1421 to avoid confusing Doxygen
1423 * dbus/dbus-hash.c: @} not }@
1425 * dbus/dbus-message.c (struct DBusMessage): split out
1428 2002-11-23 Havoc Pennington <hp@pobox.com>
1430 * configure.in: pile on more warning flags if using gcc
1432 * Doxyfile.in (EXTRACT_STATIC): set to NO, so we don't have
1433 to document static functions
1435 * configure.in: add summary to end of configure so it
1436 looks nice and attractive
1438 * dbus/dbus-hash.c: finish implementation and write unit
1441 * configure.in: add --enable-tests to enable unit tests
1443 * dbus/dbus-test.c: test program to run unit tests
1444 for all files in dbus/*, initially runs a test for
1447 * dbus/dbus-internals.h: file to hold some internal utility stuff
1449 2002-11-22 Havoc Pennington <hp@redhat.com>
1451 * dbus/dbus-hash.c: copy in Tcl hash table, not yet
1452 "ported" away from Tcl
1454 * dbus/dbus-types.h: header for types such as dbus_bool_t
1456 2002-11-22 Havoc Pennington <hp@redhat.com>
1458 * dbus/dbus.h: fixups for doc warnings
1460 * Doxyfile.in (FILE_PATTERNS): we need to scan .h to pick up
1462 (QUIET): make it quiet so we can see warnings
1464 * dbus/dbus-memory.c: teach D-BUS to allocate and free memory
1466 2002-11-22 Havoc Pennington <hp@redhat.com>
1468 * Makefile.am: include "Doxyfile" target in all-local
1470 * configure.in: generate the Doxyfile
1472 * Doxyfile.in: move Doxyfile here, so we can use
1473 configure to generate a Doxyfile with the right
1476 2002-11-22 Havoc Pennington <hp@redhat.com>
1478 * dbus/dbus-message.c: move inline docs into .c file
1480 * Doxyfile (OUTPUT_DIRECTORY): move output to doc/api
1481 so all docs are under doc/
1482 (MAN_EXTENSION): generate man pages. Use extension
1483 ".3dbus" which matches ".3qt" on my system,
1484 I guess this is OK, I don't know really.
1485 (FILE_PATTERNS): look for .c files not .h, makes sense
1488 2002-11-22 Havoc Pennington <hp@pobox.com>
1490 * Makefile.am (SUBDIRS): rename subdir "server" to "bus"
1491 because any app can be a server, and any app can be a client,
1492 the bus is a special kind of server.
1494 Thu Nov 21 23:35:31 2002 Zack Rusin <zack@kde.org>
1496 * Doxyfile : adding. Still needs Makefile rules to be generated
1497 automatically (just run "doxygen" in the toplevel dir for now to
1500 * dbus/dbus-message.h : Adding sample docs (javadoc since
1501 resembles gtk-doc a little more)
1503 * dbus/dbus.h : Adding sample docs
1505 2002-11-21 Havoc Pennington <hp@redhat.com>
1507 * dbus/Makefile.am (INCLUDES): define DBUS_COMPILATION
1508 so we can allow ourselves to include files directly,
1509 instead of having to use dbus.h
1511 * dbus/dbus.h: fill in
1513 * dbus/dbus-message.h: sketch out a sample header file.
1514 Include griping if you include it directly instead of
1517 * dbus/dbus-macros.h: new file with macros for extern "C",
1518 TRUE/FALSE, NULL, etc.
1520 * doc/file-boilerplate.c: put include guards in here
1522 2002-11-21 Havoc Pennington <hp@redhat.com>
1524 * doc/file-boilerplate.c: include both AFL and GPL boilerplate.
1526 * COPYING: include the GPL as well, and license code
1527 under both AFL and GPL.
1529 2002-11-21 Havoc Pennington <hp@redhat.com>
1531 * acconfig.h: get rid of this
1533 * autogen.sh (run_configure): add --no-configure option
1535 * configure.in: remove AC_ARG_PROGRAM to make
1536 autoconf complain less. add AC_PREREQ.
1537 add AC_DEFINE third arg.
1539 2002-11-21 Anders Carlsson <andersca@codefactory.se>
1542 Fix references so we can distcheck.
1544 2002-11-21 Havoc Pennington <hp@redhat.com>
1546 * Initial module creation