From 0c5ed69263a38b0b9188c83633bd1f48f65df396 Mon Sep 17 00:00:00 2001 From: Daniel Friesel Date: Sat, 5 Aug 2017 06:10:40 +0200 Subject: Show ImageMagick output on the terminal unless --quiet is specified (cf #309) --- src/imlib.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/imlib.c b/src/imlib.c index 193f5f8..ecc44b5 100644 --- a/src/imlib.c +++ b/src/imlib.c @@ -323,11 +323,13 @@ static char *feh_magick_load_image(char *filename) } else if (childpid == 0) { - /* discard convert output */ devnull = open("/dev/null", O_WRONLY); dup2(devnull, 0); - dup2(devnull, 1); - dup2(devnull, 2); + if (opt.quiet) { + /* discard convert output */ + dup2(devnull, 1); + dup2(devnull, 2); + } /* * convert only accepts SIGINT via killpg, a normal kill doesn't work -- cgit v1.2.3