From 44f81dfda7639afb0726e03c301362ec7301b8b3 Mon Sep 17 00:00:00 2001 From: Ben Date: Tue, 13 Apr 2010 19:38:58 +0000 Subject: [PATCH] const warning fix. --- thpresence.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/thpresence.c b/thpresence.c index 2aad406..be5921e 100644 --- a/thpresence.c +++ b/thpresence.c @@ -17,6 +17,7 @@ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA */ #include +#include "debug.h" #include "status.h" #include "account.h" #include "thpresence.h" @@ -34,12 +35,13 @@ void thrasher_set_presence (PurpleAccount *pa, PurpleStatusPrimitive primitive, /* Flip the status on if we have a status_id */ if (type) { - char *status_id = purple_status_type_get_id(type); + const char *status_id = purple_status_type_get_id(type); PurplePresence *presence = purple_presence_new_for_account(pa); PurpleStatus *status = purple_status_new(type, presence); - if (message && purple_status_get_attr_value(status, "message")) + if (message && purple_status_get_attr_value(status, "message")) { /* Don't add message if not supported by this status. */ purple_account_set_status(pa, status_id, TRUE, "message", message, NULL); + } else purple_account_set_status(pa, status_id, TRUE, NULL); } -- 2.11.4.GIT