Remove various never-used variables
authorSimon McVittie <simon.mcvittie@collabora.co.uk>
Thu, 14 Jul 2011 17:44:46 +0000 (18:44 +0100)
committerSimon McVittie <simon.mcvittie@collabora.co.uk>
Fri, 5 Aug 2011 11:26:51 +0000 (12:26 +0100)
Bug: https://bugs.freedesktop.org/show_bug.cgi?id=39231
Reviewed-by: Will Thompson <will.thompson@collabora.co.uk>
bus/activation.c
bus/bus.c
bus/dispatch.c
bus/main.c
dbus/dbus-internals.c
dbus/dbus-nonce.c
dbus/dbus-server-socket.c
dbus/dbus-sysdeps-util-unix.c
test/dbus-daemon.c
test/marshal.c
test/name-test/test-privserver-client.c

index d5424a7..6101173 100644 (file)
@@ -881,8 +881,6 @@ bus_activation_new (BusContext        *context,
                     DBusError         *error)
 {
   BusActivation *activation;
-  DBusList      *link;
-  char          *dir;
 
   _DBUS_ASSERT_ERROR_IS_CLEAR (error);
 
@@ -1671,7 +1669,6 @@ bus_activation_activate_service (BusActivation  *activation,
   char **envp = NULL;
   int argc;
   dbus_bool_t retval;
-  DBusHashIter iter;
   dbus_bool_t was_pending_activation;
   DBusString command;
 
index 04b1286..748ee90 100644 (file)
--- a/bus/bus.c
+++ b/bus/bus.c
@@ -481,7 +481,6 @@ process_config_every_time (BusContext      *context,
   DBusString full_address;
   DBusList *link;
   DBusList **dirs;
-  BusActivation *new_activation;
   char *addr;
   const char *servicehelper;
   char *s;
@@ -688,7 +687,6 @@ bus_context_new (const DBusString *config_file,
                  dbus_bool_t      systemd_activation,
                  DBusError        *error)
 {
-  DBusString log_prefix;
   BusContext *context;
   BusConfigParser *parser;
 
@@ -1393,9 +1391,6 @@ bus_context_check_security_policy (BusContext     *context,
   dbus_bool_t log;
   int type;
   dbus_bool_t requested_reply;
-  const char *sender_name;
-  const char *sender_loginfo;
-  const char *proposed_recipient_loginfo;
 
   type = dbus_message_get_type (message);
   dest = dbus_message_get_destination (message);
@@ -1561,9 +1556,6 @@ bus_context_check_security_policy (BusContext     *context,
                                          proposed_recipient,
                                          message, &toggles, &log))
     {
-      const char *msg = "Rejected send message, %d matched rules; "
-                        "type=\"%s\", sender=\"%s\" (%s) interface=\"%s\" member=\"%s\" error name=\"%s\" requested_reply=%d destination=\"%s\" (%s))";
-
       complain_about_message (context, DBUS_ERROR_ACCESS_DENIED,
           "Rejected send message", toggles,
           message, sender, proposed_recipient, requested_reply,
index a80476c..dfe6f74 100644 (file)
@@ -4773,7 +4773,6 @@ bus_unix_fds_passing_test(const DBusString *test_data_dir)
   DBusConnection *foo, *bar;
   DBusError error;
   DBusMessage *m;
-  dbus_bool_t b;
   int one[2], two[2], x, y, z;
   char r;
 
index 74b8bd2..594e3fb 100644 (file)
@@ -288,7 +288,6 @@ main (int argc, char **argv)
   int i;
   dbus_bool_t print_address;
   dbus_bool_t print_pid;
-  dbus_bool_t is_session_bus;
   int force_fork;
   dbus_bool_t systemd_activation;
 
@@ -306,7 +305,6 @@ main (int argc, char **argv)
 
   print_address = FALSE;
   print_pid = FALSE;
-  is_session_bus = FALSE;
   force_fork = FORK_FOLLOW_CONFIG_FILE;
   systemd_activation = FALSE;
 
index 95a491f..fcea079 100644 (file)
@@ -347,7 +347,6 @@ _dbus_verbose_init (void)
 static char *_dbus_file_path_extract_elements_from_tail(const char *file,int level)
 {
   static int prefix = -1;
-  char *p;
 
   if (prefix == -1) 
     {
index d30b253..e74c2dd 100644 (file)
@@ -196,7 +196,6 @@ _dbus_send_nonce (int fd, const DBusString *noncefile, DBusError *error)
 {
   dbus_bool_t read_result;
   int send_result;
-  size_t sendLen;
   DBusString nonce;
 
   _DBUS_ASSERT_ERROR_IS_CLEAR (error);
@@ -240,7 +239,6 @@ do_noncefile_create (DBusNonceFile *noncefile,
                      DBusError *error,
                      dbus_bool_t use_subdir)
 {
-    dbus_bool_t ret;
     DBusString randomStr;
 
     _DBUS_ASSERT_ERROR_IS_CLEAR (error);
index 02973c1..8e31da9 100644 (file)
@@ -89,10 +89,8 @@ handle_new_client_fd_and_unlock (DBusServer *server,
   DBusConnection *connection;
   DBusTransport *transport;
   DBusNewConnectionFunction new_connection_function;
-  DBusServerSocket* socket_server;
   void *new_connection_data;
 
-  socket_server = (DBusServerSocket*)server;
   _dbus_verbose ("Creating new client connection with fd %d\n", client_fd);
 
   HAVE_LOCK_CHECK (server);
index a80f643..805c919 100644 (file)
@@ -389,7 +389,6 @@ _dbus_request_file_descriptor_limit (unsigned int limit)
 #ifdef HAVE_SETRLIMIT
   struct rlimit lim;
   struct rlimit target_lim;
-  unsigned int current_limit;
 
   /* No point to doing this practically speaking
    * if we're not uid 0.  We expect the system
index c190cb4..eaacb87 100644 (file)
@@ -150,8 +150,6 @@ echo_filter (DBusConnection *connection,
     void *user_data)
 {
   DBusMessage *reply;
-  DBusError error = DBUS_ERROR_INIT;
-  int *sleep_ms = user_data;
 
   if (dbus_message_get_type (message) != DBUS_MESSAGE_TYPE_METHOD_CALL)
     return DBUS_HANDLER_RESULT_NOT_YET_HANDLED;
index 4cee941..e9ac7e3 100644 (file)
@@ -146,7 +146,6 @@ test_endian (Fixture *f,
     gconstpointer arg)
 {
   const gchar *blob = arg;
-  const gchar *native_blob;
   char *output;
   DBusMessage *m;
   int len;
index 1c43fae..e7f4896 100644 (file)
@@ -71,7 +71,6 @@ open_shutdown_private_connection (dbus_bool_t use_guid)
   DBusMessage *reply;
   DBusConnection *privconn;
   char *addr;
-  char *comma;
   dbus_bool_t service_died;
   dbus_bool_t private_conn_lost;