Module Name: src Committed By: martin Date: Thu Aug 1 12:28:53 UTC 2019
Modified Files: src/distrib/utils/libhack: multibyte.c Log Message: Avoid using an unitialized variable To generate a diff of this commit: cvs rdiff -u -r1.8 -r1.9 src/distrib/utils/libhack/multibyte.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/distrib/utils/libhack/multibyte.c diff -u src/distrib/utils/libhack/multibyte.c:1.8 src/distrib/utils/libhack/multibyte.c:1.9 --- src/distrib/utils/libhack/multibyte.c:1.8 Sun Jul 28 10:21:18 2019 +++ src/distrib/utils/libhack/multibyte.c Thu Aug 1 12:28:53 2019 @@ -1,4 +1,4 @@ -/* $NetBSD: multibyte.c,v 1.8 2019/07/28 10:21:18 martin Exp $ */ +/* $NetBSD: multibyte.c,v 1.9 2019/08/01 12:28:53 martin Exp $ */ /* * Ignore all multibyte sequences, removes all the citrus code. @@ -246,10 +246,8 @@ wcslen(const wchar_t *s) if (s == NULL) return 0; - while (*s) { + for (l = 0; *s; l++) s++; - l++; - } return l; }