Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/lib/libc/resolv close on exec hostaliases
details: https://anonhg.NetBSD.org/src/rev/43ada00194a0
branches: trunk
changeset: 802465:43ada00194a0
user: christos <christos%NetBSD.org@localhost>
date: Tue Sep 16 01:30:00 2014 +0000
description:
close on exec hostaliases
diffstat:
lib/libc/resolv/res_query.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diffs (27 lines):
diff -r c478b31dfdef -r 43ada00194a0 lib/libc/resolv/res_query.c
--- a/lib/libc/resolv/res_query.c Tue Sep 16 01:29:48 2014 +0000
+++ b/lib/libc/resolv/res_query.c Tue Sep 16 01:30:00 2014 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: res_query.c,v 1.14 2012/03/13 21:13:44 christos Exp $ */
+/* $NetBSD: res_query.c,v 1.15 2014/09/16 01:30:00 christos Exp $ */
/*
* Portions Copyright (C) 2004, 2005, 2008 Internet Systems Consortium, Inc. ("ISC")
@@ -93,7 +93,7 @@
static const char sccsid[] = "@(#)res_query.c 8.1 (Berkeley) 6/4/93";
static const char rcsid[] = "Id: res_query.c,v 1.11 2008/11/14 02:36:51 marka Exp";
#else
-__RCSID("$NetBSD: res_query.c,v 1.14 2012/03/13 21:13:44 christos Exp $");
+__RCSID("$NetBSD: res_query.c,v 1.15 2014/09/16 01:30:00 christos Exp $");
#endif
#endif /* LIBC_SCCS and not lint */
@@ -451,7 +451,7 @@
if (issetugid())
return (NULL);
file = getenv("HOSTALIASES");
- if (file == NULL || (fp = fopen(file, "r")) == NULL)
+ if (file == NULL || (fp = fopen(file, "re")) == NULL)
return (NULL);
buf[sizeof(buf) - 1] = '\0';
while (fgets(buf, (int)sizeof(buf), fp)) {
Home |
Main Index |
Thread Index |
Old Index