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

Re: Misc. compile warnings



2014/09/30 06:01, Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx> wrote:
> Just upgraded Mavericks and am seeing some compile warnings

The same 'zero treated as a null pointer constant' warning from zselect.c.


diff --git a/Src/Modules/zselect.c b/Src/Modules/zselect.c
index c020746..30a3f51 100644
--- a/Src/Modules/zselect.c
+++ b/Src/Modules/zselect.c
@@ -251,7 +251,7 @@ bin_zselect(char *nam, char **args, UNUSED(Options ops), UNUSED(int func))
     outptr = outdata = (char **)zalloc((fdcount+1)*sizeof(char *));
     while (nonempty(fdlist))
 	*outptr++ = getlinknode(fdlist);
-    *outptr = '\0';
+    *outptr = NULL;
     /* and store in array parameter */
     if (outhash)
 	sethparam(outhash, outdata);





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