Skip to content

Commit d4554fc

Browse files
committed
utils: Silence -Wunused-parameter with clang, Meson, and SELinux disabled
These parameters are unused if SELinux happens to be disabled. Signed-off-by: Simon McVittie <smcv@collabora.com>
1 parent 8f5b370 commit d4554fc

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

utils.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ die (const char *format, ...)
8282
}
8383

8484
void
85-
die_unless_label_valid (const char *label)
85+
die_unless_label_valid (UNUSED const char *label)
8686
{
8787
#ifdef HAVE_SELINUX
8888
if (is_selinux_enabled () == 1)
@@ -854,7 +854,7 @@ pivot_root (const char * new_root, const char * put_old)
854854
}
855855

856856
char *
857-
label_mount (const char *opt, const char *mount_label)
857+
label_mount (const char *opt, UNUSED const char *mount_label)
858858
{
859859
#ifdef HAVE_SELINUX
860860
if (mount_label)
@@ -871,7 +871,7 @@ label_mount (const char *opt, const char *mount_label)
871871
}
872872

873873
int
874-
label_create_file (const char *file_label)
874+
label_create_file (UNUSED const char *file_label)
875875
{
876876
#ifdef HAVE_SELINUX
877877
if (is_selinux_enabled () > 0 && file_label)
@@ -881,7 +881,7 @@ label_create_file (const char *file_label)
881881
}
882882

883883
int
884-
label_exec (const char *exec_label)
884+
label_exec (UNUSED const char *exec_label)
885885
{
886886
#ifdef HAVE_SELINUX
887887
if (is_selinux_enabled () > 0 && exec_label)

0 commit comments

Comments
 (0)