* PATCH: pws-24: unsigned character problems
@ 1999-06-26 16:02 Peter Stephenson
0 siblings, 0 replies; only message in thread
From: Peter Stephenson @ 1999-06-26 16:02 UTC (permalink / raw)
To: Zsh hackers list
(This is also in another mail queue so could in theory arrive twice.)
The first of these hunks fixes the problem I was having on SunOS 4.1.3_U1
with gcc 2.7.0: itok(c) wasn't working where c was a char, even though itok
is defined with a STOUC() in it. Changing c to be an int worked.
Coincidentally, I'd already fixed an error message about unsigned chars
from the test I added for spaces in option strings, which is the second
hunk.
--- Src/exec.c.uc Fri Jun 25 14:30:20 1999
+++ Src/exec.c Sat Jun 26 17:17:22 1999
@@ -1131,7 +1131,8 @@
untokenize(char *s)
{
if (*s) {
- char *p = s, c;
+ char *p = s;
+ int c;
while ((c = *s++))
if (itok(c)) {
--- Src/init.c.uc Fri Jun 25 14:29:52 1999
+++ Src/init.c Sat Jun 26 15:58:22 1999
@@ -235,10 +235,10 @@
else
dosetopt(optno, action, 1);
break;
- } else if (isspace(**argv)) {
+ } else if (isspace(STOUC(**argv))) {
/* zsh's typtab not yet set, have to use ctype */
while (*++*argv)
- if (!isspace(**argv)) {
+ if (!isspace(STOUC(**argv))) {
zerr("bad option string: `%s'", args, 0);
exit(1);
}
--
Peter Stephenson <pws@ibmth.df.unipi.it> Tel: +39 050 844536
WWW: http://www.ifh.de/~pws/
Dipartimento di Fisica, Via Buonarroti 2, 56127 Pisa, Italy
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~1999-06-26 21:34 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1999-06-26 16:02 PATCH: pws-24: unsigned character problems Peter Stephenson
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).