From 7ef4b06936aa3992171bbf28fad4e363b518b86b Mon Sep 17 00:00:00 2001 From: Stefan Ritt Date: Tue, 5 Dec 2006 14:07:40 +0000 Subject: [PATCH] Added debug output for shell execution SVN revision: 1768 --- src/elogd.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/elogd.c b/src/elogd.c index 000452b2..27dbb9db 100755 --- a/src/elogd.c +++ b/src/elogd.c @@ -1146,6 +1146,13 @@ int subst_shell(char *cmd, char *result, int size) /* execute shell with redirection to /tmp/elog-shell */ sprintf(str, "/bin/sh -c \"%s\" > /tmp/elog-shell 2>&1", cmd); + + if (verbose) { + efputs("Going to execute: "); + efputs(str); + efputs("\n"); + } + system(str); exit(0); }