Constify get_exec_file
[deliverable/binutils-gdb.git] / gdb / gnu-nat.c
index 93a50becceb66d33cd52fcde4690e94367f8fbd6..cf42af43673a5b39825e558f9a687caf9dce114b 100644 (file)
@@ -2195,7 +2195,6 @@ void
 gnu_nat_target::attach (const char *args, int from_tty)
 {
   int pid;
-  char *exec_file;
   struct inf *inf = cur_inf ();
   struct inferior *inferior;
 
@@ -2206,7 +2205,7 @@ gnu_nat_target::attach (const char *args, int from_tty)
 
   if (from_tty)
     {
-      exec_file = (char *) get_exec_file (0);
+      const char *exec_file = get_exec_file (0);
 
       if (exec_file)
        printf_unfiltered ("Attaching to program `%s', pid %d\n",
@@ -2260,7 +2259,7 @@ gnu_nat_target::detach (inferior *inf, int from_tty)
 
   if (from_tty)
     {
-      char *exec_file = get_exec_file (0);
+      const char *exec_file = get_exec_file (0);
 
       if (exec_file)
        printf_unfiltered ("Detaching from program `%s' pid %d\n",
This page took 0.023567 seconds and 4 git commands to generate.