mirror of
https://github.com/topjohnwu/selinux.git
synced 2025-02-08 12:26:50 +00:00
checkpolicy: add noreturn attribute to usage()
While at it, make usage() static and mark its argument as const. Signed-off-by: Nicolas Iooss <nicolas.iooss@m4x.org>
This commit is contained in:
parent
e720859f57
commit
ef61dd7d4b
@ -124,7 +124,7 @@ static int write_binary_policy(policydb_t * p, FILE *outfp)
|
||||
return policydb_write(p, &pf);
|
||||
}
|
||||
|
||||
static void usage(char *progname)
|
||||
static __attribute__((__noreturn__)) void usage(const char *progname)
|
||||
{
|
||||
printf("usage: %s [-h] [-V] [-b] [-C] [-U handle_unknown] [-m] [-M] [-o FILE] [INPUT]\n", progname);
|
||||
printf("Build base and policy modules.\n");
|
||||
|
@ -102,7 +102,7 @@ static const char *binfile = "policy";
|
||||
|
||||
unsigned int policyvers = POLICYDB_VERSION_MAX;
|
||||
|
||||
void usage(char *progname)
|
||||
static __attribute__((__noreturn__)) void usage(const char *progname)
|
||||
{
|
||||
printf
|
||||
("usage: %s [-b] [-C] [-d] [-U handle_unknown (allow,deny,reject)] [-M]"
|
||||
|
@ -65,7 +65,7 @@ static const char *symbol_labels[9] = {
|
||||
"levels ", "cats ", "attribs"
|
||||
};
|
||||
|
||||
void usage(const char *progname)
|
||||
static __attribute__((__noreturn__)) void usage(const char *progname)
|
||||
{
|
||||
printf("usage: %s binary_pol_file\n\n", progname);
|
||||
exit(1);
|
||||
|
@ -36,7 +36,7 @@
|
||||
|
||||
static policydb_t policydb;
|
||||
|
||||
void usage(const char *progname)
|
||||
static __attribute__((__noreturn__)) void usage(const char *progname)
|
||||
{
|
||||
printf("usage: %s binary_pol_file\n\n", progname);
|
||||
exit(1);
|
||||
|
Loading…
x
Reference in New Issue
Block a user