X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=blobdiff_plain;f=src%2Fcore%2Fexecute.c;h=1e571da69c5e74d5a726f204933924cf308e9747;hb=2c7e050f61d1bf142389edd4eb83c1dc58c5c641;hp=e04f46f03670f1f82a813b3548ff23152c1ed2a8;hpb=d8c9d3a468e61ee2a2b2c3454e662398b0885411;p=elogind.git diff --git a/src/core/execute.c b/src/core/execute.c index e04f46f03..1e571da69 100644 --- a/src/core/execute.c +++ b/src/core/execute.c @@ -155,7 +155,7 @@ _pure_ static const char *tty_path(const ExecContext *context) { return "/dev/console"; } -void exec_context_tty_reset(const ExecContext *context) { +static void exec_context_tty_reset(const ExecContext *context) { assert(context); if (context->tty_vhangup) @@ -2214,7 +2214,8 @@ int exec_command_set(ExecCommand *c, const char *path, ...) { if (!l) return -ENOMEM; - if (!(p = strdup(path))) { + p = strdup(path); + if (!p) { strv_free(l); return -ENOMEM; }