From: traud Date: Thu, 2 Apr 2020 17:14:41 +0000 (+0200) Subject: stasis: Avoid always true warnings with clang. X-Git-Tag: 13.33.0-rc1~26 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9082f9021707f17c87ba3dfff67caf593dcb5e67;p=thirdparty%2Fasterisk.git stasis: Avoid always true warnings with clang. ASTERISK-28801 Change-Id: I63ba125226b9fe8a018bd28825c877603eb8f398 --- diff --git a/main/stasis.c b/main/stasis.c index ff638bfbf8..c9b71cf116 100644 --- a/main/stasis.c +++ b/main/stasis.c @@ -473,9 +473,9 @@ struct stasis_topic *stasis_topic_create(const char *name) #ifdef AST_DEVMODE topic->statistics = stasis_topic_statistics_create(topic); - if (!topic->name || !topic->statistics || res) + if (ast_strlen_zero(topic->name) || !topic->statistics || res) #else - if (!topic->name || res) + if (ast_strlen_zero(topic->name) || res) #endif { ao2_ref(topic, -1);