Automatic date update in version.in
[binutils-gdb/blckswan.git] / gdb / testsuite / gdb.multi / bkpt-multi-exec.c
blobeb002fb2545b5a8c02ebcf4644e39cff3c03521f
1 #include <stdio.h>
2 #include <stdlib.h>
3 #include <unistd.h>
4 #include <string.h>
5 #include <limits.h>
7 int main (int argc, char ** argv)
9 char prog[PATH_MAX];
10 int len;
12 strcpy (prog, argv[0]);
13 len = strlen (prog);
14 /* Replace "bkpt-multi-exec" with "crashme". */
15 memcpy (prog + len - 15, "crashme", 7);
16 prog[len - 8] = 0;
18 printf ("foll-exec is about to execl(crashme)...\n");
20 execl (prog,
21 prog,
22 (char *)0);