Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

PATCH: miscellaneous



- I was getting `char used as subscript' warnings in zftp.c -- I hope
  it is ok to use STOUC() there.
- Then there is some stuff for the compsys docs -- most importantly the 
  description for the -i and -s option to _long_options added by Andrej.
- And then I just found out that I have the DLLD-problem only when
  compiling with debugging. So J. Random User shouldn't be affected by
  that.

Bye
 Sven

diff -u os/Modules/zftp.c Src/Modules/zftp.c
--- os/Modules/zftp.c	Tue Jul 13 14:39:39 1999
+++ Src/Modules/zftp.c	Tue Jul 13 14:38:59 1999
@@ -2261,7 +2261,7 @@
 	fflush(stdout);
 	return 0;
     } else {
-	nt = toupper(*str);
+	nt = toupper(STOUC(*str));
 	/*
 	 * RFC959 specifies other types, but these are the only
 	 * ones we know what to do with.
@@ -2294,7 +2294,7 @@
 	fflush(stdout);
 	return 0;
     }
-    nt = str[0] = toupper(*str);
+    nt = str[0] = toupper(STOUC(*str));
     if (str[1] || (nt != 'S' && nt != 'B')) {
 	zwarnnam(name, "transfer mode %s not recognised", str, 0);
 	return 1;
@@ -2651,7 +2651,7 @@
     if ((prefs = getsparam("ZFTP_PREFS"))) {
 	zfprefs = 0;
 	for (ptr = prefs; *ptr; ptr++) {
-	    switch (toupper(*ptr)) {
+	    switch (toupper(STOUC(*ptr))) {
 	    case 'S':
 		/* sendport */
 		zfprefs |= ZFPF_SNDP;
diff -u od/Zsh/compsys.yo Doc/Zsh/compsys.yo
--- od/Zsh/compsys.yo	Tue Jul 13 10:58:43 1999
+++ Doc/Zsh/compsys.yo	Tue Jul 13 14:34:35 1999
@@ -31,7 +31,7 @@
 
 Usually, tt(compinstall) will insert code into tt(.zshrc), although if
 that is not writable it will save it in another file and tell you that
-file's locations.  Note that it is up to you to make sure that the lines
+file's location.  Note that it is up to you to make sure that the lines
 added to tt(.zshrc) are actually run; you may, for example, need to move
 them to an earlier place in the file if tt(.zshrc) usually returns early.
 So long as you keep them all together (including the comment lines at the
@@ -92,7 +92,7 @@
 (e.g. using tt(compdef)) and then want to dump the new one.  The name of
 the old dumped file will be remembered for this purpose.
 
-If the parameter tt(_compdir) is set, tt(compinit) uses it has a directory
+If the parameter tt(_compdir) is set, tt(compinit) uses it as a directory
 where completion functions can be found; this is only necessary if they are
 not already in the function search path.
 
@@ -489,7 +489,7 @@
 arithmetical expression. In this case, expansion of substitutions will
 be done if the expression evaluates to `tt(1)'. For example, with
 
-example(compconf expand_substitute='NUMERIC != 1')
+example(compconf expand_substitute='${NUMERIC:-1} != 1')
 
 substitution will be performed only if given an explicit numeric
 argument other than `tt(1)', as by typing `tt(ESC 2 TAB)'.
@@ -720,8 +720,8 @@
 )
 item(tt(_parameters))(
 This should be used to complete parameter names if you need some of the
-extra options of tt(compadd). It first tries to complete only non-local
-parameters. All arguments are passed unchanged to the tt(compadd) builtin.
+extra options of tt(compadd). All arguments are passed unchanged to
+the tt(compadd) builtin.
 )
 item(tt(_options))(
 This can be used to complete option names. The difference to the
@@ -780,9 +780,19 @@
 patterns can be overridden by patterns given as arguments, however.
 
 This function also accepts the `tt(-X)', `tt(-J)', and `tt(-V)'
-options which are passed unchanged to `tt(compadd)'. Finally, it
-accepts the option `tt(-t)'; if this is given, completion is only done
-on words starting with two hyphens.
+options which are passed unchanged to `tt(compadd)'. If the
+option `tt(-t)' is given, completion is only done on words starting
+with two hyphens. The option `tt(-i) var(patterns)' can be used to
+give patterns for options which should not be completed. The patterns
+can be given as the name of an array parameter or as a literal list in 
+parentheses. E.g. `tt(-i "(--(en|dis)able-FEATURE*)")' will ignore the
+options `tt(--enable-FEATURE)' and `tt(--diable-FEATURE)'. Finally,
+the option `tt(-s) var(pairs)' can be used to describe options
+aliases. Each var(pair) consists of a pattern and a
+replacement. E.g. some tt(configure)-scripts describe options only as
+`tt(--enable-foo)', but also accept `tt(disable-foo)'. To allow
+completion of the second form, one would use
+`tt(-s "(#--enable- --disable-)")'.
 )
 enditem()
 
--- Etc/MACHINES.old	Tue Jul 13 14:35:11 1999
+++ Etc/MACHINES	Tue Jul 13 14:35:46 1999
@@ -39,7 +39,8 @@
 	remove the bogus strip and use /bin/strip instead.
 
         On Digital UNIX 4.0, compilation with gcc and with --enable-dynamic
-        apparently needs configuring with explicit flags:
+        apparently needs configuring with explicit flags when compiling
+        with debugging enabled:
           DLLD=gcc LDFLAGS='-g -rpath <path-to-.so-files>' ./configure ...
 
 FreeBSD: FreeBSD 2.2.7 [3.1.4]

--
Sven Wischnowsky                         wischnow@xxxxxxxxxxxxxxxxxxxxxxx



Messages sorted by: Reverse Date, Date, Thread, Author