summaryrefslogtreecommitdiffstats
path: root/dbus
Commit message (Collapse)AuthorAgeFilesLines
* fix memleak due to autolaunch and recursive calls to _dbus_open_transportJohn (J5) Palmieri2008-04-031-1/+16
| | | | | | * Patch from Sumit <sumitskj_20@yahoo.com>, comments added * dbus/dbus-transport.c(_dbus_transport_open): fix mem leak
* modify dbus_connection_send documentationJohn (J5) Palmieri2008-04-031-6/+12
| | | | | | | | * dbus/dbus-connection.c (dbus_connection_send): add documentation to describe when to call dbus_connection_flush and dbus_connection_unref after a call to dbus_connection_send is made Initial wording by Stanislav Brabec <sbrabec at suse.cz> (fd.o bug#13558)
* Set default exit_on_disconnect after registrationColin Walters2008-03-261-6/+6
| | | | | | | | | | 2008-03-26 Colin Walters <walters@verbum.org> Patch from Scott James Remnant <scott@netsplit.com> * dbus/dbus-bus.c: Set default exit_on_disconnect after registration with the bus, not before. This ensures that programs which wish to set exit_on_disconnect to FALSE will not be terminated if the bus exits during registration. (FDO Bug #15112)
* fix broken poll on Mac OSX - build patch by Benjamin ReedJohn (J5) Palmieri2008-03-041-1/+1
| | | | | | * configure.in: check for OSX's deadlocking poll * dbus/dbus-sysdeps-unix.c (_dbus_poll): if we have a broken poll don't use poll
* define _AI_ADDRCONFIG if not defined so that we can compile with an older glibcJohn (J5) Palmieri2008-02-281-0/+4
|
* correctly unref connections without guids during shutdownJohn (J5) Palmieri2008-02-261-13/+45
| | | | | | | | | | * dbus/dbus-connection.c (close_connection_on_shutdown): new method split out from shared_connections_shutdown (shared_connections_shutdown): shutdown all shared connections without guids (_dbus_connection_ref_unlocked): handle OOM when prepending no guid connections to the shared_connections_no_guid list * Patch by Kimmo Hämäläinen <kimmo dot hamalainen at nokia dot com>
* fix build against the latest gcc/glibcJohn (J5) Palmieri2008-02-211-0/+2
| | | | | | * dbus/dbus-sysdeps-unix.c: define _GNU_SOURCE * bus/selinux.c: include limits.h * Patch by Matthias Clasen <mclasen at redhat.com>
* wrap all_reader_classes[] in #ifndef DBUS_DISABLE_ASSERT (FDO Bug #9030)John (J5) Palmieri2008-01-151-0/+2
| | | | | | | | | | 2008-01-15 John (J5) Palmieri <johnp@redhat.com> * patch by Sébastien Couret <10function at gmail dot com> * dbus/dbus-marshal-recursive.c (all_reader_classes[]): wrap in #ifndef DBUS_DISABLE_ASSERT since it is only used in asserts which are noop
* handle SASL EXTERNAL's inital empty responce (FDO Bug #9945)John (J5) Palmieri2008-01-151-0/+1
| | | | | | | | | 2008-01-15 John (J5) Palmieri <johnp@redhat.com> * patch by Magnus Henoch <henoch plus bfdo at dtek dot chalmers dot se> * dbus/dbus-auth.c (handle_server_data_external_mech): handle SASL EXTERNAL's inital empty responce (FDO Bug #9945)
* check write return value so we don't hang (FDO Bug #11665)John (J5) Palmieri2008-01-151-3/+3
| | | | | | | | | 2008-01-15 John (J5) Palmieri <johnp@redhat.com> * patch by Peter O'Gorman <pogma at thewrittenword dot com> * dbus/dbus-spawn.c (babysit_signal_handler): check write return value so we don't hang (FDO Bug #11665)
* support for AIX poll implementation (FDO Bug #11666)John (J5) Palmieri2008-01-151-0/+27
| | | | | | | | | 2008-01-15 John (J5) Palmieri <johnp@redhat.com> * patch by Peter O'Gorman <pogma at thewrittenword dot com> * dbus/dbus-sysdeps.h: support for AIX poll implementation (FDO Bug #11666)
* don't check for < 0 on an unsigned variable (FDO Bug #12924)John (J5) Palmieri2008-01-151-3/+3
| | | | | | | | | 2008-01-15 John (J5) Palmieri <johnp@redhat.com> * patch by Kimmo Hämäläinen <kimmo dot hamalainen at nokia dot com> * dbus/dbus-connection.c (_dbus_connection_get_next_client_serial): don't check for < 0 on an unsigned variable (FDO Bug #12924)
* the API contract says sitter_p can be NULL, so let's check it (FDO Bug #12919)John (J5) Palmieri2008-01-151-1/+3
| | | | | | | | | 2008-01-15 John (J5) Palmieri <johnp@redhat.com> * patch by Kimmo Hämäläinen <kimmo dot hamalainen at nokia dot com> * dbus/dbus-spawn.c (_dbus_spawn_async_with_babysitter): the API contract says sitter_p can be NULL, so let's check it (FDO Bug #12919)
* use correct ssize_t type instead of size_t (FDO Bug #12862)John (J5) Palmieri2008-01-151-2/+2
| | | | | | | | | 2008-01-15 John (J5) Palmieri <johnp@redhat.com> * patch by Kimmo Hämäläinen <kimmo dot hamalainen at nokia dot com> * dbus/dbus-spawn.c (read_ints, read_pid): use correct ssize_t type instead of size_t (FDO Bug #12862)
* make sure to call va_end if we hit an OOM error inside va_start (FDO Bug #12846)John (J5) Palmieri2008-01-151-0/+1
| | | | | | | | | 2008-01-15 John (J5) Palmieri <johnp@redhat.com> * patch by Kimmo Hämäläinen <kimmo dot hamalainen at nokia dot com> * dbus/dbus-errors.c (dbus_set_error): make sure to call va_end if we hit an OOM error inside va_start (FDO Bug #12846)
* fix possible crash if pending_return is NULL (FDO Bug #12673)John (J5) Palmieri2008-01-151-2/+0
| | | | | | | | | 2008-01-15 John (J5) Palmieri <johnp@redhat.com> * patch by Kimmo Hämäläinen <kimmo dot hamalainen at nokia dot com> * dbus/dbus-connection.c (dbus_connection_send_with_reply): fix possible crash if pending_return is NULL (FDO Bug #12673)
* add OOM handling in various placesJohn (J5) Palmieri2008-01-153-4/+17
| | | | | | | | | | | | | | 2008-01-15 John (J5) Palmieri <johnp@redhat.com> * patches by Kimmo Hämäläinen <kimmo dot hamalainen at nokia dot com> * dbus/dbus-sysdeps-unix (_dbus_get_autolaunch_address): handle OOM (FDO Bug #12945) * dbus/dbus-uuidgen.c (return_uuid): handle OOM (FDO Bug #12928) * dbus/dbus-misc.c (dbus_get_local_machine_id): handle OOM, fix return value to return NULL not FALSE (FDO Bug #12946)
* add OOM handlingJohn (J5) Palmieri2008-01-151-3/+17
| | | | | | | | | 2008-01-15 John (J5) Palmieri <johnp@redhat.com> * patch by Kimmo Hämäläinen <kimmo dot hamalainen at nokia dot com> * dbus/dbus-internals.c (_dbus_read_uuid_file_without_creating, _dbus_create_uuid_file_exclusively): add OOM handling (FDO Bug #12952)
* add error handling when polling (FDO Bug #12954)John (J5) Palmieri2008-01-151-4/+19
| | | | | | | | | 2008-01-15 John (J5) Palmieri <johnp@redhat.com> * patch by Kimmo Hämäläinen <kimmo dot hamalainen at nokia dot com> * dbus/dbus-spawn.c (babysit, babysitter_iteration): add error handling when polling (FDO Bug #12954)
* remove dead codeJohn (J5) Palmieri2008-01-152-67/+0
| | | | | | | | | | | 2008-01-15 John (J5) Palmieri <johnp@redhat.com> * patch by Kimmo Hämäläinen <kimmo dot hamalainen at nokia dot com> * bus/config-parser.c (locate_attributes): remove dead code which always evaluated to TRUE * dbus/dbus-shell.c (_dbus_shell_quote): remove unused code
* return message loader buffer in case of OOM (FDO Bug#12666)John (J5) Palmieri2008-01-141-0/+4
| | | | | | | | | 2008-01-14 John (J5) Palmieri <johnp@redhat.com> * patch by Kimmo Hämäläinen <kimmo dot hamalainen at nokia dot com> * dbus/dbus-transport-socket.c(do_reading): return message loader buffer in case of OOM (FDO Bug#12666)
* add _dbus_geteuid to fix EXTERNAL authentication in setuid applicationsJohn (J5) Palmieri2008-01-144-5/+24
| | | | | | | | | | | | | | | | | | | | | | 2008-01-14 John (J5) Palmieri <johnp@redhat.com> * Patch by Andrea Luzzardi <scox at sig11 dot org>: creates a _dbus_geteuid function to fix EXTERNAL authentication in setuid applications * dbus/dbus-sysdeps-unix.c (_dbus_geteuid): used to get the effective uid of the running program (_dbus_credentials_add_from_current_process): use geteuid instead of getuid (_dbus_append_user_from_current_process): use geteuid instead of getuid * dbus/dbus-sysdeps-util-unix.c (_dbus_change_to_daemon_user): use geteuid instead of getuid (_dbus_unix_user_is_at_console): use geteuid instead of getuid * dbus/dbus-sysdeps-win.c (_dbus_geteuid): add a windows equivilant that returns DBUS_UID_UNSET
* fix some curly braces that were on the wrong lineHavoc Pennington2007-12-181-4/+5
| | | | | | | 2007-12-18 Havoc Pennington <hp@redhat.com> * dbus/dbus-connection.c (_dbus_connection_block_pending_call): fix location of curly braces
* Fix a problem where a nul byte was wrongly introduced into UUIDs, due to ↵Havoc Pennington2007-10-312-7/+30
| | | | | | | | | | | | | | | | | | _dbus_string_copy_to_buffer weird behavior. 2007-10-31 Havoc Pennington <hp@redhat.com> * bus/selinux.c (log_audit_callback): rewrite to use _dbus_string_copy_to_buffer_with_nul() * dbus/dbus-string.c (_dbus_string_copy_to_buffer): change to NOT nul-terminate the buffer; fail an assertion if there is not enough space in the target buffer. This fixes two bugs where copy_to_buffer was used to copy the binary bytes in a UUID, where nul termination did not make sense. Bug reported by David Castelow. (_dbus_string_copy_to_buffer_with_nul): new function that always nul-terminates the buffer, and fails an assertion if there is not enough space in the buffer.
* do not call audit_init() from bus/ directory from files in dbus/Havoc Pennington2007-10-191-1/+0
| | | | | | | | | | | | 2007-10-19 Havoc Pennington <hp@redhat.com> * bus/bus.c (bus_context_new): put the audit_init() in here instead, which I believe ends up being the same as where it was before, though I'm not sure I understand why it goes here. * dbus/dbus-sysdeps-util-unix.c (_dbus_change_to_daemon_user): remove audit_init() from here, this file can't depend on code in bus/ directory
* Use DBUS_ERROR_INIT instead of dbus_error_init wherever it's clearly equivalentSimon McVittie2007-10-1115-115/+52
|
* Merge branch 'atomic'Simon McVittie2007-10-112-3/+13
|\ | | | | | | | | | | Conflicts: ChangeLog
| * Fix detection of i486 atomic ops.Simon McVittie2007-10-112-3/+13
| | | | | | | | | | | | Previously, the attempts to determine support at compile-time on Darwin were causing the i486 atomic ops to be used on *all* i386 or x86-64 GCC builds (AH_VERBATIM can't be conditionalized like we were trying to).
* | Rename DBUS_ERROR_INITIALIZER to DBUS_ERROR_INIT per Havoc's reviewSimon McVittie2007-10-112-3/+3
| |
* | Add DBUS_ERROR_INITIALIZER macroSimon McVittie2007-10-112-1/+25
| |
* | dbus/dbus-server-socket.c: remove unused variable if disabling assertionsSimon McVittie2007-10-111-1/+1
| |
* | dbus/dbus-marshal-validate.c: get rid of empty statementsSimon McVittie2007-10-111-6/+6
| |
* | As per Havoc's review, rename DBUS_GNUC_EXTENSION to _DBUS_GNUC_EXTENSION.Simon McVittie2007-10-112-8/+9
| | | | | | | | Also update ChangeLog.
* | dbus/dbus-arch-deps.h.in: also use DBUS_GNUC_EXTENSION for ↵Simon McVittie2007-10-111-2/+2
| | | | | | | | DBUS_INT64_CONSTANT and UINT64 equivalent
* | Use DBUS_GNUC_EXTENSION to avoid -ansi -pedantic warnings about use of long ↵Simon McVittie2007-10-111-2/+2
| | | | | | | | long. (#717)
* | Add macro DBUS_GNUC_EXTENSION (the same as GLib's G_GNUC_EXTENSION)Simon McVittie2007-10-111-0/+12
|/ | | | Part of a fix for bug 717.
* Fix indentation in _dbus_object_tree_register declaration as per Havoc's reviewSimon McVittie2007-10-101-1/+1
|
* _dbus_object_tree_register: don't duplicate check for NULL and use new ↵Simon McVittie2007-10-101-5/+4
| | | | DBUS_ERROR_OBJECT_PATH_IN_USE error, both as per Havoc's review
* Add error o.fd.D.Error.ObjectPathInUse (DBUS_ERROR_OBJECT_PATH_IN_USE)Simon McVittie2007-10-102-0/+4
|
* Add dbus_connection_try_register_object_path and ↵Simon McVittie2007-10-104-24/+171
| | | | dbus_connection_try_register_fallback, to make object path registration less painful for bindings
* fd.o bug #11678 Don't error out if compiler does not support vararg macrosJohn (J5) Palmieri2007-10-031-1/+1
| | | | | | * _dbus_verbose is the only function that does this so make it a noop if vararg macros are not supported * https://bugs.freedesktop.org/show_bug.cgi?id=11678
* fd.o bug #12429 Reverse check to setpcap and only init audit if we were rootJohn (J5) Palmieri2007-10-031-2/+3
| | | | | | | | | * patch by Dan Walsh <dwalsh@redhat.com> * https://bugs.freedesktop.org/show_bug.cgi?id=12429 * Reverse we_were_root check to setpcap if we were root. Also only init audit if we were root. So error dbus message will not show up when policy reload happens. dbus -session will no longer try to send audit message, only system will.
* fd.o bug #11872 fix clearenv for systems that do not have itJohn (J5) Palmieri2007-10-031-1/+13
| | | | * patch from Brian Cameron <brian.cameron at sun.com>
* Correctly implement -fPIC and -fPIEJohn (J5) Palmieri2007-10-031-2/+2
| | | | | | | | * For security reasons we want possition independent code for libraries and possition independent executable for executables * before we were just enabling -fPIC * now we correctly enable -fPIC and -PIE for libdbus and the bus respectively * propper LD_FLAGS are set for each also
* Add argument path matching support. Bug #11066.Ryan Lortie2007-09-201-0/+7
| | | | | | | | | | | | | | | | | | 2007-09-20 Ryan Lortie <desrt@desrt.ca> * dbus/signals.c (struct DBusMatchRule, bus_match_rule_new, bus_match_rule_set_arg, bus_match_rule_parse_arg_match, match_rule_matches): Add support for parsing and matching on arg0path='/some/path' type rules. * dbus/signals.h (bus_match_rule_set_arg): change to take const DBusString instead of const char * for the string to match against. * dbus/dbus-bus.c: add a quick note to dbus_bus_add_match documentation about the path matching. * doc/dbus-specification.xml: add a more detailed description of the changes here.
* Add support for compacting DBusStrings to release wasted memory.Ryan Lortie2007-09-205-16/+110
| | | | | | | | | | | | | | | | | 2007-09-19 Ryan Lortie <desrt@desrt.ca> * dbus/dbus-string.[ch] (compact, _dbus_string_compact, _dbus_string_lock): new compact function to free up allocated memory that is no longer used. * dbus/dbus-message.c (load_message): call _dbus_string_compact on the message loader buffer. * dbus/dbus-transport-socket.c (do_reading, do_writing): call _dbus_string_compact on the incoming/outgoing "encoded" buffers. * dbus/dbus-string-util.c (_dbus_string_test): add a few tests for string compacting.
* migrate from cvs to git (cvs2svn -> git-svnimport).Ryan Lortie2007-09-131-0/+0
| | | | | | | | | | | 2007-09-13 Ryan Lortie <desrt@desrt.ca> migrate from cvs to git (cvs2svn -> git-svnimport). * HACKING: update release/branch/tag instructions * */.cvsignore: rename to .gitignore also, clean up tags and branch names to conform to HACKING
* 2007-08-17 Havoc Pennington <hp@redhat.com>Havoc Pennington2007-08-172-56/+97
| | | | | | | | | | | | | | | * tools/dbus-launch-x11.c (set_address_in_x11): fix from Michael Lorenz to use long not int with XChangeProperty format 32 * dbus/dbus-sysdeps-util-unix.c (_dbus_write_pid_to_file_and_pipe): factor this out, and use the same code in _dbus_become_daemon (where the parent writes the pid file and to the pid pipe) and in bus_context_new (where the daemon writes its own pid file and to its own pid pipe) * bus/bus.c (bus_context_new): close the pid pipe after we print to it. Also, don't write the pid to the pipe twice when we fork, someone reported this bug a long time ago.
* 2007-08-03 Havoc Pennington <hp@redhat.com>Havoc Pennington2007-08-033-1/+148
| | | | | | | | | | | | * configure.in: add major/minor/micro version number AC_SUBST * dbus/dbus-arch-deps.h.in (DBUS_MAJOR_VERSION, DBUS_MINOR_VERSION, DBUS_MICRO_VERSION, DBUS_VERSION_STRING, DBUS_VERSION): collection of macros to get version of library we are compiled against. * dbus/dbus-misc.c (dbus_get_version): new function, to get version of library we are linked against at runtime.
* Switch over to using getaddrinfo for TCP clients & servers to enable IPv6Daniel P. Berrange2007-07-258-237/+420
|