diff options
-rw-r--r-- | Src/Zle/complist.c | 2 | ||||
-rw-r--r-- | Src/Zle/zle_utils.c | 2 | ||||
-rw-r--r-- | Src/prompt.c | 13 | ||||
-rw-r--r-- | Src/utils.c | 9 |
4 files changed, 13 insertions, 13 deletions
diff --git a/Src/Zle/complist.c b/Src/Zle/complist.c index 9e633e64f..e380f5762 100644 --- a/Src/Zle/complist.c +++ b/Src/Zle/complist.c @@ -598,7 +598,7 @@ clnicezputs(Listcols colors, char *s, int ml) case MB_INVALID: /* This handles byte values that aren't valid wide-character * sequences. */ - sptr = nicechar(STOUC(*uptr)); + sptr = nicechar(*uptr); /* everything here is ASCII... */ width = strlen(sptr); wptr = sptr + width; diff --git a/Src/Zle/zle_utils.c b/Src/Zle/zle_utils.c index 517661777..2c92c955e 100644 --- a/Src/Zle/zle_utils.c +++ b/Src/Zle/zle_utils.c @@ -814,7 +814,7 @@ showmsg(char const *msg) * prettified. */ memset(&mbs, 0, sizeof mbs); - n = nicechar(STOUC(*p)); + n = nicechar(*p); cnt = 1; width = strlen(n); break; diff --git a/Src/prompt.c b/Src/prompt.c index 8b658883f..c09626e30 100644 --- a/Src/prompt.c +++ b/Src/prompt.c @@ -703,7 +703,7 @@ putpromptchar(int doprint, int endchar) static void pputc(char c) { - if(imeta(STOUC(c))) { + if (imeta(c)) { *bp++ = Meta; c ^= 32; } @@ -763,7 +763,7 @@ stradd(char *d) /* FALL THROUGH */ case MB_INVALID: /* Bad character. Take the next byte on its own. */ - pc = nicechar(STOUC(*ups)); + pc = nicechar(*ups); cnt = 1; memset(&mbs, 0, sizeof mbs); break; @@ -790,11 +790,12 @@ stradd(char *d) #else char *ps, *pc; addbufspc(niceztrlen(d)); - /* This loop puts the nice representation of the string into the prompt * - * buffer. */ - for(ps=d; *ps; ps++) - for(pc=nicechar(*ps == Meta ? STOUC(*++ps)^32 : STOUC(*ps)); *pc; pc++) + /* This loop puts the nice representation of the string into the + * prompt buffer. */ + for (ps = d; *ps; ps++) { + for (pc = nicechar(*ps == Meta ? *++ps^32 : *ps); *pc; pc++) *bp++ = *pc; + } #endif } diff --git a/Src/utils.c b/Src/utils.c index bb993e74d..5a1c5ab30 100644 --- a/Src/utils.c +++ b/Src/utils.c @@ -400,7 +400,7 @@ void nicefputs(char *s, FILE *f) { for (; *s; s++) - zputs(nicechar(STOUC(*s)), f); + zputs(nicechar(*s), f); } #endif @@ -1667,7 +1667,7 @@ read_poll(int fd, int *readchar, int polltty, zlong microseconds) * Praise Bill, this works under Cygwin (nothing else seems to). */ if ((polltty || setblock_fd(0, fd, &mode)) && read(fd, &c, 1) > 0) { - *readchar = STOUC(c); + *readchar = c; ret = 1; } if (mode != -1) @@ -1963,7 +1963,6 @@ spckword(char **s, int hist, int cmd, int ask) * NUL and return 1 if that doesn't fit. */ -/**/ static int ztrftimebuf(int *bufsizeptr, int decr) { @@ -3420,7 +3419,7 @@ niceztrlen(char const *s) } if (c == Meta) c = *s++ ^ 32; - l += strlen(nicechar(STOUC(c))); + l += strlen(nicechar(c)); } return l; } @@ -3479,7 +3478,7 @@ mb_niceformat(const char *s, FILE *stream, char **outstrp, int heap) /* FALL THROUGH */ case MB_INVALID: /* The byte didn't convert, so output it as a \M-... sequence. */ - fmt = nicechar(STOUC(*ptr)); + fmt = nicechar(*ptr); newl = strlen(fmt); cnt = 1; /* Get mbs out of its undefined state. */ |