Introduction
Introduction Statistics Contact Development Disclaimer Help
Fix improper termination of samterm argv. - sam - An updated version of the sam…
git clone git://vernunftzentrum.de/sam.git
Log
Files
Refs
LICENSE
---
commit 95e5651ac21d62d392536e2cfe1784c69ac30766
parent faf04a03721d852086ec2c89ff28c0a94d583f01
Author: Rob King <[email protected]>
Date: Wed, 18 May 2016 16:13:43 -0500
Fix improper termination of samterm argv.
Diffstat:
sam/sam.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
---
diff --git a/sam/sam.c b/sam/sam.c
@@ -43,7 +43,8 @@ int main(int argc, char *argv[])
int targc = 1;
ap = &arg[argc];
- arg[argc] = NULL;
+ arg[0] = "samterm";
+
while ((o = getopt(argc, argv, "edRr:t:s:")) != -1){
switch (o){
case 'e':
@@ -78,6 +79,7 @@ int main(int argc, char *argv[])
}
argv += optind;
argc -= optind;
+ arg[targc] = NULL;
Strinit(&cmdstr);
Strinit0(&lastpat);
You are viewing proxied material from vernunftzentrum.de. The copyright of proxied material belongs to its original authors. Any comments or complaints in relation to proxied material should be directed to the original authors of the content concerned. Please see the disclaimer for more details.