Clean up header includes
authorAaron Marcher <me@drkhsh.at>
Wed, 30 May 2018 17:35:37 +0000 (19:35 +0200)
committerAaron Marcher <me@drkhsh.at>
Wed, 30 May 2018 17:35:37 +0000 (19:35 +0200)
 - Remove <errno.h> because related functions are in util.c now
 - Remove corresponding <string.h> if not used otherwise

14 files changed:
components/battery.c
components/cpu.c
components/disk.c
components/hostname.c
components/ip.c
components/kernel_release.c
components/num_files.c
components/run_command.c
components/swap.c
components/temperature.c
components/uptime.c
components/user.c
components/volume.c
components/wifi.c

index 8bfe42a2d2e192de719a92387a74b9f67a066a83..99e09d531f95f5b38f4893b4da82ff3ba2fa983e 100644 (file)
@@ -1,5 +1,4 @@
 /* See LICENSE file for copyright and license details. */
-#include <errno.h>
 #include <stdio.h>
 #include <string.h>
 
index ecd45a6a2e94329de9ee910d906177e97b7b7169..cd5ebe4c84da2b306ede6fb691fc62b2b99e39d3 100644 (file)
@@ -1,5 +1,4 @@
 /* See LICENSE file for copyright and license details. */
-#include <errno.h>
 #include <stdio.h>
 #include <string.h>
 
index f3c96d5059335ce3ad7e934f87b66636f1474f7e..9d2284e2441e08e6beaddfaba6eac50d2416ced7 100644 (file)
@@ -1,7 +1,5 @@
 /* See LICENSE file for copyright and license details. */
-#include <errno.h>
 #include <stdio.h>
-#include <string.h>
 #include <sys/statvfs.h>
 
 #include "../util.h"
index dc3bbf15a83e8f812440a1a65258f90e6ba7d52d..23da6771b63a185e11e3a2ffc4b38af5773b0cc7 100644 (file)
@@ -1,7 +1,5 @@
 /* See LICENSE file for copyright and license details. */
-#include <errno.h>
 #include <stdio.h>
-#include <string.h>
 #include <unistd.h>
 
 #include "../util.h"
index 468dc84e2091cc33a8cda79b5d3876ca031371ab..f26e49afeafae2c8ff412925ad2a1d71c3432800 100644 (file)
@@ -1,5 +1,4 @@
 /* See LICENSE file for copyright and license details. */
-#include <errno.h>
 #include <ifaddrs.h>
 #include <netdb.h>
 #include <stdio.h>
index 531014cda62331f11144a571f3f42e8c73d36453..045730127fb8b7f0fc6d019d5506082670612b8b 100644 (file)
@@ -1,8 +1,6 @@
 /* See LICENSE file for copyright and license details. */
-#include <errno.h>
 #include <sys/utsname.h>
 #include <stdio.h>
-#include <string.h>
 
 #include "../util.h"
 
index 917903737652a4ddc03c02e024e9ef692e998ffa..86ea064ba65a5e5303071cdcddce12247ff9009c 100644 (file)
@@ -1,6 +1,5 @@
 /* See LICENSE file for copyright and license details. */
 #include <dirent.h>
-#include <errno.h>
 #include <stdio.h>
 #include <string.h>
 
index 7ae1b69f7e4b57923218578f7a9d728bbc4655f5..e00b4786e659116b042f64a467fd50e410cb723e 100644 (file)
@@ -1,5 +1,4 @@
 /* See LICENSE file for copyright and license details. */
-#include <errno.h>
 #include <stdio.h>
 #include <string.h>
 
index 9bd599a787367bf43dcf50e028043e5674f3b675..b3b519ea3d2992de287b04f54ba8b8aa3c20ea4d 100644 (file)
@@ -1,5 +1,4 @@
 /* See LICENSE file for copyright and license details. */
-#include <errno.h>
 #include <stdint.h>
 #include <stdio.h>
 #include <stdlib.h>
index bbec80b710a899840161ed6dfa5efb44b9e649eb..fe2e0c9903b1303da9b6e69023ac0848b816053a 100644 (file)
@@ -16,9 +16,7 @@
                return bprintf("%d", temp / 1000);
        }
 #elif defined(__OpenBSD__)
-       #include <errno.h>
        #include <stdio.h>
-       #include <string.h>
        #include <sys/time.h> /* before <sys/sensors.h> for struct timeval */
        #include <sys/sensors.h>
        #include <sys/sysctl.h>
index f97809d52781f26065a4b797d4e3db79f12e010e..8f15d71a4b6729107362ab3bdca02c4a68c1efe3 100644 (file)
@@ -29,8 +29,6 @@ format(int uptime)
                return format(uptime);
        }
 #elif defined(__OpenBSD__)
-       #include <errno.h>
-       #include <string.h>
        #include <sys/sysctl.h>
        #include <sys/time.h>
 
index cd503f6eb517da73fc62958d8a7bd49ffa41ee0b..71a0c9d9a3bd3ddb4bc9ac4559cddc810f6736f8 100644 (file)
@@ -1,8 +1,6 @@
 /* See LICENSE file for copyright and license details. */
-#include <errno.h>
 #include <pwd.h>
 #include <stdio.h>
-#include <string.h>
 #include <sys/types.h>
 #include <unistd.h>
 
index 8674211c420e513e039be6c1119343a450f0128f..8a70b20d31ffab95d46f2d19a9db1979f3ad9819 100644 (file)
@@ -1,5 +1,4 @@
 /* See LICENSE file for copyright and license details. */
-#include <errno.h>
 #include <fcntl.h>
 #include <stdio.h>
 #include <string.h>
index b3e1723bd9729e02672a95f05b2d8040ab84fe6a..7815c868172d1382a4493ab0f2e86eca3018d6eb 100644 (file)
@@ -1,5 +1,4 @@
 /* See LICENSE file for copyright and license details. */
-#include <errno.h>
 #include <ifaddrs.h>
 #include <stdio.h>
 #include <string.h>