From 7098ec233cc50ff38c993e4728b12c8a615e18eb Mon Sep 17 00:00:00 2001 From: David Lawrence Ramsey Date: Sat, 18 Jun 2005 05:15:08 +0000 Subject: [PATCH] n is ignored in the mbstowcs() call, so it can be 0 instead of (size_t)-1 git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@2721 35c25a1d-7b9e-4130-9fde-d3aeb78583b8 --- src/chars.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/chars.c b/src/chars.c index 0f76079e..c9b0356c 100644 --- a/src/chars.c +++ b/src/chars.c @@ -858,7 +858,7 @@ bool is_valid_mbstring(const char *s) return #ifdef NANO_WIDE ISSET(USE_UTF8) ? - (mbstowcs(NULL, s, (size_t)-1) != (size_t)-1) : + (mbstowcs(NULL, s, 0) != (size_t)-1) : #endif TRUE; -- 2.39.5