Shut up a warning about potentially passing a null ptr to strlen() by way of a bad FILE ptr. The condition wasn't actually possible, but this is just as or more correct than it was before. This sure is a long commit message for something that only adds an 'else'.

git-svn-id: https://svn.eduke32.com/eduke32@7099 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
terminx 2018-10-25 23:30:41 +00:00
parent a6021590f7
commit 2b01ea19b1

View file

@ -728,8 +728,7 @@ static uint8_t *writespecdata(const dataspec_t *spec, FILE *fil, uint8_t *dump)
if (!fil && (sp->flags&(DS_NOCHK|DS_CMP|DS_STRING)))
continue;
if (sp->flags&DS_STRING)
else if (sp->flags&DS_STRING)
{
fwrite(sp->ptr, Bstrlen((const char *)sp->ptr), 1, fil); // not null-terminated!
continue;