From 33934861193c4e256158e35947e62c17b13b3964 Mon Sep 17 00:00:00 2001 From: Richard Fuchs Date: Thu, 29 Jan 2026 15:04:26 -0400 Subject: [PATCH] MT#62181 use `false` to indicate failure Reverses the meaning of the return value Change-Id: If392c5f273355fd03c55855b1b4f2a2b9c303a07 --- apps/dsm/mods/mod_zrtp/ModZrtp.cpp | 2 +- apps/sbc/SBCCallProfile.cpp | 2 +- apps/sbc/arg_conversion.cpp | 2 +- core/AmUtils.cpp | 2 +- core/AmZRTP.cpp | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/apps/dsm/mods/mod_zrtp/ModZrtp.cpp b/apps/dsm/mods/mod_zrtp/ModZrtp.cpp index d09026f5..f104a949 100644 --- a/apps/dsm/mods/mod_zrtp/ModZrtp.cpp +++ b/apps/dsm/mods/mod_zrtp/ModZrtp.cpp @@ -182,7 +182,7 @@ EXEC_ACTION_START(ZRTPGetSessionInfoAction) { bool hex2zid(const string& zid1, char* buffer) { for (size_t i=0;i= encoded.size()) return false; unsigned int c; - if (reverse_hex2int(string() + encoded[pos + 2] + encoded[pos + 1], c)) { + if (!reverse_hex2int(string() + encoded[pos + 2] + encoded[pos + 1], c)) { DBG("%c%c does not convert from hex\n", encoded[pos + 1], encoded[pos + 2]); return false; } diff --git a/core/AmUtils.cpp b/core/AmUtils.cpp index 1297e17b..e932e2b9 100644 --- a/core/AmUtils.cpp +++ b/core/AmUtils.cpp @@ -188,7 +188,7 @@ string double2str(double val) { * Convert a reversed hex string to uint. * @param str [in] string to convert. * @param result [out] result integer. - * @return true if failed. + * @return true on success */ bool reverse_hex2int(const string& str, unsigned int& result) { diff --git a/core/AmZRTP.cpp b/core/AmZRTP.cpp index 7c4e0298..9bd02fcc 100644 --- a/core/AmZRTP.cpp +++ b/core/AmZRTP.cpp @@ -81,7 +81,7 @@ int AmZRTP::init() { for (size_t i=0;i