Fixes configuration bug; when "Symbol=" value contains a valid APRS literal "#", it was parsed as a comment and not honored (now has more strict checking).

This commit is contained in:
Chipster 2023-04-30 07:44:05 -05:00
parent ac2f19c692
commit ff4e8a9507

View file

@ -262,8 +262,8 @@ bool CConf::read()
char *p;
// if value is not quoted, remove after # (to make comment)
if ((p = strchr(value, '#')) != NULL)
*p = '\0';
if ((p = strchr(value, '#')) != NULL && p == value)
*p = '\0';
// remove trailing tab/space
for (p = value + strlen(value) - 1U; p >= value && (*p == '\t' || *p == ' '); p--)