diff --git a/run.c b/run.c index a1fb7f0..dd21366 100644 --- a/run.c +++ b/run.c @@ -1978,7 +1978,6 @@ static char *nawk_convert(const char *s, int (*fun_c)(int), size_t n = 0; wchar_t wc; const size_t sz = awk_mb_cur_max; - int unused; if (sz == 1) { buf = tostring(s); @@ -1992,14 +1991,7 @@ static char *nawk_convert(const char *s, int (*fun_c)(int), buf = tostringN(s, strlen(s) * sz + 1); (void) mbtowc(NULL, NULL, 0); /* reset internal state */ - /* - * Reset internal state here too. - * Assign result to avoid a compiler warning. (Casting to void - * doesn't work.) - * Increment said variable to avoid a different warning. - */ - unused = wctomb(NULL, L'\0'); - unused++; + (void) wctomb(NULL, L'\0'); /* reset internal state */ ps = s; pbuf = buf;