Minor improvements to CON_DEFINESOUND & fixes to prevent getlabel() from picking up tabs and other related characters

git-svn-id: https://svn.eduke32.com/eduke32@107 1a8010ca-5511-0410-912e-c29ae57300e0
This commit is contained in:
terminx 2006-04-24 06:00:20 +00:00
parent 2fa4b89f17
commit f2c77fa152

View file

@ -1607,7 +1607,7 @@ void getlabel(void)
}
i = 0;
while( ispecial(*textptr) == 0 && *textptr!=']' )
while( ispecial(*textptr) == 0 && *textptr!=']' && *textptr!='\t' && *textptr!='\n' && *textptr!='\r')
label[(labelcnt<<6)+i++] = *(textptr++);
label[(labelcnt<<6)+i] = 0;
@ -4647,8 +4647,7 @@ repeatcase:
}
scriptptr--;
i = 0;
while( *textptr == ' ')
textptr++;
skipcomments();
while( *textptr != ' ' )
{
@ -4656,10 +4655,9 @@ repeatcase:
textptr++,i++;
if(i >= BMAX_PATH)
{
puts(sounds[k]);
initprintf("%s:%ld: error: sound filename exceeds limit of %d characters.\n",compilefile,line_number,BMAX_PATH);
error++;
while( *textptr != ' ' ) textptr++;
skipcomments();
break;
}
}