diff options
| author | Mikael Magnusson <mikachu@gmail.com> | 2026-06-08 20:57:06 +0200 |
|---|---|---|
| committer | Mikael Magnusson <mikachu@gmail.com> | 2026-06-14 01:57:17 +0200 |
| commit | f9d159b88ab8ea843a3231cadd0c0b57da74cc8b (patch) | |
| tree | 5d528b8340aa2be7b5ecd845bdc55cc3067fa5e0 /Src/Modules | |
| parent | 54713: fix multibyte error reporting in zparseopts (diff) | |
| download | zsh-f9d159b88ab8ea843a3231cadd0c0b57da74cc8b.tar zsh-f9d159b88ab8ea843a3231cadd0c0b57da74cc8b.tar.gz zsh-f9d159b88ab8ea843a3231cadd0c0b57da74cc8b.tar.bz2 zsh-f9d159b88ab8ea843a3231cadd0c0b57da74cc8b.tar.lz zsh-f9d159b88ab8ea843a3231cadd0c0b57da74cc8b.tar.xz zsh-f9d159b88ab8ea843a3231cadd0c0b57da74cc8b.tar.zst zsh-f9d159b88ab8ea843a3231cadd0c0b57da74cc8b.zip | |
54714: add MB_NICECHAR and use it
Diffstat (limited to 'Src/Modules')
| -rw-r--r-- | Src/Modules/zutil.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/Src/Modules/zutil.c b/Src/Modules/zutil.c index 0bc340dc9..6f53f5c53 100644 --- a/Src/Modules/zutil.c +++ b/Src/Modules/zutil.c @@ -1991,12 +1991,8 @@ bin_zparseopts(char *nam, char **args, Options ops, UNUSED(int func)) if (*o != '-' || o > *pp + 1) { convchar_t wc = unmeta_one(o, NULL); fprintf(stderr, "%s: bad option: -", progname); -#ifdef MULTIBYTE_SUPPORT - mb_charinit(); - zputs(wcs_nicechar(wc, NULL, NULL), stderr); -#else - zputs(nicechar(wc), stderr); -#endif + MB_CHARINIT(); + zputs(MB_NICECHAR(wc), stderr); fputc('\n', stderr); } else { fprintf(stderr, "%s: bad option: -%s\n", progname, o); |
