Modifies the syntax from `*__attribute__((unused))` to the correct
format `__attribute__((unused))*` to resolve a warning issued by clang
regarding unused arguments.
Additionally, adds the 'unused' attribute to other public functions to
suppress further compiler warnings.

Signed-off-by: Michael Adler <[email protected]>
---
 env/env_api.c   | 4 ++--
 tools/ebgpart.c | 2 +-
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/env/env_api.c b/env/env_api.c
index 173b764..2b5d061 100644
--- a/env/env_api.c
+++ b/env/env_api.c
@@ -56,7 +56,7 @@ char16_t *str8to16(char16_t *buffer, const char *src)
        return tmp;
 }
 
-void ebg_beverbose(ebgenv_t *e, bool v)
+void ebg_beverbose(ebgenv_t __attribute__((unused)) *e, bool v)
 {
        bgenv_be_verbose(v);
 }
@@ -141,7 +141,7 @@ uint32_t ebg_env_user_free(ebgenv_t *e)
        return bgenv_user_free(((BGENV *)e->bgenv)->data->userdata);
 }
 
-uint16_t ebg_env_getglobalstate(ebgenv_t *e)
+uint16_t ebg_env_getglobalstate(ebgenv_t __attribute__((unused)) *e)
 {
        BGENV *env;
        int res = USTATE_UNKNOWN;
diff --git a/tools/ebgpart.c b/tools/ebgpart.c
index 54cb66a..e058793 100644
--- a/tools/ebgpart.c
+++ b/tools/ebgpart.c
@@ -553,7 +553,7 @@ PedDisk *ped_disk_new(const PedDevice *dev)
        return &g_ped_dummy_disk;
 }
 
-PedPartition *ped_disk_next_partition(const PedDisk *__attribute__((unused)) 
pd,
+PedPartition *ped_disk_next_partition(const PedDisk __attribute__((unused)) 
*pd,
                                      const PedPartition *part)
 {
        return part->next;
-- 
2.41.0

-- 
You received this message because you are subscribed to the Google Groups "EFI 
Boot Guard" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/efibootguard-dev/20230726084024.40124-4-michael.adler%40siemens.com.

Reply via email to