1 #ifdef HAVE_CONFIG_H 2 # include "config.h" 3 #endif 4 #include <stdio.h> 5 #include <unistd.h> 6 #ifdef HAVE_PRCTL 7 # include <sys/prctl.h> 8 #endif 9 main(int argc,char ** argv)10int main(int argc, char **argv) 11 { 12 if (argc < 2) 13 return 99; 14 #if defined HAVE_PRCTL && defined PR_SET_PTRACER && defined PR_SET_PTRACER_ANY 15 /* Turn off restrictions on tracing if applicable. If the options 16 * aren't available on this system, that's OK too. */ 17 (void) prctl(PR_SET_PTRACER, PR_SET_PTRACER_ANY); 18 #endif 19 if (write(1, "\n", 1) != 1) { 20 perror("write"); 21 return 99; 22 } 23 (void) execvp(argv[1], argv + 1); 24 perror(argv[1]); 25 return 99; 26 } 27