From 1189a9f9f521ab79f1f8fb94434c7f4cbac88ef0 Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Thu, 11 Jan 2018 00:39:12 +0100 Subject: log: minimize includes in log.h log.h really should only include the bare minimum of other headers, as it is really pulled into pretty much everything else and already in itself one of the most basic pieces of code we have. Let's hence drop inclusion of: 1. sd-id128.h because it's entirely unneeded in current log.h 2. errno.h, dito. 3. sys/signalfd.h which we can replace by a simple struct forward declaration 4. process-util.h which was needed for getpid_cached() which we now hide in a funciton log_emergency_level() instead, which nicely abstracts the details away. 5. sys/socket.h which was needed for struct iovec, but a simple struct forward declaration suffices for that too. Ultimately this actually makes our source tree larger (since users of the functionality above must now include it themselves, log.h won't do that for them), but I think it helps to untangle our web of includes a tiny bit. (Background: I'd like to isolate the generic bits of src/basic/ enough so that we can do a git submodule import into casync for it) --- src/test/test-extract-word.c | 1 + 1 file changed, 1 insertion(+) (limited to 'src/test/test-extract-word.c') diff --git a/src/test/test-extract-word.c b/src/test/test-extract-word.c index c8f735607..cff40a4fb 100644 --- a/src/test/test-extract-word.c +++ b/src/test/test-extract-word.c @@ -19,6 +19,7 @@ along with systemd; If not, see . ***/ +//#include #include #include -- cgit v1.2.3