about summary refs log tree commit diff
diff options
context:
space:
mode:
authorPeter Stephenson <pws@zsh.org>2014-09-30 09:58:19 +0100
committerPeter Stephenson <pws@zsh.org>2014-09-30 09:58:19 +0100
commit15222bcdcb3fddd897117ac08ed18d206fa383d1 (patch)
tree20d885821ef008855ea0db22bffb9351e345c8d2
parent32473f59a38631c4bb2403d835b9e007c8a0ddc7 (diff)
downloadzsh-15222bcdcb3fddd897117ac08ed18d206fa383d1.tar.gz
zsh-15222bcdcb3fddd897117ac08ed18d206fa383d1.tar.xz
zsh-15222bcdcb3fddd897117ac08ed18d206fa383d1.zip
Fix some compiler warnings in Zle
-rw-r--r--ChangeLog5
-rw-r--r--Src/Zle/compctl.c2
-rw-r--r--Src/Zle/zle_refresh.c3
3 files changed, 7 insertions, 3 deletions
diff --git a/ChangeLog b/ChangeLog
index 53850eb0a..d3b01a394 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2014-09-30  Peter Stephenson  <p.stephenson@samsung.com>
+
+	* 33293: Src/Zle/compctl.c, Src/Zle/zle_refresh.c: fix warnings
+	from swish new compilers with a contemporary outlook.
+
 2014-09-29  Peter Stephenson  <p.w.stephenson@ntlworld.com>
 
 	* 33286: Src/exec.c, Test/A04redirect.ztst: handle redirections
diff --git a/Src/Zle/compctl.c b/Src/Zle/compctl.c
index 52b9e9c82..0b7a32445 100644
--- a/Src/Zle/compctl.c
+++ b/Src/Zle/compctl.c
@@ -3416,7 +3416,7 @@ makecomplistflags(Compctl cc, char *s, int incmd, int compadd)
 			    *npp++ = tp;
 			    pp++;
 			}
-			*npp = '\0';
+			*npp = NULL;
 		    }
 		}
 		if (!dirs) {
diff --git a/Src/Zle/zle_refresh.c b/Src/Zle/zle_refresh.c
index 80be27f03..684ac13a2 100644
--- a/Src/Zle/zle_refresh.c
+++ b/Src/Zle/zle_refresh.c
@@ -258,7 +258,6 @@ static const REFRESH_ELEMENT zr_cr = { ZWC('\r'), 0 };
 static const REFRESH_ELEMENT zr_dt = { ZWC('.'), 0 };
 static const REFRESH_ELEMENT zr_nl = { ZWC('\n'), 0 };
 static const REFRESH_ELEMENT zr_sp = { ZWC(' '), 0 };
-static const REFRESH_ELEMENT zr_ht = { ZWC('\t'), 0 };
 static const REFRESH_ELEMENT zr_zr = { ZWC('\0'), 0 };
 
 /*
@@ -429,7 +428,7 @@ get_region_highlight(UNUSED(Param pm))
 		digbuf1, digbuf2);
 	(void)output_highlight(rhp->atr, *arrp + strlen(*arrp));
     }
-    *arrp = '\0';
+    *arrp = NULL;
     return retarr;
 }