cawf(1): remove various redundant comparisons

Reported by dcb314.

This fixes #135, #136.

Change-Id: I0f83a92e18adf68e5ad493b9057d093a6b37b328
This commit is contained in:
David van Moolenbroek 2016-06-17 20:09:08 +00:00
parent dc2c582f36
commit 4d3708913c
2 changed files with 2 additions and 2 deletions

View File

@ -104,7 +104,7 @@ void Pass2(unsigned char *line) {
* Output each word of the line as "<length> <word>".
*/
for (s1 = line;;) {
while (*s1 && *s1 == ' ')
while (*s1 == ' ')
s1++;
if (*s1 == '\0')
break;

View File

@ -43,7 +43,7 @@ int Asmname(unsigned char *s, unsigned char *c) {
* code destination (c[3])
*/
c[1] = c[2] = '\0';
while (*s && *s == ' ')
while (*s == ' ')
s++;
if ((c[0] = *s) == '\0')
return(0);