From ce7ce1b948733084e16fb133ec47d622a67dcf61 Mon Sep 17 00:00:00 2001 From: Mattias Andrée Date: Sun, 25 Nov 2018 23:13:47 +0100 Subject: m MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Mattias Andrée --- wcsndup.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'wcsndup.c') diff --git a/wcsndup.c b/wcsndup.c index 83e227d..ba4e009 100644 --- a/wcsndup.c +++ b/wcsndup.c @@ -16,7 +16,7 @@ libsimple_wcsndup(const wchar_t *s, size_t n) /* TODO test */ if (!ret) enprintf(status, "wcsdup:"); wmemcpy(ret, s, n); - ret[n] = '\0'; + ret[n] = 0; return ret; } -- cgit v1.2.3-70-g09d2