* p-lang.c (is_pascal_string_type): Check that TYPE arg is non NULL.
[deliverable/binutils-gdb.git] / gdb / p-lang.c
index c768d1bec3dc3ed6ed2cbfbe1499d085f9e8c7db..0db99a4aa92b346a269c7945c0d753f59654c60b 100644 (file)
@@ -101,7 +101,7 @@ is_pascal_string_type (struct type *type,int *length_pos,
                       struct type **char_type,
                       char **arrayname)
 {
-  if (TYPE_CODE (type) == TYPE_CODE_STRUCT)
+  if ((type != NULL) && (TYPE_CODE (type) == TYPE_CODE_STRUCT))
     {
       /* Old Borland type pascal strings from Free Pascal Compiler.  */
       /* Two fields: length and st.  */
This page took 0.024144 seconds and 4 git commands to generate.