Limit includes in imaevm.h
authorDmitry Kasatkin <d.kasatkin@samsung.com>
Fri, 14 Feb 2014 17:16:19 +0000 (19:16 +0200)
committerDmitry Kasatkin <d.kasatkin@samsung.com>
Mon, 17 Feb 2014 13:56:07 +0000 (15:56 +0200)
Signed-off-by: Dmitry Kasatkin <d.kasatkin@samsung.com>
src/evmctl.c
src/imaevm.h
src/libimaevm.c

index 209f663..eb6bf19 100644 (file)
  */
 
 #include <sys/types.h>
+#include <sys/param.h>
 #include <sys/stat.h>
 #include <sys/ioctl.h>
-#include <sys/param.h>
 #include <fcntl.h>
 #include <unistd.h>
 #include <stdlib.h>
 #include <stdio.h>
 #include <stdint.h>
 #include <string.h>
+#include <dirent.h>
 #include <attr/xattr.h>
 #include <getopt.h>
-#include <signal.h>
 #include <keyutils.h>
 #include <asm/byteorder.h>
 #include <ctype.h>
 
+#include <openssl/sha.h>
+#include <openssl/pem.h>
+#include <openssl/hmac.h>
+#include <openssl/err.h>
+#include <openssl/rsa.h>
+
 #define USE_FPRINTF
 
 #include "imaevm.h"
index 4789e43..c565731 100644 (file)
@@ -1,25 +1,12 @@
 #ifndef _LIBIMAEVM_H
 #define _LIBIMAEVM_H
 
-#include <sys/types.h>
 #include <stdint.h>
-#include <unistd.h>
 #include <syslog.h>
-
-#include <sys/stat.h>
-#include <sys/param.h>
-#include <dirent.h>
-#include <string.h>
 #include <stdbool.h>
+#include <errno.h>
 
-#include <openssl/sha.h>
 #include <openssl/rsa.h>
-#include <openssl/pem.h>
-#include <openssl/hmac.h>
-#include <openssl/engine.h>
-#include <openssl/evp.h>
-#include <openssl/err.h>
-#include <openssl/x509.h>
 
 #ifdef USE_FPRINTF
 #define do_log(level, fmt, args...)    ({ if (level <= params.verbose) fprintf(stderr, fmt, ##args); })
index 3d780c6..2e1ef2c 100644 (file)
 /* should we use logger instead for library? */
 #define USE_FPRINTF
 
+#include <sys/types.h>
+#include <sys/param.h>
+#include <sys/stat.h>
+#include <unistd.h>
+#include <dirent.h>
+#include <string.h>
+#include <stdio.h>
+
+#include <openssl/pem.h>
+#include <openssl/evp.h>
+#include <openssl/x509.h>
+
 #include "imaevm.h"
 
 const char *const pkey_hash_algo[PKEY_HASH__LAST] = {