run_command: Clean up
Aaron Marcher me@drkhsh.at
Wed, 02 May 2018 08:29:36 +0200
1 files changed,
1 insertions(+),
2 deletions(-)
jump to
M
components/run_command.c
→
components/run_command.c
@@ -11,8 +11,7 @@ {
char *p; FILE *fp; - fp = popen(cmd, "r"); - if (fp == NULL) { + if (!(fp = popen(cmd, "r"))) { fprintf(stderr, "popen '%s': %s\n", cmd, strerror(errno)); return NULL; }