Build fixes for bmpx
[monky] / src / bmpx.c
index b54c5b1..fb4076f 100644 (file)
@@ -1,4 +1,5 @@
 /* -*- mode: c; c-basic-offset: 4; tab-width: 4; indent-tabs-mode: t -*-
+ * vim: ts=4 sw=4 noet ai cindent syntax=c
  *
  * Conky, a system monitor, based on torsmo
  *
@@ -8,7 +9,7 @@
  *
  * Please see COPYING for details
  *
- * Copyright (c) 2005-2009 Brenden Matthews, Philip Kovacs, et. al.
+ * Copyright (c) 2005-2010 Brenden Matthews, Philip Kovacs, et. al.
  *     (see AUTHORS)
  * All rights reserved.
  *
@@ -24,8 +25,6 @@
  * You should have received a copy of the GNU General Public License
  * along with this program.  If not, see <http://www.gnu.org/licenses/>.
  *
- * vim: ts=4 sw=4 noet ai cindent syntax=c
- *
  */
 
 #include "config.h"
@@ -43,7 +42,7 @@ static DBusGProxy *remote_object;
 static int connected = 0;
 static char *unknown = "unknown";
 
-void fail(GError *error);
+void fail(GError *error, struct information *);
 
 void update_bmpx()
 {
@@ -59,15 +58,15 @@ void update_bmpx()
                bus = dbus_g_bus_get(DBUS_BUS_SESSION, &error);
                if (bus == NULL) {
                        NORM_ERR("BMPx error 1: %s\n", error->message);
-                       fail(error);
+                       fail(error, current_info);
                        return;
                }
 
                remote_object = dbus_g_proxy_new_for_name(bus, BMP_DBUS_SERVICE,
-                               BMP_DBUS_PATH, BMP_DBUS_INTERFACE);
+                               BMP_DBUS_PATH__BMP, BMP_DBUS_INTERFACE__BMP);
                if (!remote_object) {
                        NORM_ERR("BMPx error 2: %s\n", error->message);
-                       fail(error);
+                       fail(error, current_info);
                        return;
                }
 
@@ -79,7 +78,7 @@ void update_bmpx()
                                        G_TYPE_INVALID, G_TYPE_INT, &current_track, G_TYPE_INVALID)) {
                } else {
                        NORM_ERR("BMPx error 3: %s\n", error->message);
-                       fail(error);
+                       fail(error, current_info);
                        return;
                }
 
@@ -113,17 +112,17 @@ void update_bmpx()
                                g_value_get_string(g_hash_table_lookup(metadata, "location"));
                } else {
                        NORM_ERR("BMPx error 4: %s\n", error->message);
-                       fail(error);
+                       fail(error, current_info);
                        return;
                }
 
                g_hash_table_destroy(metadata);
        } else {
-               fail(error);
+               fail(error, current_info);
        }
 }
 
-void fail(GError *error)
+void fail(GError *error, struct information *current_info)
 {
        if (error) {
                g_error_free(error);