summaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorJohn (J5) Palmieri <johnp@redhat.com>2006-08-14 19:11:35 +0000
committerJohn (J5) Palmieri <johnp@redhat.com>2006-08-14 19:11:35 +0000
commitc1091cbbd2477699dc16f8c8e3d15fea2f68d603 (patch)
tree46585d8e26a06dc84dd93bcb9fa846127db50b65 /test
parent2592a2abb26683bf0a2ec23b6aa19dc7bafa5878 (diff)
Patches by Kjartan Maraas <kmaraas at gnome dot org>
* bus/services.c (bus_service_list_queued_owners): Add a pointer cast to fix compiler warning * dbus/dbus-dataslot.c (_dbus_data_slot_list_get): return a NULL instead of FALSE since the return type is not expecting a boolean * dbus/dbus-marshal-basic.c (_dbus_marshal_test): Remove unused variable * dbus/dbus-marshal-recursive-util.c (node_new): return a NULL instead of FALSE since the return type is not expecting a boolean * dbus/dbus-server-debug-pipe.c (_dbus_transport_debug_pipe_new): Send a NULL into _dbus_transport_new_for_fd instead of a FALSE because we are expecting a pointer not a boolean * dbus/dbus-sysdeps-util.c (_dbus_get_tmpdir): add void as the parameter so some compilers don't complain * dbus/dbus-transport-unix.c (_dbus_transport_new_for_domain_socket, _dbus_transport_new_for_tcp_socket): Send a NULL into _dbus_transport_new_for_fd instead of a FALSE because we are expecting a pointer not a boolean * test/shell-test.c (test_command_line): cast the second argument to _dbus_list_append to avoid compiler warnings * test/test-names.c (main): remove unused variable * test/test-service.c (check_hello_from_self_reply): Initialize echo_message and echo_reply to NULL * test/test-shell-service.c (handle_echo): Remove unused variable and cast the third parameter passed to dbus_connection_get_object_path_data to avoid compiler warrnings * test/name-test/test-names.c (clear_message_queue): Remove unused function * test/name-test/test-pending-call-dispatch.c: Fix format string in printf
Diffstat (limited to 'test')
-rw-r--r--test/name-test/test-names.c19
-rw-r--r--test/name-test/test-pending-call-dispatch.c2
-rw-r--r--test/shell-test.c2
-rw-r--r--test/test-names.c1
-rw-r--r--test/test-service.c2
-rw-r--r--test/test-shell-service.c3
6 files changed, 4 insertions, 25 deletions
diff --git a/test/name-test/test-names.c b/test/name-test/test-names.c
index 3cf7047b..d25ff6a7 100644
--- a/test/name-test/test-names.c
+++ b/test/name-test/test-names.c
@@ -193,25 +193,6 @@ check_connection (DBusConnection *conn,
return FALSE;
}
-static void
-clear_message_queue (DBusConnection *conn)
-{
- int tries;
- DBusMessage *msg;
-
- for (tries = 0; tries < NUM_TRIES_TIL_FAIL; tries++)
- {
- _dbus_connection_lock (conn);
- _dbus_connection_do_iteration_unlocked (conn,
- DBUS_ITERATION_DO_READING |
- DBUS_ITERATION_DO_WRITING |
- DBUS_ITERATION_BLOCK,
- 0);
- _dbus_connection_unlock (conn);
- msg = dbus_connection_pop_message (conn);
- }
-}
-
static dbus_bool_t
match_acquired_or_lost_signal (DBusConnection *conn, const char *member, const char *name)
{
diff --git a/test/name-test/test-pending-call-dispatch.c b/test/name-test/test-pending-call-dispatch.c
index 4df2ed37..54726498 100644
--- a/test/name-test/test-pending-call-dispatch.c
+++ b/test/name-test/test-pending-call-dispatch.c
@@ -103,7 +103,7 @@ main (int argc, char *argv[])
/* we just care about seconds */
delta = end_tv_sec - start_tv_sec;
- printf ("Iter %i: %is\n", i, delta);
+ printf ("Iter %i: %lis\n", i, delta);
if (delta >= 5)
{
printf ("Failed: looks like we might have been be stuck in poll ***\n");
diff --git a/test/shell-test.c b/test/shell-test.c
index 4115f191..c0134677 100644
--- a/test/shell-test.c
+++ b/test/shell-test.c
@@ -21,7 +21,7 @@ test_command_line (const char *arg1, ...)
DBusError error;
va_start (var_args, arg1);
- _dbus_list_append (&list, arg1);
+ _dbus_list_append (&list, (char *)arg1);
do
{
tmp = va_arg (var_args, char *);
diff --git a/test/test-names.c b/test/test-names.c
index b29648dc..e618e99b 100644
--- a/test/test-names.c
+++ b/test/test-names.c
@@ -46,7 +46,6 @@ main (int argc,
char **argv)
{
DBusError error;
- int result;
DBusConnection *connection;
dbus_error_init (&error);
diff --git a/test/test-service.c b/test/test-service.c
index 77b8b3ca..ed47a506 100644
--- a/test/test-service.c
+++ b/test/test-service.c
@@ -27,7 +27,7 @@ check_hello_from_self_reply (DBusPendingCall *pcall,
void *user_data)
{
DBusMessage *reply;
- DBusMessage *echo_message, *echo_reply;
+ DBusMessage *echo_message, *echo_reply = NULL;
DBusError error;
DBusConnection *connection;
diff --git a/test/test-shell-service.c b/test/test-shell-service.c
index 79a4949a..71b4baae 100644
--- a/test/test-shell-service.c
+++ b/test/test-shell-service.c
@@ -36,12 +36,11 @@ handle_echo (DBusConnection *connection,
DBusMessage *reply;
DBusMessageIter iter;
int i;
- char *s;
EchoData *d;
_dbus_verbose ("sending reply to Echo method\n");
- if (!dbus_connection_get_object_path_data (connection, echo_path, &d))
+ if (!dbus_connection_get_object_path_data (connection, echo_path, (void **)&d))
die ("No memory");