lib: remove unneeded header includes
[dpdk.git] / lib / eal / common / eal_common_options.c
index 45d393b..f247a42 100644 (file)
@@ -4,7 +4,6 @@
  */
 
 #include <stdlib.h>
-#include <unistd.h>
 #include <string.h>
 #ifndef RTE_EXEC_ENV_WINDOWS
 #include <syslog.h>
@@ -17,7 +16,6 @@
 #include <dlfcn.h>
 #include <libgen.h>
 #endif
-#include <sys/types.h>
 #include <sys/stat.h>
 #ifndef RTE_EXEC_ENV_WINDOWS
 #include <dirent.h>
@@ -1989,12 +1987,9 @@ compute_ctrl_threads_cpuset(struct internal_config *internal_cfg)
 int
 eal_cleanup_config(struct internal_config *internal_cfg)
 {
-       if (internal_cfg->hugefile_prefix != NULL)
-               free(internal_cfg->hugefile_prefix);
-       if (internal_cfg->hugepage_dir != NULL)
-               free(internal_cfg->hugepage_dir);
-       if (internal_cfg->user_mbuf_pool_ops_name != NULL)
-               free(internal_cfg->user_mbuf_pool_ops_name);
+       free(internal_cfg->hugefile_prefix);
+       free(internal_cfg->hugepage_dir);
+       free(internal_cfg->user_mbuf_pool_ops_name);
 
        return 0;
 }