[Core] scan-build: Argument with 'nonnull' attribute passed null in switch_xml_internal_dtd()

This commit is contained in:
Andrey Volk 2021-04-20 02:05:20 +03:00
parent 6726922e34
commit e30c62f8ec
1 changed files with 1 additions and 1 deletions

View File

@ -882,7 +882,7 @@ static short switch_xml_internal_dtd(switch_xml_root_t root, char *s, switch_siz
continue;
else
*s = '\0'; /* null terminate tag name */
for (i = 0; root->attr[i] && strcmp(n, root->attr[i][0]); i++);
for (i = 0; root->attr[i] && n && strcmp(n, root->attr[i][0]); i++);
//while (*(n = ++s + strspn(s, SWITCH_XML_WS)) && *n != '>') {
// gcc 4.4 you are a creep