Merge pull request #209 from narspt/patch-14

change SetYsfCallsign() to trim callsign on null char
This commit is contained in:
LX3JL 2021-11-18 12:57:31 +01:00 committed by GitHub
commit e87eb8e3dd
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View file

@ -207,7 +207,7 @@ void CCallsign::SetYsfCallsign(const char *sz)
m_uiDmrid = 0;
// set callsign
for ( i = 0; (i < sizeof(m_Callsign)) && (sz[i] != '/') && (sz[i] != '-'); i++ )
for ( i = 0; (i < sizeof(m_Callsign)) && (sz[i] != '/') && (sz[i] != '-') && (sz[i] != 0x00); i++ )
{
m_Callsign[i] = sz[i];
}

View file

@ -50,7 +50,7 @@
#define VERSION_MAJOR 2
#define VERSION_MINOR 5
#define VERSION_REVISION 1
#define VERSION_REVISION 2
// global ------------------------------------------------------