aboutsummaryrefslogtreecommitdiff
path: root/gdb/gdbserver/spu-low.c
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/gdbserver/spu-low.c')
-rw-r--r--gdb/gdbserver/spu-low.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/gdb/gdbserver/spu-low.c b/gdb/gdbserver/spu-low.c
index 2298824..77f671e 100644
--- a/gdb/gdbserver/spu-low.c
+++ b/gdb/gdbserver/spu-low.c
@@ -278,7 +278,9 @@ spu_create_inferior (char *program, char **allargs)
setpgid (0, 0);
- execvp (program, allargs);
+ execv (program, allargs);
+ if (errno == ENOENT)
+ execvp (program, allargs);
fprintf (stderr, "Cannot exec %s: %s.\n", program,
strerror (errno));