From 71d5bf4d08b3ce328fe403f464f4ec95f2d8ca29 Mon Sep 17 00:00:00 2001 From: rsc Date: Thu, 30 Aug 2007 18:19:52 +0000 Subject: [PATCH] oops - broke arg counting --- exec.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/exec.c b/exec.c index 192b0cb..e5d6fff 100644 --- a/exec.c +++ b/exec.c @@ -42,7 +42,7 @@ exec(char *path, char **argv) // Arguments. arglen = 0; for(argc=0; argv[argc]; argc++) - arglen += strlen(argv[i]) + 1; + arglen += strlen(argv[argc]) + 1; arglen = (arglen+3) & ~3; sz += arglen + 4*(argc+1);