From d40bb4f94b62e26fbf751fc33550373fa8741780 Mon Sep 17 00:00:00 2001 From: Tom Early Date: Fri, 24 Feb 2023 09:52:30 -0700 Subject: [PATCH] fixed HasSuffix --- reflector/Callsign.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/reflector/Callsign.cpp b/reflector/Callsign.cpp index 328c5e1..940c334 100644 --- a/reflector/Callsign.cpp +++ b/reflector/Callsign.cpp @@ -168,8 +168,7 @@ bool CCallsign::IsValid(void) const // is an letter or space valid = valid && (IsLetter(m_Module) || IsSpace(m_Module)); - // dmrid is not tested, as it can be nullptr - // if station does is not dmr registered + // dmr and nxdn id is not tested, as it can be 0 if station is not registered // done return valid; @@ -177,7 +176,7 @@ bool CCallsign::IsValid(void) const bool CCallsign::HasSuffix(void) const { - return 0 == memcmp(m_Suffix.c, " ", 4); + return 0x20202020u != m_Suffix.u; } ////////////////////////////////////////////////////////////////////////////////////////