aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/vsprintf.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/vsprintf.c b/lib/vsprintf.c
index e87503e41ad..e14c6ca9f96 100644
--- a/lib/vsprintf.c
+++ b/lib/vsprintf.c
@@ -680,8 +680,10 @@ repeat:
break;
case 'd':
- if (fmt[1] == 'E')
+ if (fmt[1] == 'E') {
flags |= ERRSTR;
+ fmt++;
+ }
/* fallthrough */
case 'i':
flags |= SIGN;
@@ -725,7 +727,6 @@ repeat:
ADDCH(str, ' ');
for (p = errno_str(num); *p; p++)
ADDCH(str, *p);
- fmt++;
}
}