From cc2d29dbf4aef328fa8dda870372b166f454ff26 Mon Sep 17 00:00:00 2001 From: Joe Richey Date: Wed, 16 Sep 2020 14:54:21 -0700 Subject: [PATCH] Include correct type definition in .h files Right now, cryptsetup makes an attempt to include the correct definitions in all of its header files, allowing the headers to compile regardless of the context in which they are included. A few files were missed, this change fixes them by adding the minimal set of #includes needed to get them to compile. Signed-off-by: Joe Richey --- lib/luks2/luks2.h | 2 ++ lib/utils_blkid.h | 2 ++ lib/utils_dm.h | 3 ++- lib/utils_storage_wrappers.h | 3 +++ 4 files changed, 9 insertions(+), 1 deletion(-) diff --git a/lib/luks2/luks2.h b/lib/luks2/luks2.h index f1c107cc..8f8a0124 100644 --- a/lib/luks2/luks2.h +++ b/lib/luks2/luks2.h @@ -23,6 +23,8 @@ #define _CRYPTSETUP_LUKS2_ONDISK_H #include +#include +#include #include "libcryptsetup.h" diff --git a/lib/utils_blkid.h b/lib/utils_blkid.h index ca50da70..d03d4a50 100644 --- a/lib/utils_blkid.h +++ b/lib/utils_blkid.h @@ -21,6 +21,8 @@ #ifndef _UTILS_BLKID_H #define _UTILS_BLKID_H +#include + struct blkid_handle; typedef enum { PRB_OK = 0, PRB_EMPTY, PRB_AMBIGUOUS, PRB_FAIL } blk_probe_status; diff --git a/lib/utils_dm.h b/lib/utils_dm.h index 22add180..0cd543b0 100644 --- a/lib/utils_dm.h +++ b/lib/utils_dm.h @@ -25,7 +25,8 @@ #define _UTILS_DM_H /* device-mapper library helpers */ -#include +#include +#include struct crypt_device; struct volume_key; diff --git a/lib/utils_storage_wrappers.h b/lib/utils_storage_wrappers.h index f360955b..2519c0af 100644 --- a/lib/utils_storage_wrappers.h +++ b/lib/utils_storage_wrappers.h @@ -22,6 +22,9 @@ #ifndef _UTILS_STORAGE_WRAPPERS_H #define _UTILS_STORAGE_WRAPPERS_H +#include +#include + struct crypt_storage_wrapper; struct device; struct volume_key;