Fix buglet reading spreadsheets with only one row.
authorJohn Darrington <john@darrington.wattle.id.au>
Sat, 3 Nov 2007 08:50:22 +0000 (08:50 +0000)
committerJohn Darrington <john@darrington.wattle.id.au>
Sat, 3 Nov 2007 08:50:22 +0000 (08:50 +0000)
src/data/gnumeric-reader.c

index f402ef1117d9a6a7eb76c348e640f494fc928bdd..f4292a06590e9c3ad624415cce310b2c71065ce5 100644 (file)
@@ -551,7 +551,7 @@ gnumeric_open_reader (struct gnumeric_read_info *gri, struct dictionary **dict)
              xmlChar *attr =
                xmlTextReaderGetAttribute (r->xtr, _xml ("ValueType"));
 
-             if ( 60 !=  _xmlchar_to_int (attr))
+             if ( NULL == attr || 60 !=  _xmlchar_to_int (attr))
                var_spec [idx].width = 0;
 
              free (attr);