* cli/cli-setshow.c (do_setshow_command): Partially revert previous
authorDaniel Jacobowitz <drow@false.org>
Sat, 28 May 2005 18:27:28 +0000 (18:27 +0000)
committerDaniel Jacobowitz <drow@false.org>
Sat, 28 May 2005 18:27:28 +0000 (18:27 +0000)
change.  Cast to "char **" for var_string.

gdb/ChangeLog
gdb/cli/cli-setshow.c

index 0b6102f75642a4459094101f6673dc4c71454286..3e0d69d336cee989f75c5c461390798b6a142bb2 100644 (file)
@@ -1,3 +1,8 @@
+2005-05-28  Daniel Jacobowitz  <dan@codesourcery.com>
+
+       * cli/cli-setshow.c (do_setshow_command): Partially revert previous
+       change.  Cast to "char **" for var_string.
+
 2005-05-28  Daniel Jacobowitz  <dan@codesourcery.com>
 
        * cp-name-parser.y (parse_escape): Revert previous change.  Return
index 4002953bb71748eca58177a182194bf7a793b678..68c0f6266b3abf4856aa34176c37690fdd94bb19 100644 (file)
@@ -301,8 +301,8 @@ do_setshow_command (char *arg, int from_tty, struct cmd_list_element *c)
       switch (c->var_type)
        {
        case var_string:
-         if (((char *)c->var)[0] != '\0')
-           fputstr_filtered ((char *)c->var, '"', stb->stream);
+         if (*(char **) c->var)
+           fputstr_filtered (*(char **) c->var, '"', stb->stream);
          break;
        case var_string_noescape:
        case var_optional_filename: