History log of /external/dbus/bus/services.h
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
5baf2f856a9c6625993234855b07680da1c8916f 11-Jul-2009 Tobias Mueller <fdo-bugs@cryptobitch.de> Bug 21161 - Update the FSF address

No comment.

Signed-off-by: Colin Walters <walters@verbum.org>
/external/dbus/bus/services.h
d012387afef0ba02185ebe27bc6bb15551912e92 14-Jul-2007 Havoc Pennington <hp@redhat.com> 2007-07-13 Havoc Pennington <hp@redhat.com>

* Add indent-tabs-mode: nil to all file headers.
/external/dbus/bus/services.h
1a163e765c0d6a86d2aa2ffb18a1d7e29a052e7a 22-Nov-2005 John (J5) Palmieri <johnp@redhat.com> * configure.in: Add test/name-test/Makefile to the generated
Makefile list

* dbus/dbus-shared.h (#define DBUS_NAME_FLAG_ALLOW_REPLACEMENT):
New flag which replaces DBUS_NAME_FLAG_PROHIBIT_REPLACEMENT
(#define DBUS_NAME_FLAG_DO_NOT_QUEUE): New flag for specifying
not to queue an ower if it can't be the primary owner

* bus/bus.h: Add new internal BusOwner struct

* bus/driver.c (bus_driver_handle_hello): Send flags (0 for default)
to bus_registry_ensure and don't set the prohibit_replacement flag
since they are now set per BusOwner and not per name.
(bus_driver_handle_list_queued_owners): bus method (ListQueuedOwners)
that returns the list of connections in a name's connection queue

* bus/services.c (struct BusService): remove prohibit_replacement field
(struct BusOwner): new struct for keeping track of queued connections
and their associated flags for the queue
(struct BusRegistry): add a BusOwner memory pool
(bus_registry_new): initialize the BusOwner memory pool
(bus_registry_unref): free the BusOwner memory pool
(_bus_service_find_owner_link): new internal method for
searching the queue for a specific connection
(bus_owner_set_flags): new method for adding setting the flags on a
bus owner
(bus_owner_new): new method that creates a BusOwner object from the
pool and sets its flags
(bus_owner_ref, bus_owner_unref): ref counting for BusOwner objects
(bus_registry_ensure): Add the flags parameter
(bus_registry_acquire_service): Switch from using raw connections to
using the BusOwner struct
Add new state machine for dealing with the new set of flags
(bus_registry_set_service_context_table, struct OwnershipCancelData,
cancel_ownership, free_ownership_cancel_data,
add_cancel_ownership_to_transaction, struct OwnershipRestoreData,
restore_ownership, free_ownership_restore_data,
add_restore_ownership_to_transaction): Switch to using BusOwner
instead of raw connections
(bus_service_add_owner): Add flags parameter
Switch to using BusOwner instead of raw connections
Add state machine for dealing with the new set of flags
(bus_service_swap_owner): Swaps the first and second owners in the
queue. Used to make sure proper signals are sent when a service looses
or gains primary ownership. We never insert an owner at the top of the
queue. Instead we insert it in the second position and then swap.
(bus_service_remove_owner): Remove the owner from the queue sending
out the NameLost and NameOwnerChanged signals if the we were the
primary owner
(bus_service_get_primary_owners_connection): New method that extracts
the connection from the primary owner
(bus_service_get_primary_owner): Returns the BusOwner instead of the
connection
(bus_service_get_allow_replacement): Changed from the old
bus_service_get_prohibit_replacement method. Checks the flags of the
primary owner and returns if it can be replaced or not
(bus_service_set_prohibit_replacement): removed
(bus_service_has_owner): returns TRUE if and owner with
the specified connection exists in the queue

* dbus/dbus-bus.c (dbus_bus_connection_get_unique_name): New helper
method that only compiles if tests are enabled. Allows us to get the
unique name of a connection so we can check it against the queue when
doing regression tests

* bus/activation.c (bus_activation_send_pending_auto_activate),
bus/dispatch.c (bus_dispatch),
bus/driver.c (bus_driver_handle_get_service_owner,
bus_driver_handle_get_connection_unix_user,
bus_driver_handle_get_connection_unix_process_id,
bus_driver_handle_get_connection_selinux_security_context),
bus/signals.c (connection_is_primary_owner):
use bus_service_get_primary_owners_connection instead of
bus_service_get_primary_owner

* dbus/dbus-sysdeps.c (_dbus_connect_unix_socket,
_dbus_listen_unix_socket): Calculate the length of the socket
path and use that instead of using a fixed length which was
causing socket names to contain many trailing Nul bytes.

* dbus/dbus-glib-lowlevel.h, glib/dbus-gobject.c
(dbus_g_method_get_sender): New method for extracting the sender
from a DBusGMethodInvocation
(dbus_g_method_return_get_reply): changed name to
dbus_g_method_get_reply
(dbus_g_method_return_send_reply): changed name to
dbus_g_method_send reply

* doc/dbus-specification.xml: New docs that describe how the new
queueing system works and talks about the changes to the how
we specify socket names

* glib/examples/example-service.c,
glib/examples/example-signal-emitter.c,
glib/examples/statemachine/statemachine-server.c:
Changed the RequestName flags to the new system

* test/name-test/ (test-names.c, run-test.sh, Makefile.am): New
regression test suite for testing various states of the new
queueing system
/external/dbus/bus/services.h
b5e4d26adec0a9ec37a1bae7aeb5a68344b78ebf 15-Nov-2005 Robert McQueen <robot101@debian.org> 2005-11-15 Robert McQueen <robot101@debian.org>

* bus/driver.c, bus/services.c, bus/services.h: Add a ReleaseName
method to org.freedesktop.DBus to release a bus name or give up
waiting in the queue for it.

* dbus/dbus-bus.c, dbus/dbus-bus.h, dbus/dbus-shared.h: Add a
dbus_bus_release_name method to send the ReleaseName method calls.
Add constants for the return values to dbus/dbus-shared.h.

* doc/dbus-specification.xml: Document the new ReleaseName method
in the specification.

* python/dbus_bindings.pyx: Add a low-level python binding for the
release name method.

* python/exceptions.py, python/service.py: Make freeing BusName
objects release the name. Add a NameExistsException, and fix a
bug with creating UnknownMethodException.

* test/python/test-client.py: Add tests for freeing BusName
objects causing names to be released.
/external/dbus/bus/services.h
cdac3e058b922431f387351fd8ebf60a764485d1 07-Nov-2004 Colin Walters <walters@verbum.org> 2004-11-07 Colin Walters <walters@verbum.org>

* bus/bus.c (load_config): Break into three
separate functions: process_config_first_time_only,
process_config_every_time, and process_config_postinit.
(process_config_every_time): Move call of
bus_registry_set_service_context_table into
process_config_postinit.
(process_config_postinit): New function, does
any processing that needs to happen late
in initialization (and also on reload).
(bus_context_new): Instead of calling load_config,
open config parser here and call process_config_first_time_only
and process_config_every_time directly. Later, after
we have forked but before changing UID,
invoke bus_selinux_full_init, and then call
process_config_postinit.
(bus_context_reload_config): As in bus_context_new,
load parse file inside here, and call process_config_every_time
and process_config_postinit.

* bus/services.h, bus/services.c
(bus_registry_set_service_context_table): Rename
from bus_registry_set_sid_table. Take string hash from config
parser, and convert them here into SIDs.

* bus/config-parser.c (struct BusConfigParser): Have
config parser only store a mapping of service->context
string.
(merge_service_context_hash): New function.
(merge_included): Merge context string hashes instead
of using bus_selinux_id_table_union.
(bus_config_parser_new): Don't use bus_selinux_id_table_new;
simply create a new string hash.
(bus_config_parser_unref): Unref it.
(start_selinux_child): Simply insert strings into hash,
don't call bus_selinux_id_table_copy_over.

* bus/selinux.h, bus/selinux.c (bus_selinux_id_table_union)
(bus_selinux_id_table_copy_over): Delete.
/external/dbus/bus/services.h
43605a6f4e78a8c28afb4b1e924dff0301e0e95c 10-Aug-2004 Havoc Pennington <hp@redhat.com> 2004-08-09 Havoc Pennington <hp@redhat.com>

* COPYING: switch to Academic Free License version 2.1 instead of
2.0, to resolve complaints about patent termination clause.
/external/dbus/bus/services.h
1e9b185b0c274ef0d684b1e43418388225321e72 30-Jul-2004 Havoc Pennington <hp@redhat.com> 2004-07-24 Havoc Pennington <hp@redhat.com>

SELinux support from Matthew Rickard <mjricka@epoch.ncsc.mil>

* bus/selinux.c, bus/selinux.h: new file encapsulating selinux
functionality

* configure.in: add --enable-selinux

* bus/policy.c (bus_policy_merge): add FIXME to a comment

* bus/main.c (main): initialize and shut down selinux

* bus/connection.c: store SELinux ID on each connection, to avoid
repeated getting of the string context and converting it into
an ID

* bus/bus.c (bus_context_get_policy): new accessor, though it
isn't used
(bus_context_check_security_policy): check whether the security
context of sender connection can send to the security context of
recipient connection

* bus/config-parser.c: add parsing for <selinux> and <associate>

* dbus/dbus-transport.c (_dbus_transport_get_unix_fd): to
implement dbus_connection_get_unix_fd()

* dbus/dbus-connection.c (dbus_connection_get_unix_fd): new
function, used by the selinux stuff
/external/dbus/bus/services.h
a1df3040f29223eddaa3ace0fe018fcb28cddcd9 02-Dec-2003 Richard Hult <richard@imendio.com> 2003-12-02 Richard Hult <richard@imendio.com>

* Update AFL version to 2.0 throughout the source files to reflect
the update that was done a while ago.
/external/dbus/bus/services.h
9f1a60dbba69844c0a04b3dd86280352736187ce 27-Nov-2003 Mikael Hallendal <micke@imendio.com> 2003-11-26 Mikael Hallendal <micke@imendio.com>

* bus/*.[ch]:
* dbus/*.[ch]:
* glib/*.[ch]: Made ref functions return the pointer
/external/dbus/bus/services.h
6be547d32f018c23ba56426a0bccd08baa2cf440 11-Apr-2003 Havoc Pennington <hp@redhat.com> 2003-04-10 Havoc Pennington <hp@redhat.com>

* dbus/dbus-connection.c (dbus_connection_flush): don't spin on
the connection if it's disconnected

* bus/activation.c (bus_activation_service_created): use new
transaction features to roll back removal of pending activation if
we don't successfully create the service after all. Don't remove
pending activation if the function fails.

* dbus/dbus-list.c (_dbus_list_insert_before_link)
(_dbus_list_insert_after_link): new code to facilitate
services.c fixes

* dbus/dbus-hash.c (_dbus_hash_table_insert_string_preallocated):
new functionality, so we can preallocate the ability to insert
into a hash table.

* bus/connection.c (bus_transaction_add_cancel_hook): new function
allowing us to put custom hooks in a transaction to be used for
cancelling said transaction

* doc/dbus-specification.sgml: add some discussion of secondary
service owners, and disallow zero-length service names

* bus/services.c (bus_registry_acquire_service): new function,
splits out part of bus_driver_handle_acquire_service() and fixes
a bug where we didn't remove the service doing the acquiring
from the secondary queue if we failed to remove the current owner
from the front of the queue.
/external/dbus/bus/services.h
3f4086f0fdd1cc7fc03585ec9f750897fb3c1d55 16-Mar-2003 Anders Carlsson <andersca@codefactory.se> 2003-03-16 Anders Carlsson <andersca@codefactory.se>

* bus/activation.c: (bus_pending_activation_entry_free),
(bus_pending_activation_free), (bus_activation_new),
(bus_activation_unref), (bus_activation_service_created),
(bus_activation_activate_service):
* bus/activation.h:
* bus/bus.c: (bus_context_new):
* bus/desktop-file.c: (new_section):
* bus/driver.c: (bus_driver_send_service_deleted),
(bus_driver_handle_activate_service):
* bus/services.c: (bus_registry_new), (bus_registry_ensure):
* bus/services.h:
* dbus/dbus-connection.c:
(dbus_connection_send_with_reply_and_block):
* dbus/dbus-message.c: (dbus_message_append_args_valist):
* dbus/dbus-protocol.h:
Make activation work better. Now pending activations will be queued
and the daemon won't try to activate services that are already registered.
/external/dbus/bus/services.h
6ecc14ffabcffb69aa938a67940db48272e05046 13-Mar-2003 Havoc Pennington <hp@redhat.com> 2003-03-12 Havoc Pennington <hp@pobox.com>

Throughout: purge global variables, introduce BusActivation,
BusConnections, BusRegistry, etc. objects instead.

* bus/bus.h, bus/bus.c: introduce BusContext as a global
message bus object

* test/Makefile.am (TEST_BINARIES): disable bus-test for now,
going to redo this a bit differently I think
/external/dbus/bus/services.h
29560adcc79a259a0be3511c056ee7453aa26c04 13-Mar-2003 Havoc Pennington <hp@redhat.com> 2003-03-12 Havoc Pennington <hp@redhat.com>

Mega-patch that gets the message bus daemon initially handling
out-of-memory. Work still needed. Also lots of random
moving stuff to DBusError instead of ResultCode.

* dbus/dbus-list.c (_dbus_list_length_is_one): new function

* dbus/dbus-connection.c
(dbus_connection_send_with_reply_and_block): use DBusError

* dbus/dbus-bus.c: adapt to API changes, make it use DBusError not
DBusResultCode

* dbus/dbus-connection.c (dbus_connection_send): drop the result
code here, as the only failure possible is OOM.

* bus/connection.c (bus_connection_disconnect):
rename bus_connection_disconnected as it's a notification only

* bus/driver.c (bus_driver_handle_acquire_service): don't free
"name" on get_args failure, should be done by get_args;
don't disconnect client for bad args, just return an error.
(bus_driver_handle_service_exists): ditto

* bus/services.c (bus_services_list): NULL-terminate returned array

* bus/driver.c (bus_driver_send_service_lost)
(bus_driver_send_service_acquired): send messages from driver to a
specific client to the client's unique name, not to the broadcast
service.

* dbus/dbus-message.c (decode_header_data): reject messages that
contain no name field
(_dbus_message_get_client_serial): rename to
dbus_message_get_serial and make public
(_dbus_message_set_serial): rename from set_client_serial
(_dbus_message_set_reply_serial): make public
(_dbus_message_get_reply_serial): make public

* bus/connection.c (bus_connection_foreach): allow stopping
iteration by returning FALSE from foreach function.

* dbus/dbus-connection.c (dbus_connection_send_preallocated)
(dbus_connection_free_preallocated_send)
(dbus_connection_preallocate_send): new API for sending a message
without possibility of malloc failure.
(dbus_connection_send_message): rename to just
dbus_connection_send (and same for whole function family)

* dbus/dbus-errors.c (dbus_error_free): make this reinit the error

* dbus/dbus-sysdeps.c (_dbus_exit): new function

* bus/activation.c: handle/return errors

* dbus/dbus-errors.h: add more DBUS_ERROR #define

* dbus/dbus-sysdeps.c (_dbus_directory_open) (_dbus_file_get_contents)
(_dbus_directory_get_next_file): use DBusError instead of DBusResultCode
(_dbus_result_from_errno): move to this file
/external/dbus/bus/services.h
ee1133de4dc5e181be5d09f084d8823388d5f693 27-Jan-2003 Anders Carlsson <andersca@codefactory.se> 2003-01-27 Anders Carlsson <andersca@codefactory.se>

* bus/dispatch.c: (bus_dispatch_message_handler):
Dispatch messages sent to services.

* bus/driver.c: (bus_driver_send_service_deleted),
(bus_driver_send_service_created), (bus_driver_send_service_lost),
(bus_driver_send_service_acquired):
Add helper functions for sending service related messages.

(bus_driver_send_welcome_message):
Send HELLO_REPLY instead of WELCOME.

(bus_driver_handle_list_services):
Send LIST_SERVICES_REPLY instead of SERVICES.

(bus_driver_handle_own_service),
(bus_driver_handle_service_exists):
New message handlers.

(bus_driver_handle_message):
Invoke new message handlers.

(bus_driver_remove_connection):
Don't remove any services here since that's done automatically
by bus_service_remove_owner now.

* bus/driver.h:
New function signatures.

* bus/services.c: (bus_service_add_owner):
Send ServiceAcquired message if we're the only primary owner.

(bus_service_remove_owner):
Send ServiceAcquired/ServiceLost messages.

(bus_service_set_prohibit_replacement),
(bus_service_get_prohibit_replacement):
Functions for setting prohibit replacement.

(bus_service_has_owner):
New function that checks if a connection is in the owner queue of
a certain service.

* bus/services.h:
Add new function signatures.

* dbus/dbus-list.c: (_dbus_list_test):
Add tests for _dbus_list_remove_last and traversing the list backwards.

* dbus/dbus-list.h:
Fix a typo in _dbus_list_get_prev_link, if we're at the first element we can't
go any further, so return NULL then.

* dbus/dbus-protocol.h:
Add new messages, service flags and service replies.
/external/dbus/bus/services.h
a16e83f45d33ae5f3bd5966416c57c8ad4448ae8 25-Jan-2003 Anders Carlsson <andersca@codefactory.se> 2003-01-25 Anders Carlsson <andersca@codefactory.se>

* bus/connection.c: (bus_connection_foreach):
* bus/connection.h:
Add new bus_connection_foreach function.

* bus/driver.c: (send_one_message), (bus_driver_broadcast_message):
Add function that broadcasts a message to all clients.

(bus_driver_send_service_created), (bus_driver_handle_hello),
(bus_driver_send_welcome_message),
(bus_driver_handle_list_services), (bus_driver_message_handler):
Implement functions that take care of listing services, and notifying
clients when new services are created.

* bus/services.c: (bus_services_list):
* bus/services.h:
Add new function that returns an array of strings with the currently
registered services.

* glib/dbus-glib.h:
* glib/dbus-gmain.c:
Update copyright year.
/external/dbus/bus/services.h
aff24a72c18a43dbb6f2d85e6d2226a3c2ea8f10 21-Jan-2003 Anders Carlsson <andersca@codefactory.se> 2003-01-21 Anders Carlsson <andersca@codefactory.se>

* bus/Makefile.am:
Add driver.[ch]

* bus/connection.c: (connection_disconnect_handler):
Remove the connection from the bus driver's list.

(connection_watch_callback): Dispatch messages.

(free_connection_data): Free connection name.

(bus_connection_setup): Add connection to the bus driver's list.
(bus_connection_remove_owned_service):
(bus_connection_set_name), (bus_connection_get_name):
Add functions for setting and getting the connection's name.

* bus/connection.h:
Add function headers.

* bus/driver.c: (create_unique_client_name),
(bus_driver_handle_hello_message),
(bus_driver_send_welcome_message), (bus_driver_message_handler),
(bus_driver_add_connection), (bus_driver_remove_connection):
* bus/driver.h:
* bus/main.c:
* bus/services.c: (bus_service_free):
* bus/services.h:
New file that handles communication and registreation with the bus
itself.
/external/dbus/bus/services.h
96a9f80300b7794475a5451a60a07555ea3526be 06-Jan-2003 Havoc Pennington <hp@redhat.com> 2003-01-05 Havoc Pennington <hp@pobox.com>

* bus/connection.c: implement routines for handling connections,
first thing is keeping a list of owned services on each connection
and setting up watches etc.

* bus/services.c: implement a mapping from service names to lists
of connections

* dbus/dbus-hash.c: add DBUS_HASH_POINTER

* dbus/dbus-threads.c (dbus_static_mutex_lock): add functions
to use static mutexes for global data

* dbus/dbus-connection.c (dbus_connection_set_data): add new
collection of functions to set/get application-specific data
on the DBusConnection.
/external/dbus/bus/services.h