about summary refs log tree commit diff
path: root/Src/parse.c
diff options
context:
space:
mode:
authorPeter Stephenson <pws@users.sourceforge.net>2010-12-20 10:28:43 +0000
committerPeter Stephenson <pws@users.sourceforge.net>2010-12-20 10:28:43 +0000
commita7bc22ca009cfd2d3e4e977d19599f6a3fb5096e (patch)
treee4f5fe6ebd168d6a4519d5d0591c02ed8de38775 /Src/parse.c
parentc8d07027c89d36a5a3981196a19d48a9286127a8 (diff)
downloadzsh-a7bc22ca009cfd2d3e4e977d19599f6a3fb5096e.tar.gz
zsh-a7bc22ca009cfd2d3e4e977d19599f6a3fb5096e.tar.xz
zsh-a7bc22ca009cfd2d3e4e977d19599f6a3fb5096e.zip
Paul 28538 / me 28540 / couple of unposted casts:
use char * for pointer arithmetic rather than void *
Diffstat (limited to 'Src/parse.c')
-rw-r--r--Src/parse.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/Src/parse.c b/Src/parse.c
index 2953f00aa..e59a882ca 100644
--- a/Src/parse.c
+++ b/Src/parse.c
@@ -2765,7 +2765,7 @@ write_dump(int dfd, LinkList progs, int map, int hlen, int tlen)
 	fdsetflags(pre, ((map ? FDF_MAP : 0) | other));
 	fdsetother(pre, tlen);
 	strcpy(fdversion(pre), ZSH_VERSION);
-	write_loop(dfd, pre, FD_PRELEN * sizeof(wordcode));
+	write_loop(dfd, (char *)pre, FD_PRELEN * sizeof(wordcode));
 
 	for (node = firstnode(progs); node; incnode(node)) {
 	    wcf = (WCFunc) getdata(node);
@@ -2786,11 +2786,11 @@ write_dump(int dfd, LinkList progs, int map, int hlen, int tlen)
 	    head.flags = fdhbldflags(wcf->flags, (tail - n));
 	    if (other)
 		fdswap((Wordcode) &head, sizeof(head) / sizeof(wordcode));
-	    write_loop(dfd, &head, sizeof(head));
+	    write_loop(dfd, (char *)&head, sizeof(head));
 	    tmp = strlen(n) + 1;
 	    write_loop(dfd, n, tmp);
 	    if ((tmp &= (sizeof(wordcode) - 1)))
-		write_loop(dfd, &head, sizeof(wordcode) - tmp);
+		write_loop(dfd, (char *)&head, sizeof(wordcode) - tmp);
 	}
 	for (node = firstnode(progs); node; incnode(node)) {
 	    prog = ((WCFunc) getdata(node))->prog;
@@ -2798,7 +2798,7 @@ write_dump(int dfd, LinkList progs, int map, int hlen, int tlen)
 		   sizeof(wordcode) - 1) / sizeof(wordcode);
 	    if (other)
 		fdswap(prog->prog, (((Wordcode) prog->strs) - prog->prog));
-	    write_loop(dfd, prog->prog, tmp * sizeof(wordcode));
+	    write_loop(dfd, (char *)prog->prog, tmp * sizeof(wordcode));
 	}
 	if (other)
 	    break;