Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/usr.bin/getaddrinfo Add missing include files. Don't rely o...
details: https://anonhg.NetBSD.org/src/rev/289f3a7a868f
branches: trunk
changeset: 327860:289f3a7a868f
user: ginsbach <ginsbach%NetBSD.org@localhost>
date: Wed Mar 19 01:24:32 2014 +0000
description:
Add missing include files. Don't rely on them bein pulled in as a
side effect of other includes. Fixes build errors when getaddrinfo(1)
is added to the usr.bin tree.
- need <sys/socket.h> for address family (AF_*) and socket type (SOCK_*)
- need <stdio.h> for printf() and friends
diffstat:
usr.bin/getaddrinfo/getaddrinfo.c | 8 ++++++--
1 files changed, 6 insertions(+), 2 deletions(-)
diffs (29 lines):
diff -r 80e9a3f406ca -r 289f3a7a868f usr.bin/getaddrinfo/getaddrinfo.c
--- a/usr.bin/getaddrinfo/getaddrinfo.c Tue Mar 18 23:43:40 2014 +0000
+++ b/usr.bin/getaddrinfo/getaddrinfo.c Wed Mar 19 01:24:32 2014 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: getaddrinfo.c,v 1.2 2014/03/14 13:17:18 ginsbach Exp $ */
+/* $NetBSD: getaddrinfo.c,v 1.3 2014/03/19 01:24:32 ginsbach Exp $ */
/*-
* Copyright (c) 2013 The NetBSD Foundation, Inc.
@@ -30,7 +30,10 @@
*/
#include <sys/cdefs.h>
-__RCSID("$NetBSD: getaddrinfo.c,v 1.2 2014/03/14 13:17:18 ginsbach Exp $");
+__RCSID("$NetBSD: getaddrinfo.c,v 1.3 2014/03/19 01:24:32 ginsbach Exp $");
+
+#include <sys/types.h>
+#include <sys/socket.h>
#include <assert.h>
#include <err.h>
@@ -40,6 +43,7 @@
#include <stdbool.h>
#include <stdint.h>
#include <stdlib.h>
+#include <stdio.h>
#include <string.h>
#include <unistd.h>
#include <util.h>
Home |
Main Index |
Thread Index |
Old Index