From 3c9bbe4140018a750667529d293c6ea02bd5d265 Mon Sep 17 00:00:00 2001 From: Alessandro Mauri Date: Sun, 26 Apr 2020 17:31:06 +0200 Subject: [PATCH] execvp --- hkd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hkd.c b/hkd.c index b77df32..2297d3e 100644 --- a/hkd.c +++ b/hkd.c @@ -253,7 +253,7 @@ void exec_command (char *path) break; case 0: /* we are the child */ - if(execv(path, argv) < 0) { + if(execvp(path, argv) < 0) { /* execv only returns if an error occured, so we exit * otherwise we duplicate the process */ fprintf(stderr, ANSI_COLOR_RED "Could not run %s\n" ANSI_COLOR_RESET