about summary refs log tree commit diff stats
diff options
context:
space:
mode:
-rw-r--r--Makefile.am1
-rw-r--r--src/xmpp/avatar.c2
-rw-r--r--src/xmpp/avatar.h2
-rw-r--r--tests/unittests/xmpp/stub_avatar.c7
4 files changed, 10 insertions, 2 deletions
diff --git a/Makefile.am b/Makefile.am
index 6fe31446..95b2401d 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -105,6 +105,7 @@ unittest_sources = \
 	src/event/server_events.c src/event/server_events.h \
 	src/event/client_events.c src/event/client_events.h \
 	src/ui/tray.h src/ui/tray.c \
+	tests/unittests/xmpp/stub_avatar.c \
 	tests/unittests/xmpp/stub_xmpp.c \
 	tests/unittests/xmpp/stub_message.c \
 	tests/unittests/ui/stub_ui.c tests/unittests/ui/stub_ui.h \
diff --git a/src/xmpp/avatar.c b/src/xmpp/avatar.c
index 4d250462..fb69424c 100644
--- a/src/xmpp/avatar.c
+++ b/src/xmpp/avatar.c
@@ -76,7 +76,7 @@ avatar_pep_subscribe(void)
     //caps_add_feature(XMPP_FEATURE_USER_AVATAR_METADATA_NOTIFY);
 }
 
-bool
+gboolean
 avatar_get_by_nick(const char* nick)
 {
     caps_remove_feature(XMPP_FEATURE_USER_AVATAR_METADATA_NOTIFY);
diff --git a/src/xmpp/avatar.h b/src/xmpp/avatar.h
index 8f1415b6..37026542 100644
--- a/src/xmpp/avatar.h
+++ b/src/xmpp/avatar.h
@@ -39,6 +39,6 @@
 #include <glib.h>
 
 void avatar_pep_subscribe(void);
-bool avatar_get_by_nick(const char* nick);
+gboolean avatar_get_by_nick(const char* nick);
 
 #endif
diff --git a/tests/unittests/xmpp/stub_avatar.c b/tests/unittests/xmpp/stub_avatar.c
new file mode 100644
index 00000000..64b8a95f
--- /dev/null
+++ b/tests/unittests/xmpp/stub_avatar.c
@@ -0,0 +1,7 @@
+#include <stdio.h>
+#include <glib.h>
+#include <stdlib.h>
+
+void avatar_pep_subscribe(void) {};
+gboolean avatar_get_by_nick(const char* nick) {return TRUE;}
+