summaryrefslogtreecommitdiffstats
path: root/lib/Utils/spawn.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lib/Utils/spawn.cpp')
-rw-r--r--lib/Utils/spawn.cpp14
1 files changed, 14 insertions, 0 deletions
diff --git a/lib/Utils/spawn.cpp b/lib/Utils/spawn.cpp
index 3aeb682..d3e6ac6 100644
--- a/lib/Utils/spawn.cpp
+++ b/lib/Utils/spawn.cpp
@@ -5,6 +5,19 @@
*/
#include "abrtlib.h"
+using namespace std;
+
+static string concat_str_vector(char **strings)
+{
+ string result;
+ while (*strings) {
+ result += *strings++;
+ if (*strings)
+ result += ' ';
+ }
+ return result;
+}
+
/* Returns pid */
pid_t fork_execv_on_steroids(int flags,
char **argv,
@@ -71,6 +84,7 @@ pid_t fork_execv_on_steroids(int flags,
if (dir)
xchdir(dir);
+ VERB1 log("Executing: %s", concat_str_vector(argv).c_str());
execvp(argv[0], argv);
if (!(flags & EXECFLG_QUIET))
perror_msg("Can't execute '%s'", argv[0]);