summaryrefslogtreecommitdiff
path: root/src/journal
diff options
context:
space:
mode:
authorThomas Hindoe Paaboel Andersen <phomes@gmail.com>2015-02-14 09:44:31 +0100
committerThomas Hindoe Paaboel Andersen <phomes@gmail.com>2015-02-23 23:53:42 +0100
commit2eec67acbb00593e414549a7e5b35eb7dd776b1b (patch)
treec692391dddfa88d938a29ea238a9e1a95da879fc /src/journal
parent4aab5d0cbd979b2cccb88534f118bceaa86466d8 (diff)
remove unused includes
This patch removes includes that are not used. The removals were found with include-what-you-use which checks if any of the symbols from a header is in use.
Diffstat (limited to 'src/journal')
-rw-r--r--src/journal/cat.c1
-rw-r--r--src/journal/catalog.c1
-rw-r--r--src/journal/compress.c1
-rw-r--r--src/journal/compress.h2
-rw-r--r--src/journal/coredump.c2
-rw-r--r--src/journal/coredumpctl.c1
-rw-r--r--src/journal/fsprg.c1
-rw-r--r--src/journal/journal-authenticate.h1
-rw-r--r--src/journal/journal-file.c1
-rw-r--r--src/journal/journal-qrcode.h2
-rw-r--r--src/journal/journal-vacuum.c3
-rw-r--r--src/journal/journal-vacuum.h1
-rw-r--r--src/journal/journal-verify.c1
-rw-r--r--src/journal/journalctl.c3
-rw-r--r--src/journal/journald-console.c1
-rw-r--r--src/journal/journald-rate-limit.h1
-rw-r--r--src/journal/journald-server.c4
-rw-r--r--src/journal/journald-server.h4
-rw-r--r--src/journal/journald-stream.c1
-rw-r--r--src/journal/journald.c4
-rw-r--r--src/journal/mmap-cache.c1
-rw-r--r--src/journal/mmap-cache.h1
-rw-r--r--src/journal/test-catalog.c1
-rw-r--r--src/journal/test-journal-enum.c1
-rw-r--r--src/journal/test-journal-interleaving.c1
-rw-r--r--src/journal/test-journal-verify.c1
-rw-r--r--src/journal/test-journal.c1
-rw-r--r--src/journal/test-mmap-cache.c1
28 files changed, 0 insertions, 44 deletions
diff --git a/src/journal/cat.c b/src/journal/cat.c
index 79706b692d..2e236f0004 100644
--- a/src/journal/cat.c
+++ b/src/journal/cat.c
@@ -21,7 +21,6 @@
#include <stdio.h>
#include <getopt.h>
-#include <assert.h>
#include <unistd.h>
#include <stdlib.h>
#include <errno.h>
diff --git a/src/journal/catalog.c b/src/journal/catalog.c
index f170232841..e505a05305 100644
--- a/src/journal/catalog.c
+++ b/src/journal/catalog.c
@@ -34,7 +34,6 @@
#include "hashmap.h"
#include "strv.h"
#include "strbuf.h"
-#include "strxcpyx.h"
#include "conf-files.h"
#include "mkdir.h"
#include "catalog.h"
diff --git a/src/journal/compress.c b/src/journal/compress.c
index 6923753f89..4232206f44 100644
--- a/src/journal/compress.c
+++ b/src/journal/compress.c
@@ -19,7 +19,6 @@
along with systemd; If not, see <http://www.gnu.org/licenses/>.
***/
-#include <assert.h>
#include <stdlib.h>
#include <string.h>
#include <unistd.h>
diff --git a/src/journal/compress.h b/src/journal/compress.h
index 136dda6d39..6294f16faa 100644
--- a/src/journal/compress.h
+++ b/src/journal/compress.h
@@ -21,8 +21,6 @@
along with systemd; If not, see <http://www.gnu.org/licenses/>.
***/
-#include <inttypes.h>
-#include <stdbool.h>
#include <unistd.h>
#include "journal-def.h"
diff --git a/src/journal/coredump.c b/src/journal/coredump.c
index f7ba0191e1..6357d3e277 100644
--- a/src/journal/coredump.c
+++ b/src/journal/coredump.c
@@ -23,7 +23,6 @@
#include <unistd.h>
#include <stdio.h>
#include <sys/prctl.h>
-#include <sys/types.h>
#include <sys/xattr.h>
#ifdef HAVE_ELFUTILS
@@ -44,7 +43,6 @@
#include "conf-parser.h"
#include "copy.h"
#include "stacktrace.h"
-#include "path-util.h"
#include "compress.h"
#include "acl-util.h"
#include "capability.h"
diff --git a/src/journal/coredumpctl.c b/src/journal/coredumpctl.c
index afb39ad035..62983a73e4 100644
--- a/src/journal/coredumpctl.c
+++ b/src/journal/coredumpctl.c
@@ -35,7 +35,6 @@
#include "pager.h"
#include "macro.h"
#include "journal-internal.h"
-#include "copy.h"
#include "compress.h"
#include "sigbus.h"
diff --git a/src/journal/fsprg.c b/src/journal/fsprg.c
index 5c8d6d6feb..a9f564c249 100644
--- a/src/journal/fsprg.c
+++ b/src/journal/fsprg.c
@@ -30,7 +30,6 @@
#include <gcrypt.h>
#include <string.h>
-#include <assert.h>
#include "fsprg.h"
diff --git a/src/journal/journal-authenticate.h b/src/journal/journal-authenticate.h
index 565fe8432c..118bb1367b 100644
--- a/src/journal/journal-authenticate.h
+++ b/src/journal/journal-authenticate.h
@@ -22,7 +22,6 @@
***/
#include <stdbool.h>
-#include <inttypes.h>
#include "journal-file.h"
diff --git a/src/journal/journal-file.c b/src/journal/journal-file.c
index 2845e05ce0..9b4967fb32 100644
--- a/src/journal/journal-file.c
+++ b/src/journal/journal-file.c
@@ -34,7 +34,6 @@
#include "journal-authenticate.h"
#include "lookup3.h"
#include "compress.h"
-#include "fsprg.h"
#define DEFAULT_DATA_HASH_TABLE_SIZE (2047ULL*sizeof(HashItem))
#define DEFAULT_FIELD_HASH_TABLE_SIZE (333ULL*sizeof(HashItem))
diff --git a/src/journal/journal-qrcode.h b/src/journal/journal-qrcode.h
index c527e65553..3ff6a3ad4a 100644
--- a/src/journal/journal-qrcode.h
+++ b/src/journal/journal-qrcode.h
@@ -21,8 +21,6 @@
along with systemd; If not, see <http://www.gnu.org/licenses/>.
***/
-#include <inttypes.h>
-#include <sys/types.h>
#include <stdio.h>
#include "systemd/sd-id128.h"
diff --git a/src/journal/journal-vacuum.c b/src/journal/journal-vacuum.c
index 832c327b31..a367dc1bb9 100644
--- a/src/journal/journal-vacuum.c
+++ b/src/journal/journal-vacuum.c
@@ -19,12 +19,9 @@
along with systemd; If not, see <http://www.gnu.org/licenses/>.
***/
-#include <sys/types.h>
#include <fcntl.h>
#include <sys/stat.h>
-#include <sys/statvfs.h>
#include <unistd.h>
-#include <sys/xattr.h>
#include "journal-def.h"
#include "journal-file.h"
diff --git a/src/journal/journal-vacuum.h b/src/journal/journal-vacuum.h
index a7fb6f0f0d..c45cc31d0e 100644
--- a/src/journal/journal-vacuum.h
+++ b/src/journal/journal-vacuum.h
@@ -21,6 +21,5 @@
along with systemd; If not, see <http://www.gnu.org/licenses/>.
***/
-#include <inttypes.h>
int journal_directory_vacuum(const char *directory, uint64_t max_use, usec_t max_retention_usec, usec_t *oldest_usec, bool vacuum);
diff --git a/src/journal/journal-verify.c b/src/journal/journal-verify.c
index b03335ef31..35c270cb34 100644
--- a/src/journal/journal-verify.c
+++ b/src/journal/journal-verify.c
@@ -32,7 +32,6 @@
#include "journal-verify.h"
#include "lookup3.h"
#include "compress.h"
-#include "fsprg.h"
static void draw_progress(uint64_t p, usec_t *last_usec) {
unsigned n, i, j, k;
diff --git a/src/journal/journalctl.c b/src/journal/journalctl.c
index 55c7786331..56435ff7b4 100644
--- a/src/journal/journalctl.c
+++ b/src/journal/journalctl.c
@@ -28,12 +28,10 @@
#include <stdio.h>
#include <unistd.h>
#include <stdlib.h>
-#include <time.h>
#include <getopt.h>
#include <signal.h>
#include <poll.h>
#include <sys/stat.h>
-#include <sys/ioctl.h>
#include <sys/inotify.h>
#include <linux/fs.h>
@@ -54,7 +52,6 @@
#include "journal-internal.h"
#include "journal-def.h"
#include "journal-verify.h"
-#include "journal-authenticate.h"
#include "journal-qrcode.h"
#include "journal-vacuum.h"
#include "fsprg.h"
diff --git a/src/journal/journald-console.c b/src/journal/journald-console.c
index 5363aaa4ff..f7ea779f0b 100644
--- a/src/journal/journald-console.c
+++ b/src/journal/journald-console.c
@@ -21,7 +21,6 @@
#include <time.h>
#include <fcntl.h>
-#include <unistd.h>
#include <sys/socket.h>
#include "fileio.h"
diff --git a/src/journal/journald-rate-limit.h b/src/journal/journald-rate-limit.h
index 648ab22786..466239d3c6 100644
--- a/src/journal/journald-rate-limit.h
+++ b/src/journal/journald-rate-limit.h
@@ -21,7 +21,6 @@
along with systemd; If not, see <http://www.gnu.org/licenses/>.
***/
-#include "macro.h"
#include "util.h"
typedef struct JournalRateLimit JournalRateLimit;
diff --git a/src/journal/journald-server.c b/src/journal/journald-server.c
index 7ee8174ea2..2488884634 100644
--- a/src/journal/journald-server.c
+++ b/src/journal/journald-server.c
@@ -24,20 +24,17 @@
#include <linux/sockios.h>
#include <sys/statvfs.h>
#include <sys/mman.h>
-#include <sys/timerfd.h>
#include <libudev.h>
#include "sd-journal.h"
#include "sd-messages.h"
#include "sd-daemon.h"
-#include "fileio.h"
#include "mkdir.h"
#include "hashmap.h"
#include "journal-file.h"
#include "socket-util.h"
#include "cgroup-util.h"
-#include "list.h"
#include "missing.h"
#include "conf-parser.h"
#include "selinux-util.h"
@@ -48,7 +45,6 @@
#include "journald-kmsg.h"
#include "journald-syslog.h"
#include "journald-stream.h"
-#include "journald-console.h"
#include "journald-native.h"
#include "journald-audit.h"
#include "journald-server.h"
diff --git a/src/journal/journald-server.h b/src/journal/journald-server.h
index c96877c508..559d100131 100644
--- a/src/journal/journald-server.h
+++ b/src/journal/journald-server.h
@@ -21,16 +21,12 @@
along with systemd; If not, see <http://www.gnu.org/licenses/>.
***/
-#include <inttypes.h>
#include <stdbool.h>
-#include <sys/epoll.h>
#include <sys/types.h>
-#include <sys/socket.h>
#include "sd-event.h"
#include "journal-file.h"
#include "hashmap.h"
-#include "util.h"
#include "audit.h"
#include "journald-rate-limit.h"
#include "list.h"
diff --git a/src/journal/journald-stream.c b/src/journal/journald-stream.c
index 942a857803..bc5b26d118 100644
--- a/src/journal/journald-stream.c
+++ b/src/journal/journald-stream.c
@@ -19,7 +19,6 @@
along with systemd; If not, see <http://www.gnu.org/licenses/>.
***/
-#include <fcntl.h>
#include <unistd.h>
#include <stddef.h>
diff --git a/src/journal/journald.c b/src/journal/journald.c
index 80f4634f67..28a423326e 100644
--- a/src/journal/journald.c
+++ b/src/journal/journald.c
@@ -19,12 +19,8 @@
along with systemd; If not, see <http://www.gnu.org/licenses/>.
***/
-#include <sys/epoll.h>
-#include <sys/socket.h>
-#include <errno.h>
#include <unistd.h>
-#include "systemd/sd-journal.h"
#include "systemd/sd-messages.h"
#include "systemd/sd-daemon.h"
diff --git a/src/journal/mmap-cache.c b/src/journal/mmap-cache.c
index ab21cdc288..22f75540b8 100644
--- a/src/journal/mmap-cache.c
+++ b/src/journal/mmap-cache.c
@@ -22,7 +22,6 @@
#include <errno.h>
#include <stdlib.h>
#include <sys/mman.h>
-#include <string.h>
#include "hashmap.h"
#include "list.h"
diff --git a/src/journal/mmap-cache.h b/src/journal/mmap-cache.h
index a85c2b6063..37ea7b4a9c 100644
--- a/src/journal/mmap-cache.h
+++ b/src/journal/mmap-cache.h
@@ -21,7 +21,6 @@
along with systemd; If not, see <http://www.gnu.org/licenses/>.
***/
-#include <inttypes.h>
#include <stdbool.h>
#include <sys/stat.h>
diff --git a/src/journal/test-catalog.c b/src/journal/test-catalog.c
index c605ee0e70..dbfdea609d 100644
--- a/src/journal/test-catalog.c
+++ b/src/journal/test-catalog.c
@@ -21,7 +21,6 @@
***/
#include <locale.h>
-#include <stdlib.h>
#include <unistd.h>
#include <errno.h>
#include <fcntl.h>
diff --git a/src/journal/test-journal-enum.c b/src/journal/test-journal-enum.c
index 980244e016..cde2025ae9 100644
--- a/src/journal/test-journal-enum.c
+++ b/src/journal/test-journal-enum.c
@@ -24,7 +24,6 @@
#include "log.h"
#include "sd-journal.h"
#include "macro.h"
-#include "util.h"
#include "journal-internal.h"
int main(int argc, char *argv[]) {
diff --git a/src/journal/test-journal-interleaving.c b/src/journal/test-journal-interleaving.c
index 3c706018e9..3e6141771c 100644
--- a/src/journal/test-journal-interleaving.c
+++ b/src/journal/test-journal-interleaving.c
@@ -26,7 +26,6 @@
#include "systemd/sd-journal.h"
#include "journal-file.h"
-#include "journal-internal.h"
#include "journal-vacuum.h"
#include "util.h"
#include "log.h"
diff --git a/src/journal/test-journal-verify.c b/src/journal/test-journal-verify.c
index 9da120c0bb..de9cd9c8b8 100644
--- a/src/journal/test-journal-verify.c
+++ b/src/journal/test-journal-verify.c
@@ -27,7 +27,6 @@
#include "log.h"
#include "journal-file.h"
#include "journal-verify.h"
-#include "journal-authenticate.h"
#define N_ENTRIES 6000
#define RANDOM_RANGE 77
diff --git a/src/journal/test-journal.c b/src/journal/test-journal.c
index 230d26596a..f7cc75b3d5 100644
--- a/src/journal/test-journal.c
+++ b/src/journal/test-journal.c
@@ -22,7 +22,6 @@
#include <fcntl.h>
#include <unistd.h>
-#include "systemd/sd-journal.h"
#include "log.h"
#include "journal-file.h"
diff --git a/src/journal/test-mmap-cache.c b/src/journal/test-mmap-cache.c
index 3fcd77475d..3258b22702 100644
--- a/src/journal/test-mmap-cache.c
+++ b/src/journal/test-mmap-cache.c
@@ -24,7 +24,6 @@
#include <unistd.h>
#include <fcntl.h>
-#include "log.h"
#include "macro.h"
#include "util.h"
#include "mmap-cache.h"