]> git.ipfire.org Git - thirdparty/dbus.git/commitdiff
Patches by Kjartan Maraas <kmaraas at gnome dot org>
authorJohn (J5) Palmieri <johnp@redhat.com>
Mon, 14 Aug 2006 19:11:35 +0000 (19:11 +0000)
committerJohn (J5) Palmieri <johnp@redhat.com>
Mon, 14 Aug 2006 19:11:35 +0000 (19:11 +0000)
        * 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

16 files changed:
ChangeLog
bus/services.c
dbus/dbus-dataslot.c
dbus/dbus-marshal-basic.c
dbus/dbus-marshal-recursive-util.c
dbus/dbus-server-debug-pipe.c
dbus/dbus-sysdeps-util.c
dbus/dbus-sysdeps.c
dbus/dbus-sysdeps.h
dbus/dbus-transport-unix.c
test/name-test/test-names.c
test/name-test/test-pending-call-dispatch.c
test/shell-test.c
test/test-names.c
test/test-service.c
test/test-shell-service.c

index 1bba3cb8b99e7df98899f1ce9291941ea45e861c..a99c2a957e73c63d6932205a297269fa7f931f4b 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,54 @@
+2006-08-14  John (J5) Palmieri  <johnp@redhat.com>
+
+       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
+
+
 2006-08-14  John (J5) Palmieri  <johnp@redhat.com>
 
        * dbus/dbus-bus.c:
index 52f522b4206e384f0f504c88c3aaad034349ace5..bb7e77f4e161bcb406b4ac69e029f2c59911c76c 100644 (file)
@@ -1266,7 +1266,7 @@ bus_service_list_queued_owners (BusService *service,
       owner = (BusOwner *) link->data;
       uname = bus_connection_get_name (owner->conn);
 
-      if (!_dbus_list_append (return_list, uname))
+      if (!_dbus_list_append (return_list, (char *)uname))
         goto oom;
 
       link = _dbus_list_get_next_link (&service->owners, link);
index 8b1bbb87167af20e5cd870a05292ee8adc20e2d6..83e25865c5db550f411e0ff59bda4b22e3943c91 100644 (file)
@@ -305,7 +305,7 @@ _dbus_data_slot_list_get  (DBusDataSlotAllocator *allocator,
    * are disabled, since then the asserts are empty.
    */
   if (!_dbus_mutex_lock (allocator->lock))
-    return FALSE;
+    return NULL;
   _dbus_assert (slot >= 0);
   _dbus_assert (slot < allocator->n_allocated_slots);
   _dbus_assert (allocator->allocated_slots[slot].slot_id == slot);
index b983ae56a4f68f8b243f2098bc95e5835c6fa185..048e85a18f85c7b430bd7840f72f50f92fbfe988 100644 (file)
@@ -1663,7 +1663,6 @@ _dbus_marshal_test (void)
   dbus_uint16_t *v_ARRAY_UINT16;
   dbus_int32_t *v_ARRAY_INT32;
   dbus_uint32_t *v_ARRAY_UINT32;
-  double *v_ARRAY_DOUBLE;
   DBusString t;
   double v_DOUBLE;
   double t_DOUBLE;
index 2a2c57d95436c545f4c93d52eacf4ac19610ee60..c2e9b411a4ab6d4d2dac4276c1cb85930538eae2 100644 (file)
@@ -945,7 +945,7 @@ node_new (const TestTypeNodeClass *klass)
       if (!(* klass->construct) (node))
         {
           dbus_free (node);
-          return FALSE;
+          return NULL;
         }
     }
 
index 57882d97152f7c493b723d7ba1523e46e63f3830..0917c1e09bf35d4efcfabee1093b07c1f0484b76 100644 (file)
@@ -257,7 +257,7 @@ _dbus_transport_debug_pipe_new (const char     *server_name,
   _dbus_fd_set_close_on_exec (server_fd);
   
   client_transport = _dbus_transport_new_for_fd (client_fd,
-                                                 FALSE, &address);
+                                                 NULL, &address);
   if (client_transport == NULL)
     {
       _dbus_close (client_fd, NULL);
index bfc87801d7ba20d48b0c849a40892adbadf2a89e..ebe20b4aad3663b909f79aa58f2fad82c1b187be 100644 (file)
@@ -297,7 +297,7 @@ _dbus_set_signal_handler (int               sig,
   act.sa_handler = handler;
   act.sa_mask    = empty_mask;
   act.sa_flags   = 0;
-  sigaction (sig,  &act, 0);
+  sigaction (sig,  &act, NULL);
 }
 
 
index 43bfcd8c950d6e6f83223ca560e6e037946138c5..20ff014f569183b4201887130a13e3fc43c7233f 100644 (file)
@@ -3005,7 +3005,7 @@ int _dbus_printf_string_upper_bound (const char *format,
  * @returns char* - location of temp directory
  */
 char*
-_dbus_get_tmpdir()
+_dbus_get_tmpdir(void)
 {
   char* tmpdir;
 
index 8e7c5019a4990458e858837916d94afcdc7bdde5..1df9986e9fab761eaecabc0e32fadfb19b54148e 100644 (file)
@@ -323,7 +323,7 @@ void _dbus_set_signal_handler (int               sig,
 dbus_bool_t _dbus_file_exists     (const char *file);
 dbus_bool_t _dbus_user_at_console (const char *username,
                                    DBusError  *error);
-char* _dbus_get_tmpdir();
+char* _dbus_get_tmpdir(void);
 
 /* Define DBUS_VA_COPY() to do the right thing for copying va_list variables. 
  * config.h may have already defined DBUS_VA_COPY as va_copy or __va_copy. 
index 39216cab84f450e2ea9e774f81fd5e4ea6c13cec..b2f7faa3627169fecc50ae9534dd5a18065982ea 100644 (file)
@@ -1229,7 +1229,7 @@ _dbus_transport_new_for_domain_socket (const char     *path,
   _dbus_verbose ("Successfully connected to unix socket %s\n",
                  path);
 
-  transport = _dbus_transport_new_for_fd (fd, FALSE, &address);
+  transport = _dbus_transport_new_for_fd (fd, NULL, &address);
   if (transport == NULL)
     {
       dbus_set_error (error, DBUS_ERROR_NO_MEMORY, NULL);
@@ -1297,7 +1297,7 @@ _dbus_transport_new_for_tcp_socket (const char     *host,
   _dbus_verbose ("Successfully connected to tcp socket %s:%d\n",
                  host, port);
   
-  transport = _dbus_transport_new_for_fd (fd, FALSE, &address);
+  transport = _dbus_transport_new_for_fd (fd, NULL, &address);
   if (transport == NULL)
     {
       dbus_set_error (error, DBUS_ERROR_NO_MEMORY, NULL);
index 3cf7047be7fbf6467448366a03e3641051429eb3..d25ff6a7d3f46e9cd2441d216de3ce6e28d230d1 100644 (file)
@@ -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)
 {
index 4df2ed37c37164618b7d53e1ada07de1c5106b74..54726498f8f91f8576146adac3b1a06614fd5714 100644 (file)
@@ -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");
index 4115f191343aacc118cf84ee3295556bbaf5e51f..c01346774166dd07ae38650e9f69dba75964243e 100644 (file)
@@ -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 *);
index b29648dc37690243f85357457cb89a024011f2fb..e618e99b540f03e811e3da744cc725356a4014c6 100644 (file)
@@ -46,7 +46,6 @@ main (int    argc,
       char **argv)
 {
   DBusError error;
-  int result;
   DBusConnection *connection;
   
   dbus_error_init (&error);
index 77b8b3caae98c8c5961bc98634d467ca42018dce..ed47a5063904198711bd8bd5f85a67962a5456ea 100644 (file)
@@ -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;
   
index 79a4949a520c1d68d385f94d6bc01cac2b1a431a..71b4baae92b10a0984793339c1c4a8f8ba860b63 100644 (file)
@@ -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");