Background Process (Daemon) in C not execvp() -ing
问题 So, I am trying to run a background process and execvp from it. When i enter cp /path/file /var/tmp, the process is not copying the file. Here is my code for reference: void cmd_bg(char command[]) { pid_t process_id = 0; pid_t sid = 0; char* argv[512]; getArgv(command,argv); // Create child process process_id = fork(); // Indication of fork() failure if (process_id < 0) { printf("fork failed!\n"); // Return failure in exit status exit(1); } // PARENT PROCESS. Need to kill it. if (process_id >