cc: getflag() fmt will be terminated at end of loop (from charles forsyth)
This commit is contained in:
parent
651b2a32be
commit
37d2856f55
1 changed files with 1 additions and 1 deletions
|
@ -76,9 +76,9 @@ getflag(char *s)
|
||||||
nstar = 0;
|
nstar = 0;
|
||||||
while(fmt < e){
|
while(fmt < e){
|
||||||
s += chartorune(&c, s);
|
s += chartorune(&c, s);
|
||||||
fmt += runetochar(fmt, &c);
|
|
||||||
if(c == 0 || c >= nelem(flagbits))
|
if(c == 0 || c >= nelem(flagbits))
|
||||||
break;
|
break;
|
||||||
|
fmt += runetochar(fmt, &c);
|
||||||
f = flagbits[c];
|
f = flagbits[c];
|
||||||
switch(f) {
|
switch(f) {
|
||||||
case Fnone:
|
case Fnone:
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue