about summary refs log tree commit diff stats
path: root/tests/unittests/config
diff options
context:
space:
mode:
authorFrank Zschockelt <profanity@freakysoft.de>2019-05-08 21:51:29 +0200
committerFrank Zschockelt <profanity@freakysoft.de>2019-05-08 21:51:29 +0200
commita5db791dc484bfde7df067911d8ee9f95968b88d (patch)
treebac196bad0d3eef71ce730ec7e9dca1794e25625 /tests/unittests/config
parentc94f3d0b4ad3dbad3f33cbe0d7c19c6cd41e7aea (diff)
downloadprofani-tty-a5db791dc484bfde7df067911d8ee9f95968b88d.tar.gz
Use mock_ptr_type() to silence compiler warnings
Unit tests on 32-bit architectures were failing due to
"cast to pointer from integer of different size" warnings.
mock_ptr_type silences those by first casting to uintptr_t.
Diffstat (limited to 'tests/unittests/config')
-rw-r--r--tests/unittests/config/stub_accounts.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/unittests/config/stub_accounts.c b/tests/unittests/config/stub_accounts.c
index b164497e..e0489e0a 100644
--- a/tests/unittests/config/stub_accounts.c
+++ b/tests/unittests/config/stub_accounts.c
@@ -36,13 +36,13 @@ int  accounts_remove(const char *jid)
 
 gchar** accounts_get_list(void)
 {
-    return (gchar **)mock();
+    return mock_ptr_type(gchar **);
 }
 
 ProfAccount* accounts_get_account(const char * const name)
 {
     check_expected(name);
-    return (ProfAccount*)mock();
+    return mock_ptr_type(ProfAccount*);
 }
 
 gboolean accounts_enable(const char * const name)