Add support for target specific command line switches to old-style simualtors.
[deliverable/binutils-gdb.git] / gdb / demangle.c
index 4b5bc9becbd356f3c4ceeaf5afc3e575b27ed53c..1fd69be4c58f5c15327bc1881c7aa2ba758d66c7 100644 (file)
@@ -186,7 +186,7 @@ _initialize_demangler (void)
        libiberty_demanglers[ndems].demangling_style != unknown_demangling; 
        ndems++)
     ;
-  demangling_style_names = xmalloc (ndems * sizeof (char *));
+  demangling_style_names = xcalloc (ndems + 1, sizeof (char *));
   for (i = 0;
        libiberty_demanglers[i].demangling_style != unknown_demangling; 
        i++)
@@ -200,7 +200,7 @@ _initialize_demangler (void)
 Use `set demangle-style' without arguments for a list of demangling styles.",
                          &setlist);
   show = add_show_from_set (set, &showlist);
-  set->function.sfunc = set_demangling_command;
+  set_cmd_sfunc (set, set_demangling_command);
 
   /* Set the default demangling style chosen at compilation time. */
   set_demangling_style (DEFAULT_DEMANGLING_STYLE);
This page took 0.023613 seconds and 4 git commands to generate.