gdb/
[binutils-gdb.git] / gdb / fork-child.c
index f1153077f59c39de6d1822f2b3b163bba4fd9582..bb173e7cac9ab12606aa56cf6f3673992781b077 100644 (file)
@@ -315,7 +315,7 @@ fork_inferior (char *exec_file_arg, char *allargs, char **env,
             in a separate process group.  */
          debug_setpgrp = gdb_setpgid ();
          if (debug_setpgrp == -1)
-           perror ("setpgrp failed in child");
+           perror (_("setpgrp failed in child"));
        }
 
       /* Ask the tty subsystem to switch to the one we specified
@@ -367,12 +367,11 @@ fork_inferior (char *exec_file_arg, char *allargs, char **env,
          /* Otherwise, we directly exec the target program with
             execvp.  */
          int i;
-         char *errstring;
 
          execvp (exec_file, argv);
 
          /* If we get here, it's an error.  */
-         errstring = safe_strerror (errno);
+         safe_strerror (errno);
          fprintf_unfiltered (gdb_stderr, "Cannot exec %s ", exec_file);
 
          i = 1;
@@ -384,10 +383,6 @@ fork_inferior (char *exec_file_arg, char *allargs, char **env,
              i++;
            }
          fprintf_unfiltered (gdb_stderr, ".\n");
-#if 0
-         /* This extra info seems to be useless.  */
-         fprintf_unfiltered (gdb_stderr, "Got error %s.\n", errstring);
-#endif
          gdb_flush (gdb_stderr);
          _exit (0177);
        }