]> git.ipfire.org Git - thirdparty/binutils-gdb.git/commitdiff
* p-lang.c (is_pascal_string_type): Check that TYPE arg is non NULL.
authorPierre Muller <muller@sourceware.org>
Wed, 10 Mar 2010 22:31:48 +0000 (22:31 +0000)
committerPierre Muller <muller@sourceware.org>
Wed, 10 Mar 2010 22:31:48 +0000 (22:31 +0000)
gdb/ChangeLog
gdb/p-lang.c

index b8a45306bc935eb46b4acf829bcdf1658fd017ac..991d3c881a6d422c869185c8d5ba9ecab2b15e68 100644 (file)
@@ -1,3 +1,7 @@
+2010-03-10  Pierre Muller  <muller@ics.u-strasbg.fr>
+
+       * p-lang.c (is_pascal_string_type): Check that TYPE arg is non NULL.
+
 2010-03-07  Joel Brobecker  <brobecker@adacore.com>
 
        * remote.c (remote_get_ada_task_ptid): New function.
index c768d1bec3dc3ed6ed2cbfbe1499d085f9e8c7db..415cd9945667e273dd36753c36a58a7b82080a9a 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.  */