zsh-workers
 help / color / mirror / code / Atom feed
* PATCH: minor character tweaks
@ 2006-09-21 16:08 Peter Stephenson
  0 siblings, 0 replies; only message in thread
From: Peter Stephenson @ 2006-09-21 16:08 UTC (permalink / raw)
  To: Zsh hackers list

A few things that turned from a compilation under Cygwin, which produced
some different warnings.

Index: Src/prompt.c
===================================================================
RCS file: /cvsroot/zsh/zsh/Src/prompt.c,v
retrieving revision 1.41
diff -u -r1.41 prompt.c
--- Src/prompt.c	15 Sep 2006 13:17:27 -0000	1.41
+++ Src/prompt.c	21 Sep 2006 16:05:38 -0000
@@ -1130,7 +1130,8 @@
 			     * Normal text: build up a multibyte character.
 			     */
 			    char inchar;
-			    wchar_t cc, wcw;
+			    wchar_t cc;
+			    int wcw;
 
 			    /*
 			     * careful: string is still metafied (we
Index: Src/utils.c
===================================================================
RCS file: /cvsroot/zsh/zsh/Src/utils.c,v
retrieving revision 1.138
diff -u -r1.138 utils.c
--- Src/utils.c	15 Sep 2006 13:17:27 -0000	1.138
+++ Src/utils.c	21 Sep 2006 16:05:40 -0000
@@ -2019,9 +2019,10 @@
 noquery(int purge)
 {
     int val = 0;
-    char c;
 
 #ifdef FIONREAD
+    char c;
+
     ioctl(SHTTY, FIONREAD, (char *)&val);
     if (purge) {
 	for (; val; val--)
Index: Src/Zle/complist.c
===================================================================
RCS file: /cvsroot/zsh/zsh/Src/Zle/complist.c,v
retrieving revision 1.95
diff -u -r1.95 complist.c
--- Src/Zle/complist.c	20 Aug 2006 22:28:17 -0000	1.95
+++ Src/Zle/complist.c	21 Sep 2006 16:05:41 -0000
@@ -982,7 +982,7 @@
 	len = MB_METACHARLENCONV(p, &cchar);
 #ifdef MULTIBYTE_SUPPORT
 	if (cchar == WEOF) {
-	    cchar = (wchar_t)p;
+	    cchar = (wchar_t)(*p == Meta ? p[1] ^ 32 : *p);
 	    width = 1;
 	}
 	else
@@ -995,7 +995,7 @@
 		len = MB_METACHARLENCONV(p, &cchar);
 #ifdef MULTIBYTE_SUPPORT
 		if (cchar == WEOF)
-		    cchar = (wchar_t)p;
+		    cchar = (wchar_t)(*p == Meta ? p[1] ^ 32 : *p);
 #endif
 		p += len;
 

-- 
Peter Stephenson <pws@csr.com>                  Software Engineer
CSR PLC, Churchill House, Cambridge Business Park, Cowley Road
Cambridge, CB4 0WZ, UK                          Tel: +44 (0)1223 692070


To access the latest news from CSR copy this link into a web browser:  http://www.csr.com/email_sig.php


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2006-09-21 16:11 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-09-21 16:08 PATCH: minor character tweaks 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).