History log of /external/dbus/dbus/dbus-test.c
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
a44d08711c64e7ae807d2b4f181cefa848e2aa32 17-Jun-2010 Will Thompson <will.thompson@collabora.co.uk> Revert "Bug 28460 - Refactored dbus configuration access."

This reverts commit 6f9077ee870ad02119facf83d1293301b4535c3b, which
broke the build on Unix (see previous patch) and introduced a bunch of
warnings.
/external/dbus/dbus/dbus-test.c
6f9077ee870ad02119facf83d1293301b4535c3b 14-Jun-2010 Ralf Habacker <ralf.habacker@freenet.de> Bug 28460 - Refactored dbus configuration access.

Libdbus uses several config variables. On unix these settings are read from
environment variables by using _dbus_getenv.

On other platforms like wince there are no environment variables available and
_dbus_getenv needs an emulation for those plattforms (see
dbus/dbus-sysdeps-wince-glue.c)

To cleanup this emulation the appended patch adds a config api by adding
_dbus_config_... functions.

Also having all client config related functions listed in one header file
provides a good overview about which config attributes are available.

The default implementation retrieves the config values from environment
variables. For other os this could be easily extended or replaced by.
/external/dbus/dbus/dbus-test.c
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/dbus/dbus-test.c
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/dbus/dbus-test.c
7be5fd95cdccdca28937804f32ca8b1308887d09 10-Jun-2007 Havoc Pennington <hp@redhat.com> 2007-06-09 Havoc Pennington <hp@redhat.com>

* bus/policy.c (bus_policy_create_client_policy): gracefully
continue if the connection has no unix user - just don't apply
any unix user dependent rules.

* bus/config-parser.c: remove dbus-userdb.h usage

* bus/bus.c: remove dbus-userdb.h usage

* dbus/dbus-transport.c (_dbus_transport_get_is_authenticated):
support Windows user function; also, fix the logic for checking
auth as root in the default auth code (broken in the previous
commit)

* dbus/dbus-connection.c
(dbus_connection_set_windows_user_function): new function
(dbus_connection_get_windows_user): new function
/external/dbus/dbus/dbus-test.c
23832672266bb4ff23b66247c0cfa1a2ed0cc97b 09-Jun-2007 Havoc Pennington <hp@redhat.com> 2007-06-09 Havoc Pennington <hp@redhat.com>

* bus/dispatch.c (check_get_connection_unix_process_id): adapt
since sysdeps-unix.h stuff isn't included anymore

* bus/bus.c (bus_context_new): use more abstract functions to
change user, so they can be no-ops on Windows

* dbus/dbus-credentials.c, dbus/dbus-credentials.h,
dbus/dbus-credentials-util.c: new files containing a fully opaque
DBusCredentials data type to replace the old not opaque one.

* configure.in (DBUS_UNIX): define DBUS_UNIX to match DBUS_WIN on
windows

* dbus/dbus-userdb.h: prohibit on Windows, next step is to clean
up the uses of it in bus/*.c and factor out the parts of
cookie auth that depend on it
/external/dbus/dbus/dbus-test.c
5c593d75fff379b06cb690ae755a661da47d49ee 19-May-2007 Ralf Habacker <ralf.habacker@freenet.de> * dbus/dbus-test.c (dbus_internal_do_not_use_run_tests): disabled tests not running on wince.
/external/dbus/dbus/dbus-test.c
d3204dc446d96876baab9859de132a5a4da675d4 15-Nov-2006 Havoc Pennington <hp@redhat.com> 2006-11-14 Havoc Pennington <hp@redhat.com>

* dbus/dbus-misc.c, dbus/dbus-misc.h: Move
dbus_get_local_machine_id() to its own file, no substantive
changes. There are a couple other things we might want to add that
are "misc" so moving out of dbus-connection.[hc] which is big
enough already.
/external/dbus/dbus/dbus-test.c
eaefe03a8891b84e3f9e1f99f9098d65567e3092 28-Oct-2006 Havoc Pennington <hp@redhat.com> 2006-10-27 Havoc Pennington <hp@redhat.com>

* dbus/dbus-test.c: enclose more of the file in the
DBUS_BUILD_TESTS check.

* dbus/dbus-sysdeps-pthread.c (PTHREAD_CHECK): fix for
DBUS_DISABLE_ASSERT case.

* dbus/dbus-connection.c (dbus_connection_get_unix_user): document
that it only works on the server side

* dbus/dbus-bus.c: add a global lock covering the BusData we
attach to each connection
(internal_bus_get): lock our access to the BusData
(dbus_bus_register): lock the entire registration process
with _DBUS_LOCK(bus_datas). If we get the lock and
registration is already complete, silently return (vs. previous
behavior of aborting).
(dbus_bus_set_unique_name): lock the BusData
(dbus_bus_get_unique_name): lock the BusData
/external/dbus/dbus/dbus-test.c
54a2e9f7961b4b8afff94bb0c5b756f986965be6 24-Feb-2005 Colin Walters <walters@verbum.org> 2005-02-24 Colin Walters <walters@verbum.org>

* dbus/dbus-signature.c: New file; implements various functions
related to type signatures. Includes an interator for parsing,
validation functions.
(dbus_type_is_basic): Moved here from
dbus-marshal-basic.c:_dbus_type_is_basic.
(dbus_type_is_container): Moved here from
dbus-marshal-basic.c:_dbus_type_is_container.

All callers of _dbus_type_is_container and _dbus_type_is_basic
updated, and include dbus-signature.h.

* dbus/dbus-signature.h: New file; prototypes for the above.

* dbus/Makefile.am (DBUS_LIB_SOURCES): Add dbus-signature.c,
dbus-signature.h.

* dbus/dbus-marshal-basic.c (map_type_char_to_type): New utility
function factored out of _dbus_first_type_in_signature.
(_dbus_first_type_in_signature_c_str): New function; returns first
type code for a type signature character.

* dbus/dbus-marshal-basic.h: Prototype _dbus_first_type_in_signature_c_str,
handle function moves.

* dbus/dbus-marshal-recursive.h: Export _dbus_type_signature_next.

* dbus/dbus-marshal-recursive.c (_dbus_type_signature_next): New
function; skips to next complete type in type signature.
Implemented using previous skip_one_complete_type. Now
skip_one_complete_type just delegates to
_dbus_type_signature_next.

* dbus/dbus-marshal-basic.c (_dbus_type_is_basic): Moved
to dbus-signature.c
(_dbus_type_is_container): Ditto.

* doc/dbus-specification.xml: Update introspection sample to
use real type signatures.

* dbus/dbus-test.h: Prototype signature test.

* dbus/dbus-test.c (dbus_internal_do_not_use_run_tests): Run
signature tests.

* dbus/dbus-protocol.h (DBUS_ERROR_INVALID_SIGNATURE): New error.
/external/dbus/dbus/dbus-test.c
f9a7bcc2fcef2b43d4dc5d560ac138da1e9719c9 21-Feb-2005 Colin Walters <walters@verbum.org> 2005-02-21 Colin Walters <walters@verbum.org>

* dbus/dbus-test-main.c (main): Take optional specific test
argument.

* dbus/dbus-test.c (run_test): New function, runs a test function
with no data directory.
(run_data_test): Like above, but takes data directory.
(dbus_internal_do_not_use_run_tests): Take
specific test argument. Replace lots of cut n' paste code
with run_test and run_data_test.

* dbus/dbus-test.h: Update prototype for
dbus_internal_do_not_use_run_tests.
/external/dbus/dbus/dbus-test.c
71f3b461b371d6bf7c7bc4e92578420b78d5c0d8 11-Feb-2005 Havoc Pennington <hp@redhat.com> 2005-02-10 Havoc Pennington <hp@redhat.com>

* dbus/dbus-message-factory.c (generate_special): modify test to
avoid using a non-basic dict key

* dbus/dbus-marshal-validate-util.c: add test for the below

* doc/dbus-specification.xml: require that dict keys are a basic
type

* dbus/dbus-marshal-validate.c
(_dbus_validate_signature_with_reason): require that dict key is a
basic type
/external/dbus/dbus/dbus-test.c
3ed9db546e1143bc9aa2d83a6f423fdd81227352 28-Jan-2005 Havoc Pennington <hp@redhat.com> 2005-01-27 Havoc Pennington <hp@redhat.com>

* dbus/dbus-arch-deps.h.in: add 16/32-bit types

* configure.in: find the right type for 16 and 32 bit ints as well
as 64

* dbus/dbus-protocol.h (DBUS_TYPE_INT16, DBUS_TYPE_UINT16): add
the 16-bit types so people don't have to stuff them in 32-bit or
byte arrays.
/external/dbus/dbus/dbus-test.c
fddbc09c4a9125fcb168fb31ff300d4132919ea6 28-Jan-2005 Havoc Pennington <hp@redhat.com> 2005-01-27 Havoc Pennington <hp@redhat.com>

* dbus/dbus-message.c: byteswap the message if you init an
iterator to read/write from it

* dbus/dbus-marshal-byteswap.c: new file implementing
_dbus_marshal_byteswap()

* dbus/dbus-marshal-basic.c: add _dbus_swap_array()
/external/dbus/dbus/dbus-test.c
9d21554dd3b560952cd5aa607c4ec07898c0b260 23-Jan-2005 Havoc Pennington <hp@redhat.com> 2005-01-23 Havoc Pennington <hp@redhat.com>

* dbus/dbus-message-factory.c, dbus/dbus-message-util.c:
get this all working, not many tests in the framework yet though
/external/dbus/dbus/dbus-test.c
aad6fa897f85486386b030847151cb09943c97c0 17-Jan-2005 Havoc Pennington <hp@redhat.com> 2005-01-16 Havoc Pennington <hp@redhat.com>

* dbus/dbus-internals.c (_dbus_real_assert): print the function
name the assertion failed in

* dbus/dbus-internals.h (_dbus_return_if_fail)
(_dbus_return_val_if_fail): assert that the name of the function
containing the check doesn't start with '_', since we only want to
use checks on public functions

* dbus/dbus-connection.c (_dbus_connection_ref_unlocked): change
checks to assertions

* dbus/dbus-marshal-header.c (_dbus_header_set_field_basic):
change checks to asserts for private function

* dbus/dbus-message.c (_dbus_message_set_serial): checks
to asserts for private function

* dbus/dbus-marshal-recursive.c (skip_one_complete_type): remove
broken assertion that was breaking make check
(_dbus_type_reader_array_is_empty): remove this rather than fix
it, was only used in assertions
/external/dbus/dbus/dbus-test.c
9c3d566e95c9080f6040c64531b0ccae22bd5d74 15-Jan-2005 Havoc Pennington <hp@redhat.com> 2005-01-15 Havoc Pennington <hp@redhat.com>

* Land the new message args API and type system.

This patch is huge, but the public API change is not
really large. The set of D-BUS types has changed somewhat,
and the arg "getters" are more geared toward language bindings;
they don't make a copy, etc.

There are also some known issues. See these emails for details
on this huge patch:
http://lists.freedesktop.org/archives/dbus/2004-December/001836.html
http://lists.freedesktop.org/archives/dbus/2005-January/001922.html

* dbus/dbus-marshal-*: all the new stuff

* dbus/dbus-message.c: basically rewritten

* dbus/dbus-memory.c (check_guards): with "guards" enabled, init
freed blocks to be all non-nul bytes so using freed memory is less
likely to work right

* dbus/dbus-internals.c (_dbus_test_oom_handling): add
DBUS_FAIL_MALLOC=N environment variable, so you can do
DBUS_FAIL_MALLOC=0 to skip the out-of-memory checking, or
DBUS_FAIL_MALLOC=10 to make it really, really, really slow and
thorough.

* qt/message.cpp: port to the new message args API
(operator<<): use str.utf8() rather than str.unicode()
(pretty sure this is right from the Qt docs?)

* glib/dbus-gvalue.c: port to the new message args API

* bus/dispatch.c, bus/driver.c: port to the new message args API

* dbus/dbus-string.c (_dbus_string_init_const_len): initialize the
"locked" flag to TRUE and align_offset to 0; I guess we never
looked at these anyhow, but seems cleaner.

* dbus/dbus-string.h (_DBUS_STRING_ALLOCATION_PADDING):
move allocation padding macro to this header; use it to implement
(_DBUS_STRING_STATIC): ability to declare a static string.

* dbus/dbus-message.c (_dbus_message_has_type_interface_member):
change to return TRUE if the interface is not set.

* dbus/dbus-string.[hc]: move the D-BUS specific validation stuff
to dbus-marshal-validate.[hc]

* dbus/dbus-marshal-basic.c (_dbus_type_to_string): move here from
dbus-internals.c

* dbus/Makefile.am: cut over from dbus-marshal.[hc]
to dbus-marshal-*.[hc]

* dbus/dbus-object-tree.c (_dbus_decompose_path): move this
function here from dbus-marshal.c
/external/dbus/dbus/dbus-test.c
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/dbus/dbus-test.c
6971a06b04b3fdd48b61202b2276e8140f4b7be0 22-Apr-2004 Kristian Høgsberg <krh@redhat.com> 2004-04-21 Kristian Høgsberg <krh@redhat.com>

* dbus/dbus-server-unix.c (unix_finalize): Don't unref
unix_server->watch here, it is unreffed in disconnect.
(_dbus_server_new_for_tcp_socket): convert NULL host to
"localhost" here so we don't append NULL to address.

* dbus/dbus-server.c (_dbus_server_test): Add test case for
various addresses, including tcp with no explicit host.
/external/dbus/dbus/dbus-test.c
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/dbus/dbus-test.c
1dd3f1788f1b4c9af2f4fa744abdb7892d0a14b9 31-Aug-2003 Havoc Pennington <hp@redhat.com> 2003-08-30 Havoc Pennington <hp@pobox.com>

* dbus/dbus-connection.c: purge DBusMessageHandler

* dbus/dbus-message-handler.c: remove DBusMessageHandler, just
use callbacks everywhere
/external/dbus/dbus/dbus-test.c
5fd1e389e1c1c12ad4a55c2af6abdc8e7a2f6d41 31-Aug-2003 Havoc Pennington <hp@redhat.com> 2003-08-30 Havoc Pennington <hp@pobox.com>

* test/data/valid-config-files/system.d/test.conf: change to
root for the user so warnings don't get printed

* dbus/dbus-message.c: add dbus_message_get_path,
dbus_message_set_path

* dbus/dbus-object-tree.c (do_test_dispatch): add test of
dispatching to a path

* dbus/dbus-string.c (_dbus_string_validate_path): add

* dbus/dbus-marshal.c (_dbus_demarshal_object_path): implement
(_dbus_marshal_object_path): implement

* dbus/dbus-protocol.h (DBUS_HEADER_FIELD_PATH): new header field
to contain the path to the target object
(DBUS_HEADER_FIELD_SENDER_SERVICE): rename
DBUS_HEADER_FIELD_SENDER to explicitly say it's the sender service
/external/dbus/dbus/dbus-test.c
8d38a2e2c5dc95de992c4d856ec1b0c0948bca3e 29-Aug-2003 Havoc Pennington <hp@redhat.com> 2003-08-28 Havoc Pennington <hp@pobox.com>

purge DBusObjectID

* dbus/dbus-connection.c: port to no ObjectID, create a
DBusObjectTree, rename ObjectTree to ObjectPath in public API

* dbus/dbus-connection.h (struct DBusObjectTreeVTable): delete
everything except UnregisterFunction and MessageFunction

* dbus/dbus-marshal.c: port away from DBusObjectID,
add DBUS_TYPE_OBJECT_PATH

* dbus/dbus-object-registry.[hc], dbus/dbus-object.[hc],
dbus/dbus-objectid.[hc]: remove these, we are moving to
path-based object IDs
/external/dbus/dbus/dbus-test.c
24f411a6a10e4838f57595720642ce83ceae814c 25-Aug-2003 Havoc Pennington <hp@redhat.com> 2003-08-25 Havoc Pennington <hp@pobox.com>

Just noticed that dbus_message_test is hosed, I wonder when I
broke that. I thought make check was passing earlier...

* dbus/dbus-object-tree.c: add new "object tree" to match DCOP
container tree, will replace most of dbus-object-registry

* dbus/dbus-string.c (_dbus_string_append_printf_valist): fix C99
screwup
/external/dbus/dbus/dbus-test.c
ef614207fc4f03e5cc02faeb109f739eb1ccdf31 15-Aug-2003 Havoc Pennington <hp@redhat.com> 2003-08-15 Havoc Pennington <hp@pobox.com>

* dbus/dbus-connection.c,
dbus/dbus-pending-call.c: Finish the pending call stuff
/external/dbus/dbus/dbus-test.c
824d4a5edfe1fa7222ab5cb49928bf78a675b563 09-Jul-2003 Havoc Pennington <hp@redhat.com> 2003-07-08 Havoc Pennington <hp@pobox.com>

* dbus/dbus-object.c: implement some of this

* dbus/dbus-object-registry.c
(_dbus_object_registry_add_and_unlock): fill in the object_id out
param
(_dbus_object_registry_new): handle OOM
/external/dbus/dbus/dbus-test.c
d8abf955f5bff3e83cabd267883039f7a42c98c3 08-Jul-2003 Havoc Pennington <hp@redhat.com> 2003-07-08 Havoc Pennington <hp@pobox.com>

* dbus/dbus-object.h: sketch out an API for registering objects
with a connection, that allows us to use as little as 24 bytes
per object and lets application code represent an object in
any conceivable way.

* dbus/dbus-object-registry.c: implement the hard bits of the
DBusConnection aspect of object API. Not yet wired up.
/external/dbus/dbus/dbus-test.c
3f1ad214b5e5c63697ee208d459b304a4ef6e79b 07-Jul-2003 Havoc Pennington <hp@redhat.com> 2003-07-06 Havoc Pennington <hp@pobox.com>

* dbus/dbus-marshal.c (_dbus_marshal_set_object_id): new function
(_dbus_marshal_object_id): new
(_dbus_demarshal_object_id): new
(_dbus_marshal_get_arg_end_pos): support object ID type, and
consolidate identical switch cases. Don't conditionalize handling
of DBUS_TYPE_UINT64, need to handle the type always.
(_dbus_marshal_validate_arg): consolidate identical cases, and
handle DBUS_TYPE_OBJECT_ID

* dbus/dbus-objectid.c: new file with DBusObjectID data type.

* dbus/dbus-protocol.h: add DBUS_TYPE_OBJECT_ID
/external/dbus/dbus/dbus-test.c
928d7f3cadc94c59a207f6f656652d858f4a85e7 29-Jun-2003 Miloslav Trmac <mitr@volny.cz> 2003-06-29 Miloslav Trmac <mitr@volny.cz>

* dbus/dbus-memory.c (dbus_realloc): Don't check guards after shrinking
the allocated block.
(_dbus_memory_test): New function.
* dbus/dbus-test.h: Add _dbus_memory_test ().
* dbus/dbus-test.c (dbus_internal_do_not_use_run_tests): Call it.
/external/dbus/dbus/dbus-test.c
d1c7eefb66483c3ea4d9e7fb6dca23dcfac8cad5 05-May-2003 Havoc Pennington <hp@redhat.com> 2003-05-04 Havoc Pennington <hp@pobox.com>

* dbus/dbus-message-handler.c (_dbus_message_handler_test): add
unit test

* dbus/dbus-marshal.c (_dbus_demarshal_string_array): fix this
function, which assumed length was in # of strings, not bytes

* dbus/dbus-message.c (_dbus_message_test): add tests for some
missing coverage

* dbus/dbus-connection.c
(_dbus_connection_queue_received_message): disable function for
now, we are only using it in test mode

* dbus/dbus-message.c (_dbus_message_loader_queue_messages):
remove a mistaken FIXME
/external/dbus/dbus/dbus-test.c
fe1cb3a9a1fc6bcbfa1b3be74ac9d5867005210f 15-Apr-2003 Havoc Pennington <hp@redhat.com> 2003-04-14 Havoc Pennington <hp@redhat.com>

* dbus/dbus-userdb.c: user database abstraction, mostly to get
caching, but at some point we might want to be able to use a
different database.

* bus/dispatch.c (bus_dispatch_sha1_test): add a test that uses
SHA1 conf file to test the sha1 auth mechanism, since the regular
test always uses EXTERNAL when available.

* configure.in,
test/data/valid-config-files/debug-allow-all-sha1.conf.in:
add conf file that requires use of sha1 auth
/external/dbus/dbus/dbus-test.c
0366385618ccc26789fdf3a9cc35ee038de071f6 09-Apr-2003 Havoc Pennington <hp@redhat.com> 2003-04-08 Havoc Pennington <hp@redhat.com>

* test/data/invalid-messages/array-with-mixed-types.message:
regression test that fails for the moment

* dbus/dbus-test.c (dbus_internal_do_not_use_run_tests): reorder
tests for convenience

* dbus/dbus-marshal.c (_dbus_marshal_validate_arg): don't allow
array of nil, it broke things.

* test/data/invalid-messages/array-of-nil.message: regression test

* test/data/valid-messages/array-of-array-of-uint32.message:
happened to write this so added it to suite
/external/dbus/dbus/dbus-test.c
c5020ac870c5990a36c3576453cc23431213e8bf 08-Apr-2003 Alexander Larsson <alexl@redhat.com> 2003-04-08 Alexander Larsson <alexl@redhat.com>

Implemented recursive types, named types and new-style iters

* bus/driver.c:
* glib/test-thread-client.c: (thread_func):
* glib/test-thread-server.c: (handle_test_message):
* test/test-service.c: (handle_echo):
Update to new api

* dbus/Makefile.am:
* dbus/dbus-dict.c:
* dbus/dbus-dict.h:
* dbus/dbus.h
Remove DBusDict

* dbus/dbus-internals.c: (_dbus_type_to_string):
Update for new types.

* dbus/dbus-marshal.[ch]:
Implement recursive types and the new marshalling format.
Remove hardcoded dict marshalling.
Marshal named types.

* dbus/dbus-message-builder.c:
Add BYTE_ARRAY.
Remove references to old types

* dbus/dbus-message.[ch]:
New non-refcounted iter API that supports recursive iters.
Use iters for appending, including support for recursive
iters.
Add byte and named type support.
Update everything to new marshalling formats.
Add tests for new API.

* dbus/dbus-protocol.h:
Remove old array types.
Add types: BYTE, ARRAY, DICT, NAMED

* dbus/dbus-string.c:
* dbus/dbus-sysdeps.c:
Make parse_double locale safe.

* dbus/dbus-test-main.c:
Call setlocale.

* dbus/dbus-test.c:
Kill dict test

* doc/dbus-specification.sgml:
Update spec

* test/data/incomplete-messages/missing-body.message:
* test/data/invalid-messages/bad-boolean.message:
* test/data/invalid-messages/bad-boolean-array.message:
* test/data/invalid-messages/boolean-array-length-too-long.message-raw:
* test/data/invalid-messages/boolean-has-no-value.message-raw:
* test/data/invalid-messages/too-short-dict.message:
* test/data/valid-messages/dict-simple.message:
* test/data/valid-messages/dict.message:
* test/data/valid-messages/emptiness.message:
* test/data/valid-messages/lots-of-arguments.message:
* test/data/valid-messages/no-padding.message:
* test/data/valid-messages/recursive-types.message:
Add missing NAME fields
Fix up dicts & arrays

* test/data/invalid-messages/dict-with-nil-value.message:
Removed, this is not invalid anymore.

* test/data/valid-messages/recursive-types.message:
Add new test for deeply recursive types.
/external/dbus/dbus/dbus-test.c
bc8b061eec0fd9de6552a9e6118c40283863b6dc 06-Apr-2003 Havoc Pennington <hp@redhat.com> 2003-04-06 Havoc Pennington <hp@pobox.com>

* dbus/dbus-threads.c: Redo how the fake debug mutexes are done
so it detects deadlocks and also we actually init threads when
debugging.
/external/dbus/dbus/dbus-test.c
03b9ca6d4ecf2577958530b8390d675c73a58825 05-Apr-2003 Havoc Pennington <hp@redhat.com> 2003-04-04 Havoc Pennington <hp@redhat.com>

* dbus/dbus-spawn.c, dbus/dbus-spawn.h: Change dbus_spawn to
return a "babysitter" object that is used to monitor the status of
the spawned process and reap it when required.

* test/test-segfault.c, test/test-exit.c,
test/test-sleep-forever.c: binaries that do various lame things,
used in the test suite.

* dbus/dbus-sysdeps.c: kill _dbus_errno_to_string()
/external/dbus/dbus/dbus-test.c
94790fef4a846ef2bed9bf1825c4c2b0ca7b8566 02-Apr-2003 Havoc Pennington <hp@redhat.com> 2003-04-02 Havoc Pennington <hp@redhat.com>

* dbus/dbus-sysdeps.c (_dbus_file_get_contents): include filenames
in error messages
(_dbus_string_get_dirname): new
(_dbus_sysdeps_test): new
(_dbus_directory_open): include dirnames in error messages

* bus/config-parser.c: interpret <include> and <includedir> and
<servicedir> relative to config file location if the given
filename is not absolute.

* dbus/dbus-string.c (_dbus_string_find_byte_backward): new
/external/dbus/dbus/dbus-test.c
269d74f214f87bed0f6fd58f1c848240d31e0b9f 26-Mar-2003 Havoc Pennington <hp@redhat.com> 2003-03-26 Havoc Pennington <hp@pobox.com>

* bus/test-main.c, dbus/dbus-test.c (main): check memleaks
after every test so it's quick and easy to see which leaked, and
so we test multiple dbus_shutdown() calls

* configure.in: change configure.in XML stuff to also support
expat

* config-loader-libxml.c: some hacking

* config-loader-expat.c: some hacking

* config-parser.c: some hacking, plus tests
/external/dbus/dbus/dbus-test.c
c3af5ccdbc22e8990d04ec2f89ad1f2e053655e9 24-Mar-2003 Havoc Pennington <hp@redhat.com> 2003-03-23 Havoc Pennington <hp@pobox.com>

* dbus/dbus-threads.c (dbus_mutex_new, dbus_condvar_new): with
DBUS_BUILD_TESTS, actually alloc/free a block of memory for
the mutex, so we can check for proper memory management
and OOM handling.

* dbus/dbus-dataslot.c: remove the mutex from
DBusDataSlotAllocator and lock it manually when using it,
to simplify fitting it into the global slots framework.

* dbus/dbus-threads.c (init_static_locks): rework how we're
handling global locks so they are easily shut down.

* bus/policy.c (bus_policy_append_rule): fix

* bus/test-main.c (main): check for memleaks

* dbus/dbus-test.c (dbus_internal_do_not_use_run_tests): make
test suite check for memleaks

* dbus/dbus-memory.c: add support in test mode for tracking
number of outstanding blocks
/external/dbus/dbus/dbus-test.c
ee09dbf058bec7edd55deb2dbca67e7f0885b160 07-Mar-2003 Anders Carlsson <andersca@codefactory.se> 2003-03-07 Anders Carlsson <andersca@codefactory.se>

* dbus/Makefile.am:
Add dbus-dict.[ch]

* dbus/dbus-dict.c: (dbus_dict_entry_free), (dbus_dict_new),
(dbus_dict_ref), (dbus_dict_unref), (dbus_dict_contains),
(dbus_dict_remove), (dbus_dict_get_value_type),
(dbus_dict_get_keys), (dbus_dict_put_boolean),
(dbus_dict_put_int32), (dbus_dict_put_uint32),
(dbus_dict_put_double), (dbus_dict_put_string),
(dbus_dict_put_boolean_array), (dbus_dict_put_int32_array),
(dbus_dict_put_uint32_array), (dbus_dict_put_double_array),
(dbus_dict_put_string_array), (dbus_dict_get_boolean),
(dbus_dict_get_int32), (dbus_dict_get_uint32),
(dbus_dict_get_double), (dbus_dict_get_string),
(dbus_dict_get_boolean_array), (dbus_dict_get_int32_array),
(dbus_dict_get_uint32_array), (dbus_dict_get_double_array),
(dbus_dict_get_string_array), (_dbus_dict_test):
* dbus/dbus-dict.h:
Add DBusDict implementation

* dbus/dbus-test.c: (dbus_internal_do_not_use_run_tests):
* dbus/dbus-test.h:
Add _dbus_dict_test.
/external/dbus/dbus/dbus-test.c
7e050c88719553d0c74e3dc68caf7bc50ae99590 05-Mar-2003 Havoc Pennington <hp@redhat.com> 2003-03-04 Havoc Pennington <hp@pobox.com>

* test/data/auth/*: adapt to changes

* dbus/dbus-auth-script.c (_dbus_auth_script_run): add
USERID_BASE64 and change USERNAME_BASE64 to put in username not
userid

* dbus/dbus-keyring.c (_dbus_keyring_validate_context): prevent
more stuff from being in a context name, to make the protocol
simpler to deal with

* dbus/dbus-errors.c (dbus_error_has_name): new function
(dbus_error_is_set): new function

* dbus/dbus-auth.c: replace DBUS_STUPID_TEST_MECH auth
with DBUS_COOKIE_SHA1, implement DBUS_COOKIE_SHA1

* dbus/dbus-connection.c (dbus_connection_flush): also read
messages during a flush operation

* dbus/Makefile.am: remove dbus-md5 since it isn't currently used.
/external/dbus/dbus/dbus-test.c
7265423411609c14ddb9e6643463b840afcaa09b 26-Feb-2003 Havoc Pennington <hp@redhat.com> 2003-02-26 Havoc Pennington <hp@pobox.com>

* dbus/dbus-connection.c
(dbus_connection_send_message_with_reply_and_block): fix crash
where we ref'd the outgoing message instead of the returned reply

* dbus/dbus-transport-unix.c (do_authentication): check read watch
at the end of this function, so if we didn't need to read for
authentication, we reinstall it for receiving messages

* dbus/dbus-message.c (dbus_message_new_reply): allow replies to
a NULL sender for peer-to-peer case

* dbus/dbus-transport-unix.c (check_read_watch): handle
!authenticated case correctly

* glib/dbus-gmain.c: add support for DBusServer

* dbus/dbus-server.c: add data slot support

* glib/dbus-gmain.c (dbus_connection_setup_with_g_main): check
return values and handle errors

* dbus/dbus-dataslot.c: factor out the data slot stuff from
DBusConnection

* Doxyfile.in (INPUT): add glib subdir

* glib/dbus-gmain.c (dbus_connection_setup_with_g_main): rename
setup_with_g_main instead of hookup_with_g_main; write docs
/external/dbus/dbus/dbus-test.c
2f38c959212d98e2194139daa9120fda37415b4f 24-Feb-2003 Havoc Pennington <hp@redhat.com> 2003-02-23 Havoc Pennington <hp@pobox.com>

* dbus/dbus-keyring.c: finish most of this implementation and
simple unit test

* dbus/dbus-errors.c (dbus_set_error_const, dbus_set_error): make
these barf if the error isn't cleared to NULL

* dbus/dbus-sysdeps.c (_dbus_delete_file): set error on failure
(_dbus_create_directory): new function

* dbus/dbus-errors.c (dbus_set_error): fix warning

* dbus/dbus-string.c (_dbus_string_hex_encode): new function
(_dbus_string_hex_decode): new function
(test_hex_roundtrip): test code

* dbus/dbus-sha.c (_dbus_sha_compute): use dbus_string_hex_encode

* dbus/dbus-md5.c (_dbus_md5_compute): use dbus_string_hex_encode

* dbus/dbus-sysdeps.c (_dbus_string_save_to_file): make this use
the save-to-temp/rename trick to atomically write the new file
(_dbus_string_parse_uint): new function
/external/dbus/dbus/dbus-test.c
6c07098c5ec68e78320a6f07e4c9e141a95729ed 22-Feb-2003 Havoc Pennington <hp@redhat.com> 2003-02-22 Havoc Pennington <hp@pobox.com>

* dbus/dbus-message.c (dbus_message_iter_get_string_array):
(dbus_message_iter_get_byte_array): Fix up doxygen warnings

* dbus/dbus-sha.c: add implementation of SHA-1 algorithm

* dbus/test/data/sha-1: add US government test suite for SHA-1
/external/dbus/dbus/dbus-test.c
78e16e99e753175fa49e787eab256932eefaa03f 19-Feb-2003 Havoc Pennington <hp@redhat.com> 2003-02-18 Havoc Pennington <hp@pobox.com>

* dbus/dbus-string.c (_dbus_string_zero): new function

* dbus/dbus-md5.c: include MD5 implementation by L. Peter Deutsch,
wrap it in some dbus-friendly API

* dbus/dbus-types.h: add 16-bit types
/external/dbus/dbus/dbus-test.c
3791dcca16cb46b0ff7305beff75d1aa2645940c 13-Feb-2003 Havoc Pennington <hp@redhat.com> 2003-02-10 Havoc Pennington <hp@pobox.com>

* dbus/dbus-auth-script.c, dbus/dbus-auth-script.h: sync
initial cut at test framework for DBusAuth from laptop.
Doesn't quite work yet but it compiles and I need to get
it off the 266mhz laptop. ;-)

* dbus/dbus-server-debug.c (_dbus_server_debug_accept_transport):
fix a memleak in error case
/external/dbus/dbus/dbus-test.c
d8f9c46bf873fe03dbb1db100f3c6d02b2d6c847 01-Feb-2003 Havoc Pennington <hp@redhat.com> 2003-01-31 Havoc Pennington <hp@pobox.com>

* dbus/dbus-message.c: refactor the test code to be more general,
in preparation for writing a "randomly permute test cases to
try to break the loader" program.
/external/dbus/dbus/dbus-test.c
5ebb5748c2a7587c734eeed9c66f2a1fc0635d09 30-Jan-2003 Anders Carlsson <andersca@codefactory.se> 2003-01-30 Anders Carlsson <andersca@codefactory.se>

* dbus/Makefile.am:
Add dbus-address.[ch]

* dbus/dbus-address.c: (dbus_address_entry_free),
(dbus_address_entries_free), (create_entry),
(dbus_address_entry_get_method), (dbus_address_entry_get_value),
(dbus_parse_address), (_dbus_address_test):
* dbus/dbus-address.h:
New files for dealing with address parsing.

* dbus/dbus-connection.c:
Document timeout functions.

* dbus/dbus-message.c:
Document dbus_message_new_from_message.

* dbus/dbus-server-debug.c:
Document.

* dbus/dbus-server.c: (dbus_server_listen):
Parse address and use correct server implementation.

* dbus/dbus-string.c: (_dbus_string_find_to), (_dbus_string_test):
* dbus/dbus-string.h:
New function with test.

* dbus/dbus-test.c: (dbus_internal_symbol_do_not_use_run_tests):
* dbus/dbus-test.h:
Add address tests.

* dbus/dbus-transport-debug.c:
Document.

* dbus/dbus-transport.c: (_dbus_transport_open):
Parse address and use correct transport implementation.
/external/dbus/dbus/dbus-test.c
05a4ad6994919b352b5229d0b1b0a8ebebe2a42f 28-Jan-2003 Havoc Pennington <hp@redhat.com> 2003-01-27 Havoc Pennington <hp@pobox.com>

* dbus/dbus-mempool.c (time_for_size): replace printf with
_dbus_verbose

* dbus/dbus-message-builder.c (_dbus_message_data_load): allow
empty lines; fix the SAVE_LENGTH stuff to be
START_LENGTH/END_LENGTH so it actually works; couple other
bugfixes

* test/Makefile.am (dist-hook): add dist-hook for .message files

* dbus/dbus-string.c (DBUS_STRING_COPY_PREAMBLE): source of a copy
can be constant or locked.
(_dbus_string_free): allow freeing a const string as
documented/intended

* dbus/dbus-sysdeps.c (_dbus_concat_dir_and_file): utility

* dbus/dbus-test-main.c (main): take an argument which is the
directory containing test data

* dbus/dbus-message.c (_dbus_message_test): pass a test_data_dir
argument to this and load all the messages in test/data/
checking that they can be loaded or not loaded as appropriate.
/external/dbus/dbus/dbus-test.c
650c2745b8e1065b957779e26413a5040fd97f30 18-Jan-2003 Havoc Pennington <hp@redhat.com> 2003-01-18 Havoc Pennington <hp@pobox.com>

* dbus/dbus-test.c: include config.h so that tests actually run

* dbus/dbus-string.c: add assertions that stuff is 8-byte aligned,
so the failure mode when that assumption fails will be plenty
obvious.
/external/dbus/dbus/dbus-test.c
eae3a9cf885eddf16ecd604cc06fc33b1af4cd45 15-Jan-2003 Havoc Pennington <hp@redhat.com> 2003-01-15 Havoc Pennington <hp@redhat.com>

* dbus/dbus-test.c (dbus_internal_symbol_do_not_use_run_tests):
fix build when --disable-tests

* Makefile.am (EXTRA_DIST): put HACKING in here

* HACKING: document procedure for making a tarball release.
/external/dbus/dbus/dbus-test.c
993be1059afcb0e9a5b67f5287fb1122d6c48ce6 09-Jan-2003 Havoc Pennington <hp@redhat.com> 2003-01-08 Havoc Pennington <hp@pobox.com>

* dbus/dbus-string.c (_dbus_string_align_length): new function

* dbus/dbus-test-main.c: move main() for test app here
* dbus/dbus-test.c
(dbus_internal_symbol_do_not_use_run_tests): we have to export a
symbol to run tests, because dbus-test isn't in the main
library

Code review nitpicks.

* dbus/dbus-message.c (dbus_message_write_header): add newlines
for people with narrow emacs ;-). Assert client_serial was filled
in. Assert message->name != NULL.
(dbus_message_append_fields): have "first_field_type" arg separate
from va list, needed for C++ binding that also uses varargs IIRC
and helps with type safety
(dbus_message_new): add @todo about using DBusString to store
service/name internally
(dbus_message_new): don't leak ->service and ->name on OOM later
in the function
(dbus_message_unref): free the service name
(dbus_message_get_fields): same change to varargs
i.e. first_field_type
(_dbus_message_loader_return_buffer): assert that the message data
is aligned (if not it's a bug in our code). Put in verbose griping
about why we set corrupted = TRUE.
(decode_header_data): add FIXME that char* is evil. Was going to
add FIXME about evil locale-specific string.h strncmp, but just
switched to wacky string-as-uint32 optimization. Move check for
"no room for field name" above get_const_data_len() to avoid
assertion failure in get_const_data_len if we have trailing 2
bytes or the like. Check for service and name fields being
provided twice. Don't leak service/name on error. Require field
names to be aligned to 4 bytes.

* dbus/dbus-marshal.c: move byte swap stuff to header
(_dbus_pack_int32): uscore-prefix
(_dbus_unpack_int32): uscore-prefix
(_dbus_unpack_uint32): export
(_dbus_demarshal_string): add @todo complaining about use of
memcpy()
(_dbus_marshal_get_field_end_pos): add @todo about bad error
handling allowing corrupt data to go unchecked
/external/dbus/dbus/dbus-test.c
1b53cbcce333381754b0568b740ece550a8f6ac9 07-Jan-2003 Anders Carlsson <andersca@codefactory.se> 2003-01-07 Anders Carlsson <andersca@codefactory.se>

* dbus/dbus-connection-internal.h:
* dbus/dbus-connection.c: (_dbus_connection_new_for_transport),
(_dbus_connection_get_next_client_serial),
(dbus_connection_send_message):
* dbus/dbus-internals.h:
* dbus/dbus-marshal.c: (unpack_uint32), (dbus_unpack_int32),
(dbus_pack_int32), (_dbus_marshal_double), (_dbus_marshal_int32),
(_dbus_marshal_uint32), (_dbus_demarshal_double),
(_dbus_demarshal_int32), (_dbus_demarshal_uint32),
(_dbus_demarshal_string), (_dbus_marshal_get_field_end_pos),
(_dbus_verbose_bytes), (_dbus_marshal_test):
* dbus/dbus-marshal.h:
* dbus/dbus-message-internal.h:
* dbus/dbus-message.c: (_dbus_message_set_client_serial),
(dbus_message_write_header), (_dbus_message_lock),
(dbus_message_new), (dbus_message_ref), (dbus_message_unref),
(dbus_message_get_name), (dbus_message_append_int32),
(dbus_message_append_uint32), (dbus_message_append_double),
(dbus_message_append_string), (dbus_message_append_byte_array),
(dbus_message_get_fields_iter), (dbus_message_iter_ref),
(dbus_message_iter_unref), (dbus_message_iter_has_next),
(dbus_message_iter_next), (dbus_message_iter_get_field_type),
(dbus_message_iter_get_string), (dbus_message_iter_get_int32),
(dbus_message_iter_get_uint32), (dbus_message_iter_get_double),
(decode_header_data), (_dbus_message_loader_return_buffer),
(message_iter_test), (_dbus_message_test):
* dbus/dbus-message.h:
* dbus/dbus-protocol.h:
* dbus/dbus-test.c: (main):
* dbus/dbus-test.h:
* glib/test-dbus-glib.c: (message_handler), (main):
* test/echo-client.c: (main):
* test/watch.c: (check_messages):
Make messages sendable and receivable for real.
/external/dbus/dbus/dbus-test.c
2297787455989c9ec47ea899b2ad6f3f6ef72c05 25-Dec-2002 Havoc Pennington <hp@redhat.com> 2002-12-25 Havoc Pennington <hp@pobox.com>

* doc/dbus-sasl-profile.txt: docs on the authentication protocol,
it is a simple protocol that just maps directly to SASL.

* dbus/dbus-auth.h, dbus/dbus-auth.c: authentication protocol
initial implementation, not actually used yet.

* dbus/dbus-string.c (_dbus_string_find): new function
(_dbus_string_equal): new function
(_dbus_string_base64_encode): new function
(_dbus_string_base64_decode): new function
/external/dbus/dbus/dbus-test.c
f25559f534de1d81631b0c517b24a9b0e0818d21 25-Dec-2002 Anders Carlsson <andersca@codefactory.se> 2002-12-25 Anders Carlsson <andersca@codefactory.se>

* dbus/Makefile.am:
* dbus/dbus-marshal.c: (swap_bytes), (_dbus_marshal_double),
(_dbus_marshal_int32), (_dbus_marshal_uint32),
(_dbus_demarshal_double), (_dbus_demarshal_int32),
(_dbus_demarshal_uint32), (_dbus_marshal_test):
* dbus/dbus-marshal.h:
* dbus/dbus-protocol.h:
* dbus/dbus-test.c: (main):
* dbus/dbus-test.h:
Add un-optimized marshalling/demarshalling routines.
/external/dbus/dbus/dbus-test.c
17fbe2b702cdc880abd6cbe117e620b6432f42e0 24-Dec-2002 Havoc Pennington <hp@redhat.com> 2002-12-24 Havoc Pennington <hp@pobox.com>

* glib/dbus-gthread.c: fix include

* glib/dbus-glib.h: rename DBusMessageHandler for now.
I think glib API needs to change, though, as you don't
want to use DBusMessageFunction, you want to use the
DBusMessageHandler object. Probably
dbus_connection_open_with_g_main_loop()
and dbus_connection_setup_g_main_loop() or something like that
(but think of better names...) that just create a connection
that has watch/timeout functions etc. already set up.

* dbus/dbus-connection.c
(dbus_connection_send_message_with_reply): new function just to
show how the message handler helps us deal with replies.

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

* dbus/dbus-string.c (_dbus_string_test): free a string that
wasn't

* dbus/dbus-hash.c: use memory pools for the hash entries
(rebuild_table): be more paranoid about overflow, and
shrink table when we can
(_dbus_hash_test): reduce number of sprintfs and write
valid C89. Add tests for case where we grow and then
shrink the hash table.

* dbus/dbus-mempool.h, dbus/dbus-mempool.c: memory pools

* dbus/dbus-connection.c (dbus_connection_register_handler)
(dbus_connection_unregister_handler): new functions

* dbus/dbus-message.c (dbus_message_get_name): new

* dbus/dbus-list.c: fix docs typo

* dbus/dbus-message-handler.h, dbus/dbus-message-handler.c:
an object representing a handler for messages.
/external/dbus/dbus/dbus-test.c
d4b870e7f91b7018524f7b85dc00b90cc64453bf 12-Dec-2002 Havoc Pennington <hp@redhat.com> 2002-12-11 Havoc Pennington <hp@pobox.com>

* dbus/dbus-types.h: add dbus_unichar

* dbus/dbus-internals.c (_dbus_verbose): use _dbus_getenv

* dbus/dbus-connection.c (dbus_connection_send_message): return
TRUE on success

* dbus/dbus-transport.c: include dbus-watch.h

* dbus/dbus-connection.c: include dbus-message-internal.h

* HACKING: add file with coding guidelines stuff.

* dbus/dbus-string.h, dbus/dbus-string.c: Encapsulate all string
handling here, for security purposes (as in vsftpd). Not actually
using this class yet.

* dbus/dbus-sysdeps.h, dbus/dbus-sysdeps.c: Encapsulate all
system/libc usage here, as in vsftpd, for ease of auditing (and
should also simplify portability). Haven't actually moved all the
system/libc usage into here yet.
/external/dbus/dbus/dbus-test.c
576cdb6e0b1274e9fa5276e01337aef330dd4e8c 23-Nov-2002 Havoc Pennington <hp@redhat.com> 2002-11-23 Havoc Pennington <hp@pobox.com>

* dbus/dbus-internals.h (_DBUS_INT_MAX): add _DBUS_INT_MIN
_DBUS_INT_MAX

* dbus/dbus-test.c (main): add list test, and include
dbus-test.h as intended

* dbus/dbus-hash.c (_dbus_hash_table_remove_string)
(_dbus_hash_table_remove_int): return value indicates
whether the entry existed to remove

* dbus/dbus-list.c: add linked list utility class,
with docs and tests

* dbus/dbus-hash.c: add TODO item about shrinking the hash bucket
array sometimes.
/external/dbus/dbus/dbus-test.c
1428c65e7c46fd9f52e43b7424c56552ec2686e8 23-Nov-2002 Havoc Pennington <hp@redhat.com> 2002-11-23 Havoc Pennington <hp@pobox.com>

* configure.in: pile on more warning flags if using gcc

* Doxyfile.in (EXTRACT_STATIC): set to NO, so we don't have
to document static functions

* configure.in: add summary to end of configure so it
looks nice and attractive

* dbus/dbus-hash.c: finish implementation and write unit
tests and docs

* configure.in: add --enable-tests to enable unit tests

* dbus/dbus-test.c: test program to run unit tests
for all files in dbus/*, initially runs a test for
dbus-hash.c

* dbus/dbus-internals.h: file to hold some internal utility stuff
/external/dbus/dbus/dbus-test.c