Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/usr.sbin/vnconfig PR bin/48829 Thomas Schmitt: vnconfig pret...
details: https://anonhg.NetBSD.org/src/rev/1c159b808f36
branches: trunk
changeset: 329430:1c159b808f36
user: dholland <dholland%NetBSD.org@localhost>
date: Fri May 23 20:50:16 2014 +0000
description:
PR bin/48829 Thomas Schmitt: vnconfig pretends to succeed on
nonexistent files
diffstat:
usr.sbin/vnconfig/vnconfig.c | 7 ++++---
1 files changed, 4 insertions(+), 3 deletions(-)
diffs (22 lines):
diff -r 47455be107e9 -r 1c159b808f36 usr.sbin/vnconfig/vnconfig.c
--- a/usr.sbin/vnconfig/vnconfig.c Fri May 23 19:59:17 2014 +0000
+++ b/usr.sbin/vnconfig/vnconfig.c Fri May 23 20:50:16 2014 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: vnconfig.c,v 1.41 2013/06/09 13:25:40 christos Exp $ */
+/* $NetBSD: vnconfig.c,v 1.42 2014/05/23 20:50:16 dholland Exp $ */
/*-
* Copyright (c) 1997 The NetBSD Foundation, Inc.
@@ -318,9 +318,10 @@
int ffd;
ffd = open(file, readonly ? O_RDONLY : O_RDWR);
- if (ffd < 0)
+ if (ffd < 0) {
warn("%s", file);
- else {
+ rv = -1;
+ } else {
(void) close(ffd);
rv = ioctl(fd, VNDIOCSET, &vndio);
Home |
Main Index |
Thread Index |
Old Index