summaryrefslogtreecommitdiff
path: root/tests/unit/gui/test-gui-nick.cpp
diff options
context:
space:
mode:
authorSébastien Helleu <flashcode@flashtux.org>2020-10-04 08:52:37 +0200
committerSébastien Helleu <flashcode@flashtux.org>2020-10-04 08:53:08 +0200
commitbb82dbc0ecdf1a7a54c2e47093d862e0e5b31a11 (patch)
tree778f1f4160f2c987e1535afc3e85dff6a39923fc /tests/unit/gui/test-gui-nick.cpp
parentf8403c76db457b89c36865d1cb3771df5626ff6e (diff)
downloadweechat-bb82dbc0ecdf1a7a54c2e47093d862e0e5b31a11.zip
tests: add missing braces around if/else in macro WEE_NICK_STRDUP_FOR_COLOR (issue #1565)
Diffstat (limited to 'tests/unit/gui/test-gui-nick.cpp')
-rw-r--r--tests/unit/gui/test-gui-nick.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/tests/unit/gui/test-gui-nick.cpp b/tests/unit/gui/test-gui-nick.cpp
index b275dfd7c..e366ab751 100644
--- a/tests/unit/gui/test-gui-nick.cpp
+++ b/tests/unit/gui/test-gui-nick.cpp
@@ -55,9 +55,13 @@ extern char *gui_nick_strdup_for_color (const char *nickname);
#define WEE_NICK_STRDUP_FOR_COLOR(__result, __nickname) \
nick = gui_nick_strdup_for_color (__nickname); \
if (__result) \
+ { \
STRCMP_EQUAL(__result, nick); \
+ } \
else \
+ { \
POINTERS_EQUAL(NULL, nick); \
+ } \
if (nick) \
free (nick);