summaryrefslogtreecommitdiff
path: root/usr.bin/vi
diff options
context:
space:
mode:
authorJonathan Gray <jsg@cvs.openbsd.org>2015-04-21 01:41:43 +0000
committerJonathan Gray <jsg@cvs.openbsd.org>2015-04-21 01:41:43 +0000
commit555187e79ea5510b7e5e766c6d9a54552750d4a5 (patch)
tree8df018e05a10b3fe59edce396c2380453d2e2c83 /usr.bin/vi
parent8dd3078353214b131e72a22512f1d5b66e9516c1 (diff)
init both fds passed to pipe as -1 instead of initing one twice
ok deraadt@ guenther@ miod@ millert@
Diffstat (limited to 'usr.bin/vi')
-rw-r--r--usr.bin/vi/ex/ex_cscope.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.bin/vi/ex/ex_cscope.c b/usr.bin/vi/ex/ex_cscope.c
index 0bca4cbb2cd..4e00e6e76a4 100644
--- a/usr.bin/vi/ex/ex_cscope.c
+++ b/usr.bin/vi/ex/ex_cscope.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ex_cscope.c,v 1.24 2015/01/16 06:40:14 deraadt Exp $ */
+/* $OpenBSD: ex_cscope.c,v 1.25 2015/04/21 01:41:42 jsg Exp $ */
/*-
* Copyright (c) 1994, 1996
@@ -359,7 +359,7 @@ run_cscope(SCR *sp, CSC *csc, char *dbname)
* Cscope reads from to_cs[0] and writes to from_cs[1]; vi reads from
* from_cs[0] and writes to to_cs[1].
*/
- to_cs[0] = to_cs[1] = from_cs[0] = from_cs[0] = -1;
+ to_cs[0] = to_cs[1] = from_cs[0] = from_cs[1] = -1;
if (pipe(to_cs) < 0 || pipe(from_cs) < 0) {
msgq(sp, M_SYSERR, "pipe");
goto err;