GDB/MI: Document support for -exec-run --start in -list-features
[deliverable/binutils-gdb.git] / gdb / jv-valprint.c
index cb89a854008ae483ba1315228b52d1b0d90f1729..f465ca09e35ca2b3d382fb705b78825b99b06c40 100644 (file)
@@ -29,7 +29,7 @@
 #include "jv-lang.h"
 #include "c-lang.h"
 #include "annotate.h"
-#include "gdb_string.h"
+#include <string.h>
 
 /* Local functions */
 
@@ -417,22 +417,16 @@ java_print_value_fields (struct type *type, const gdb_byte *valaddr,
                }
              else if (field_is_static (&TYPE_FIELD (type, i)))
                {
+                 struct value_print_options opts;
                  struct value *v = value_static_field (type, i);
+                 struct type *t = check_typedef (value_type (v));
 
-                 if (v == NULL)
-                   val_print_optimized_out (NULL, stream);
-                 else
-                   {
-                     struct value_print_options opts;
-                     struct type *t = check_typedef (value_type (v));
-
-                     if (TYPE_CODE (t) == TYPE_CODE_STRUCT)
-                       v = value_addr (v);
-                     opts = *options;
-                     opts.deref_ref = 0;
-                     common_val_print (v, stream, recurse + 1,
-                                       &opts, current_language);
-                   }
+                 if (TYPE_CODE (t) == TYPE_CODE_STRUCT)
+                   v = value_addr (v);
+                 opts = *options;
+                 opts.deref_ref = 0;
+                 common_val_print (v, stream, recurse + 1,
+                                   &opts, current_language);
                }
              else if (TYPE_FIELD_TYPE (type, i) == NULL)
                fputs_filtered ("<unknown type>", stream);
This page took 0.024086 seconds and 4 git commands to generate.