Return X86_TDESC_MMX in x86_get_ipa_tdesc_idx
[deliverable/binutils-gdb.git] / gdb / interps.c
index 4de7c4e8be6c48d4b266943e06f4ba90c3babaf5..1e59034a5e87b052bdd1007ea0019ca10e5455fb 100644 (file)
@@ -407,21 +407,14 @@ interpreter_exec_cmd (char *args, int from_tty)
 {
   struct ui_interp_info *ui_interp = get_current_interp_info ();
   struct interp *old_interp, *interp_to_use;
-  char **prules = NULL;
-  char **trule = NULL;
   unsigned int nrules;
   unsigned int i;
-  struct cleanup *cleanup;
 
   if (args == NULL)
     error_no_arg (_("interpreter-exec command"));
 
-  prules = gdb_buildargv (args);
-  cleanup = make_cleanup_freeargv (prules);
-
-  nrules = 0;
-  for (trule = prules; *trule != NULL; trule++)
-    nrules++;
+  gdb_argv prules (args);
+  nrules = prules.count ();
 
   if (nrules < 2)
     error (_("usage: interpreter-exec <interpreter> [ <command> ... ]"));
@@ -446,8 +439,6 @@ interpreter_exec_cmd (char *args, int from_tty)
     }
 
   interp_set (old_interp, 0);
-
-  do_cleanups (cleanup);
 }
 
 /* See interps.h.  */
This page took 0.029251 seconds and 4 git commands to generate.