daemon: Avoid gcc warning about noreturn function in acl & cap code.

acl.c: In function 'do_acl_get_file':
acl.c:158:1: error: function might be candidate for attribute 'noreturn' [-Werror=suggest-attribute=noreturn]
This commit is contained in:
Richard W.M. Jones
2012-11-30 09:00:08 +00:00
parent a8f6e06b30
commit fe4cdb2a47
2 changed files with 10 additions and 0 deletions

View File

@@ -154,18 +154,24 @@ optgroup_acl_available (void)
return 0;
}
extern char *do_acl_get_file (const char *path, const char *acltype) __attribute__((noreturn));
char *
do_acl_get_file (const char *path, const char *acltype)
{
abort ();
}
extern int do_acl_set_file (const char *path, const char *acltype, const char *acl) __attribute__((noreturn));
int
do_acl_set_file (const char *path, const char *acltype, const char *acl)
{
abort ();
}
extern int do_acl_delete_def_file (const char *dir) __attribute__((noreturn));
int
do_acl_delete_def_file (const char *dir)
{

View File

@@ -116,12 +116,16 @@ optgroup_linuxcaps_available (void)
return 0;
}
extern char *do_cap_get_file (const char *path) __attribute__((noreturn));
char *
do_cap_get_file (const char *path)
{
abort ();
}
extern int do_cap_set_file (const char *path, const char *cap) __attribute__((noreturn));
int
do_cap_set_file (const char *path, const char *cap)
{