summaryrefslogtreecommitdiff
path: root/usr.bin/patch/inp.c
diff options
context:
space:
mode:
authorKiyoshi Aman <kiyoshi.aman+adelie@gmail.com>2019-06-03 07:25:47 -0500
committerKiyoshi Aman <kiyoshi.aman+adelie@gmail.com>2019-06-03 07:25:47 -0500
commit7672573e52e652a5b800638bd8605c1eee7c54b6 (patch)
tree869733f20f2edc0d0f4e6c2636ed44a0f057714d /usr.bin/patch/inp.c
parent910491b6123a35ec4ab1530dcb91659bcc3d1cad (diff)
downloaduserland-7672573e52e652a5b800638bd8605c1eee7c54b6.tar.gz
userland-7672573e52e652a5b800638bd8605c1eee7c54b6.tar.bz2
userland-7672573e52e652a5b800638bd8605c1eee7c54b6.tar.xz
userland-7672573e52e652a5b800638bd8605c1eee7c54b6.zip
usr.bin/patch: make buildable
Diffstat (limited to 'usr.bin/patch/inp.c')
-rw-r--r--usr.bin/patch/inp.c13
1 files changed, 5 insertions, 8 deletions
diff --git a/usr.bin/patch/inp.c b/usr.bin/patch/inp.c
index b434a88..b1c0312 100644
--- a/usr.bin/patch/inp.c
+++ b/usr.bin/patch/inp.c
@@ -30,9 +30,6 @@
* behaviour
*/
-#include <sys/cdefs.h>
-__RCSID("$NetBSD: inp.c,v 1.26 2018/06/18 18:33:31 christos Exp $");
-
#include <sys/types.h>
#include <sys/file.h>
#include <sys/stat.h>
@@ -230,8 +227,8 @@ plan_a(const char *filename)
strerror(errno));
}
(void)dup2(devnull, STDOUT_FILENO);
- argp[0] = __UNCONST(RCSDIFF);
- argp[1] = __UNCONST(filename);
+ argp[0] = RCSDIFF;
+ argp[1] = filename;
execv(RCSDIFF, argp);
exit(127);
}
@@ -251,9 +248,9 @@ plan_a(const char *filename)
case -1:
fatal("can't fork: %s\n", strerror(errno));
case 0:
- argp[0] = __UNCONST(CHECKOUT);
- argp[1] = __UNCONST("-l");
- argp[2] = __UNCONST(filename);
+ argp[0] = CHECKOUT;
+ argp[1] = "-l";
+ argp[2] = filename;
execv(CHECKOUT, argp);
exit(127);
}