+2014-03-21 Benno Schulenberg <bensberg@justemail.net>
+ * src/chars.c (is_punct_mbchar, mbstrchr) - Elide a variable,
+ thus making two ifs identical to six others.
+
2014-03-19 Benno Schulenberg <bensberg@justemail.net>
* doc/nanorc.sample.in - Document the changed whitespace defaults.
* src/global.c, doc/man/nanorc.5 - Allow softwrap to be rebound.
#ifdef ENABLE_UTF8
if (use_utf8) {
wchar_t wc;
- int c_mb_len = mbtowc(&wc, c, MB_CUR_MAX);
- if (c_mb_len < 0) {
+ if (mbtowc(&wc, c, MB_CUR_MAX) < 0) {
mbtowc_reset();
wc = bad_wchar;
}
char *s_mb = charalloc(MB_CUR_MAX);
const char *q = s;
wchar_t ws, wc;
- int c_mb_len = mbtowc(&wc, c, MB_CUR_MAX);
- if (c_mb_len < 0) {
+ if (mbtowc(&wc, c, MB_CUR_MAX) < 0) {
mbtowc_reset();
wc = (unsigned char)*c;
bad_c_mb = TRUE;