From a7d28aa53a772a950f79d189310b32a3a765c007 Mon Sep 17 00:00:00 2001 From: Gary Kramlich Date: Fri, 7 Apr 2023 00:49:29 -0500 Subject: Fix some issues where we were triggering GWarnings with presence Testing Done: I ran into these while porting the Bonjour prpl to the new status API, so I verified they stopped happening against that code. Reviewed at https://reviews.imfreedom.org/r/2426/ --- libpurple/purplepresence.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'libpurple') diff --git a/libpurple/purplepresence.c b/libpurple/purplepresence.c index 0182e54760..5095ddf28a 100644 --- a/libpurple/purplepresence.c +++ b/libpurple/purplepresence.c @@ -653,6 +653,10 @@ purple_presence_get_message(PurplePresence *presence) { return priv->message; } + if(priv->active_status == NULL) { + return NULL; + } + return purple_status_get_attr_string(priv->active_status, "message"); } -- cgit v1.2.1