diff mbox series

[3/5] libsepol/test: Declare file local functions as static

Message ID 20220414135141.1723610-3-jwcart2@gmail.com (mailing list archive)
State Accepted
Headers show
Series [1/5] libsepol/test Include policydb.h header for policydb_t declaration | expand

Commit Message

James Carter April 14, 2022, 1:51 p.m. UTC
This is needed to use "-Wmissing-prototypes".

Signed-off-by: James Carter <jwcart2@gmail.com>
---
 libsepol/tests/test-expander.c        | 2 +-
 libsepol/tests/test-linker-cond-map.c | 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)
diff mbox series

Patch

diff --git a/libsepol/tests/test-expander.c b/libsepol/tests/test-expander.c
index ee70e220..a9e66ed8 100644
--- a/libsepol/tests/test-expander.c
+++ b/libsepol/tests/test-expander.c
@@ -67,7 +67,7 @@  extern int mls;
 /* Takes base, some number of modules, links them, and expands them
    reads source from myfiles array, which has the base string followed by
    each module string */
-int expander_policy_init(policydb_t * mybase, int num_modules, policydb_t ** mymodules, policydb_t * myexpanded, const char *const *myfiles)
+static int expander_policy_init(policydb_t * mybase, int num_modules, policydb_t ** mymodules, policydb_t * myexpanded, const char *const *myfiles)
 {
 	char *filename[num_modules + 1];
 	int i;
diff --git a/libsepol/tests/test-linker-cond-map.c b/libsepol/tests/test-linker-cond-map.c
index 5400c46b..694a7346 100644
--- a/libsepol/tests/test-linker-cond-map.c
+++ b/libsepol/tests/test-linker-cond-map.c
@@ -55,7 +55,7 @@  typedef struct test_cond_expr {
 	uint32_t expr_type;
 } test_cond_expr_t;
 
-void test_cond_expr_mapping(policydb_t * p, avrule_decl_t * d, test_cond_expr_t * bools, int len)
+static void test_cond_expr_mapping(policydb_t * p, avrule_decl_t * d, test_cond_expr_t * bools, int len)
 {
 	int i;
 	cond_expr_t *expr;
@@ -76,7 +76,7 @@  void test_cond_expr_mapping(policydb_t * p, avrule_decl_t * d, test_cond_expr_t
 	}
 }
 
-void test_bool_state(policydb_t * p, const char *bool, int state)
+static void test_bool_state(policydb_t * p, const char *bool, int state)
 {
 	cond_bool_datum_t *b;