From: deraadt Date: Fri, 3 May 1996 15:01:44 +0000 (+0000) Subject: don't munge argv strings -- copy them first. avoids 'w' showing: X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=04a32ef2f7fbd3b2dcc148b40f610dba61d7cfe5;p=openbsd don't munge argv strings -- copy them first. avoids 'w' showing: deraadt p8 zeus.theos.com 8:26AM 3 dd if of bs --- diff --git a/bin/dd/args.c b/bin/dd/args.c index 7c817649926..97ed5bd60a4 100644 --- a/bin/dd/args.c +++ b/bin/dd/args.c @@ -105,6 +105,7 @@ jcl(argv) in.dbsz = out.dbsz = 512; while (oper = *++argv) { + oper = strdup(oper); if ((arg = strchr(oper, '=')) == NULL) errx(1, "unknown operand %s", oper); *arg++ = '\0';