lib/exec_shell: cleanup function attributes

Reported-by: Sami Kerola <kerolasa@iki.fi>
Signed-off-by: Karel Zak <kzak@redhat.com>
This commit is contained in:
Karel Zak 2018-02-01 12:25:39 +01:00
parent 9a84ecc0d8
commit 117d079199
2 changed files with 7 additions and 2 deletions

View file

@ -1 +1,6 @@
extern void __attribute__((__noreturn__)) exec_shell(void);
#ifndef UTIL_LINUX_EXEC_SHELL_H
#define UTIL_LINUX_EXEC_SHELL_H
extern void exec_shell(void) __attribute__((__noreturn__));
#endif /* UTIL_LINUX_EXEC_SHELL_H */

View file

@ -30,7 +30,7 @@
#define DEFAULT_SHELL "/bin/sh"
void exec_shell(void)
void __attribute__((__noreturn__)) exec_shell(void)
{
const char *shell = getenv("SHELL");
char *shellc = xstrdup(shell);