[igt-dev] [PATCH i-g-t 05/14] runner: Remove unused headers

Ryszard Knop ryszard.knop at intel.com
Tue May 31 14:28:35 UTC 2022


Using CLion's automated code inspection, most unused includes were found
and removed. Some warnings remain as CLion is unable to track code usage
across certain attributes, but the vast majority of unneeded headers are
now gone.

Signed-off-by: Ryszard Knop <ryszard.knop at intel.com>
---
 runner/job_list.c          | 2 --
 runner/resultgen.c         | 1 -
 runner/results.c           | 2 --
 runner/resume.c            | 2 --
 runner/runner.c            | 1 -
 runner/runner_json_tests.c | 1 -
 runner/settings.c          | 1 -
 7 files changed, 10 deletions(-)

diff --git a/runner/job_list.c b/runner/job_list.c
index 520a98da..3d6ef002 100644
--- a/runner/job_list.c
+++ b/runner/job_list.c
@@ -1,12 +1,10 @@
 #include <ctype.h>
 #include <errno.h>
 #include <fcntl.h>
-#include <linux/limits.h>
 #include <stdio.h>
 #include <stdlib.h>
 #include <string.h>
 #include <sys/stat.h>
-#include <sys/types.h>
 #include <unistd.h>
 
 #include "job_list.h"
diff --git a/runner/resultgen.c b/runner/resultgen.c
index 6ecf325b..1d92d303 100644
--- a/runner/resultgen.c
+++ b/runner/resultgen.c
@@ -5,7 +5,6 @@
 #include <string.h>
 #include <sys/mman.h>
 #include <sys/stat.h>
-#include <sys/types.h>
 #include <unistd.h>
 
 #include <json.h>
diff --git a/runner/results.c b/runner/results.c
index 3eb7cb15..31510a05 100644
--- a/runner/results.c
+++ b/runner/results.c
@@ -1,8 +1,6 @@
 #include <fcntl.h>
 #include <stdio.h>
 #include <stdlib.h>
-#include <sys/stat.h>
-#include <sys/types.h>
 
 #include "resultgen.h"
 
diff --git a/runner/resume.c b/runner/resume.c
index eb8074e3..10cf253c 100644
--- a/runner/resume.c
+++ b/runner/resume.c
@@ -2,8 +2,6 @@
 #include <fcntl.h>
 #include <stdio.h>
 #include <string.h>
-#include <sys/stat.h>
-#include <sys/types.h>
 
 #include "settings.h"
 #include "job_list.h"
diff --git a/runner/runner.c b/runner/runner.c
index 4855ad64..62c2671c 100644
--- a/runner/runner.c
+++ b/runner/runner.c
@@ -1,5 +1,4 @@
 #include <stdio.h>
-#include <string.h>
 
 #include "settings.h"
 #include "job_list.h"
diff --git a/runner/runner_json_tests.c b/runner/runner_json_tests.c
index 7253c906..6b94bc1e 100644
--- a/runner/runner_json_tests.c
+++ b/runner/runner_json_tests.c
@@ -1,5 +1,4 @@
 #include <sys/types.h>
-#include <sys/stat.h>
 #include <fcntl.h>
 
 #include <json.h>
diff --git a/runner/settings.c b/runner/settings.c
index bb63a9f4..313a0c95 100644
--- a/runner/settings.c
+++ b/runner/settings.c
@@ -10,7 +10,6 @@
 #include <stdio.h>
 #include <stdlib.h>
 #include <string.h>
-#include <sys/types.h>
 #include <sys/stat.h>
 #include <sys/utsname.h>
 #include <unistd.h>
-- 
2.36.1



More information about the igt-dev mailing list