summaryrefslogtreecommitdiff
path: root/src/multibyte
diff options
context:
space:
mode:
Diffstat (limited to 'src/multibyte')
-rw-r--r--src/multibyte/wcsnrtombs.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/multibyte/wcsnrtombs.c b/src/multibyte/wcsnrtombs.c
index 7eb05d45..ee4a534a 100644
--- a/src/multibyte/wcsnrtombs.c
+++ b/src/multibyte/wcsnrtombs.c
@@ -40,7 +40,7 @@ size_t wcsnrtombs(char *restrict dst, const wchar_t **restrict wcs, size_t wn, s
ws++; wn--;
/* safe - this loop runs fewer than sizeof(buf) times */
s+=l; n-=l;
- cnt++;
+ cnt += l;
}
if (dst) *wcs = ws;
return cnt;