From ade0cd8bb95ce20b520cb3b13600d04130f52976 Mon Sep 17 00:00:00 2001 From: Vincent Sanders Date: Sun, 17 Apr 2016 13:42:28 +0100 Subject: Reduce unecessary use of networking headers The utility configuration header dragged in a number of bsd sockets and related API as a side effect of setting up the configuration. By splitting the header and API setup into a separate header only the small number of places that need the functionality explitly include it. --- content/fetchers.h | 2 +- content/fetchers/curl.c | 3 ++- content/urldb.c | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) (limited to 'content') diff --git a/content/fetchers.h b/content/fetchers.h index c8f8300b8..92b11dc69 100644 --- a/content/fetchers.h +++ b/content/fetchers.h @@ -25,7 +25,7 @@ #ifndef _NETSURF_DESKTOP_FETCHERS_H_ #define _NETSURF_DESKTOP_FETCHERS_H_ -#include "utils/config.h" +#include "utils/inet.h" /* this is necessary for the fd_set definition */ #include struct nsurl; diff --git a/content/fetchers/curl.c b/content/fetchers/curl.c index 88c8bbe41..e789ce558 100644 --- a/content/fetchers/curl.c +++ b/content/fetchers/curl.c @@ -27,7 +27,8 @@ * The CURL handles are cached in the curl_handle_ring. */ -#include "utils/config.h" +/* must come first to ensure winsock2.h vs windows.h ordering issues */ +#include "utils/inet.h" #include #include diff --git a/content/urldb.c b/content/urldb.c index 1afa13131..0b59e1f4d 100644 --- a/content/urldb.c +++ b/content/urldb.c @@ -96,7 +96,7 @@ #include #include -#include "utils/config.h" +#include "utils/inet.h" #include "utils/nsoption.h" #include "utils/log.h" #include "utils/corestrings.h" -- cgit v1.2.3