about summary refs log tree commit diff
path: root/wcsmbs/mbrtowc.c
diff options
context:
space:
mode:
Diffstat (limited to 'wcsmbs/mbrtowc.c')
-rw-r--r--wcsmbs/mbrtowc.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/wcsmbs/mbrtowc.c b/wcsmbs/mbrtowc.c
index 034ccfec41..7c05680d91 100644
--- a/wcsmbs/mbrtowc.c
+++ b/wcsmbs/mbrtowc.c
@@ -42,7 +42,7 @@ __mbrtowc (wchar_t *pwc, const char *s, size_t n, mbstate_t *ps)
   size_t dummy;
   const unsigned char *inbuf;
   char *outbuf = (char *) (pwc ?: buf);
-  int flush;
+  int flush = 0;
 
   /* Set information for this step.  */
   data.__invocation_counter = 0;
@@ -60,8 +60,6 @@ __mbrtowc (wchar_t *pwc, const char *s, size_t n, mbstate_t *ps)
       n = 1;
       flush = 1;
     }
-  else
-    flush = *s == '\0' ? 1 : 0;
 
   /* Tell where we want the result.  */
   data.__outbuf = outbuf;