After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 568010 - Colrow problems when loading sxc files
Colrow problems when loading sxc files
Status: RESOLVED FIXED
Product: Gnumeric
Classification: Applications
Component: import/export OOo / OASIS
git master
Other All
: Normal normal
: ---
Assigned To: Jody Goldberg
Jody Goldberg
Depends on:
Blocks:
 
 
Reported: 2009-01-16 20:05 UTC by sum1
Modified: 2009-02-22 00:35 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
the sxc file from OpenOffice.org's Bugzilla (47.75 KB, application/vnd.sun.xml.calc)
2009-01-16 20:07 UTC, sum1
  Details
Patch to try (526 bytes, patch)
2009-02-19 14:58 UTC, Morten Welinder
none Details | Review

Description sum1 2009-01-16 20:05:51 UTC
Version: r17074 (+ the patch from Bug 326595, which should be unrelated)
OS: Ubuntu Intrepid

Steps to reproduce:
- Download http://www.openoffice.org/nonav/issues/showattachment.cgi/921/oneif_256x256.sxc (from Issue 2800 in OO.org's Bugzilla)
- Open and close the file


Valgrind output:

==17588== Conditional jump or move depends on uninitialised value(s)
==17588==    at 0x40828FB: row_calc_spans (cellspan.c:401)
==17588==    by 0x40D3884: item_grid_draw (item-grid.c:441)
==17588==    by 0x4538FE8: foo_canvas_group_draw (foo-canvas.c:1496)
==17588==    by 0x4538FE8: foo_canvas_group_draw (foo-canvas.c:1496)
==17588==    by 0x453C2C3: foo_canvas_expose (foo-canvas.c:2898)
==17588==    by 0x4897035: (within /usr/lib/libgtk-x11-2.0.so.0.1400.4)
==17588==    by 0x4F673C8: (within /usr/lib/libgobject-2.0.so.0.1800.2)
==17588==    by 0x4F68C4A: g_closure_invoke (in /usr/lib/libgobject-2.0.so.0.1800.2)
==17588==    by 0x4F7ED3C: (within /usr/lib/libgobject-2.0.so.0.1800.2)
==17588==    by 0x4F8062A: g_signal_emit_valist (in /usr/lib/libgobject-2.0.so.0.1800.2)
==17588==    by 0x4F80C25: g_signal_emit (in /usr/lib/libgobject-2.0.so.0.1800.2)
==17588==    by 0x49AC33D: (within /usr/lib/libgtk-x11-2.0.so.0.1400.4)
==17588== 
==17588== Conditional jump or move depends on uninitialised value(s)
==17588==    at 0x410C2A6: sheet_col_destroy (sheet.c:3413)
==17588==    by 0x410C711: sheet_destroy_contents (sheet.c:3541)
==17588==    by 0x4150652: workbook_dispose (workbook.c:113)
==17588==    by 0x4F6AD17: g_object_unref (in /usr/lib/libgobject-2.0.so.0.1800.2)
==17588==    by 0x415D206: wbcg_close_if_user_permits (wbc-gtk.c:1569)
==17588==    by 0x415D484: wbc_gtk_close (wbc-gtk.c:1616)
==17588==    by 0x4897035: (within /usr/lib/libgtk-x11-2.0.so.0.1400.4)
==17588==    by 0x4F68C4A: g_closure_invoke (in /usr/lib/libgobject-2.0.so.0.1800.2)
==17588==    by 0x4F7F5D7: (within /usr/lib/libgobject-2.0.so.0.1800.2)
==17588==    by 0x4F8062A: g_signal_emit_valist (in /usr/lib/libgobject-2.0.so.0.1800.2)
==17588==    by 0x4F80C25: g_signal_emit (in /usr/lib/libgobject-2.0.so.0.1800.2)
==17588==    by 0x49AC33D: (within /usr/lib/libgtk-x11-2.0.so.0.1400.4)
==17588== 
==17588== Conditional jump or move depends on uninitialised value(s)
==17588==    at 0x410C772: sheet_destroy_contents (sheet.c:3548)
==17588==    by 0x4150652: workbook_dispose (workbook.c:113)
==17588==    by 0x4F6AD17: g_object_unref (in /usr/lib/libgobject-2.0.so.0.1800.2)
==17588==    by 0x415D206: wbcg_close_if_user_permits (wbc-gtk.c:1569)
==17588==    by 0x415D484: wbc_gtk_close (wbc-gtk.c:1616)
==17588==    by 0x4897035: (within /usr/lib/libgtk-x11-2.0.so.0.1400.4)
==17588==    by 0x4F68C4A: g_closure_invoke (in /usr/lib/libgobject-2.0.so.0.1800.2)
==17588==    by 0x4F7F5D7: (within /usr/lib/libgobject-2.0.so.0.1800.2)
==17588==    by 0x4F8062A: g_signal_emit_valist (in /usr/lib/libgobject-2.0.so.0.1800.2)
==17588==    by 0x4F80C25: g_signal_emit (in /usr/lib/libgobject-2.0.so.0.1800.2)
==17588==    by 0x49AC33D: (within /usr/lib/libgtk-x11-2.0.so.0.1400.4)
==17588==    by 0x48910AB: gtk_main_do_event (in /usr/lib/libgtk-x11-2.0.so.0.1400.4)


Backtrace:

Program received signal SIGSEGV, Segmentation fault.

Thread 3067012864 (LWP 17825)

  • #0 sheet_col_destroy
    at sheet.c line 3415
  • #1 sheet_destroy_contents
    at sheet.c line 3541
  • #2 workbook_dispose
    at workbook.c line 113
  • #3 g_object_unref
    from /usr/lib/libgobject-2.0.so.0
  • #4 wbcg_close_if_user_permits
    at wbc-gtk.c line 1569
  • #5 wbc_gtk_close
    at wbc-gtk.c line 1616
  • #6 cb_file_close
    at wbc-gtk-actions.c line 161
  • #7 g_cclosure_marshal_VOID__VOID
    from /usr/lib/libgobject-2.0.so.0
  • #8 g_closure_invoke
    from /usr/lib/libgobject-2.0.so.0
  • #9 ??
    from /usr/lib/libgobject-2.0.so.0
  • #10 g_signal_emit_valist
    from /usr/lib/libgobject-2.0.so.0
  • #11 g_signal_emit
    from /usr/lib/libgobject-2.0.so.0
  • #12 ??
    from /usr/lib/libgtk-x11-2.0.so.0
  • #13 gtk_action_activate
    from /usr/lib/libgtk-x11-2.0.so.0
  • #14 g_cclosure_marshal_VOID__VOID
    from /usr/lib/libgobject-2.0.so.0
  • #15 g_closure_invoke
    from /usr/lib/libgobject-2.0.so.0
  • #16 ??
    from /usr/lib/libgobject-2.0.so.0
  • #17 g_signal_emit_valist
    from /usr/lib/libgobject-2.0.so.0
  • #18 g_signal_emit
    from /usr/lib/libgobject-2.0.so.0
  • #19 gtk_widget_activate
    from /usr/lib/libgtk-x11-2.0.so.0
  • #20 gtk_menu_shell_activate_item
    from /usr/lib/libgtk-x11-2.0.so.0
  • #21 ??
    from /usr/lib/libgtk-x11-2.0.so.0
  • #22 ??
    from /usr/lib/libgtk-x11-2.0.so.0
  • #23 ??
    from /usr/lib/libgtk-x11-2.0.so.0
  • #24 ??
    from /usr/lib/libgobject-2.0.so.0
  • #25 g_closure_invoke
    from /usr/lib/libgobject-2.0.so.0
  • #26 ??
    from /usr/lib/libgobject-2.0.so.0
  • #27 g_signal_emit_valist
    from /usr/lib/libgobject-2.0.so.0
  • #28 g_signal_emit
    from /usr/lib/libgobject-2.0.so.0
  • #29 ??
    from /usr/lib/libgtk-x11-2.0.so.0
  • #30 gtk_propagate_event
    from /usr/lib/libgtk-x11-2.0.so.0
  • #31 gtk_main_do_event
    from /usr/lib/libgtk-x11-2.0.so.0
  • #32 ??
    from /usr/lib/libgdk-x11-2.0.so.0
  • #33 g_main_context_dispatch
    from /usr/lib/libglib-2.0.so.0
  • #34 ??
    from /usr/lib/libglib-2.0.so.0
  • #35 g_main_loop_run
    from /usr/lib/libglib-2.0.so.0
  • #36 gtk_main
    from /usr/lib/libgtk-x11-2.0.so.0
  • #37 main
    at main-application.c line 507

Comment 1 sum1 2009-01-16 20:07:07 UTC
Created attachment 126604 [details]
the sxc file from OpenOffice.org's Bugzilla
Comment 2 Morten Welinder 2009-02-19 14:50:25 UTC
UMR happens when
row=0 col=256
Comment 3 Morten Welinder 2009-02-19 14:58:26 UTC
Created attachment 129068 [details] [review]
Patch to try

This ought to do the trick, if I understand things right.
Comment 4 Morten Welinder 2009-02-19 15:08:21 UTC
I made colrow_reset_defaults catch any such attempt.  That takes care of
the crashing and weirdness independently of the patch above.
--> lowering severity.
Comment 5 Morten Welinder 2009-02-20 21:30:54 UTC
This problem has been fixed in the development version. The fix will be available in the next major software release. Thank you for your bug report.
Comment 6 sum1 2009-02-21 06:17:04 UTC
It looks like the colrow_reset_defaults patch (r17152) has caused a regression.

Steps to reproduce:
- Download Attachment 20975 [details] (.sxc file from Bug 125604)
- ssconvert attachment.sxc /tmp/foo.txt


Valgrind output:

==31506== Invalid read of size 1
==31506==    at 0x4080245: gnm_cell_cleanout (cell.c:69)
==31506==    by 0x410C5DB: cell_free (sheet.c:3266)
==31506==    by 0x410CD2F: cb_remove_allcells (sheet.c:3484)
==31506==    by 0x4FCF2A5: g_hash_table_foreach (ghash.c:1076)
==31506==    by 0x410C0AD: sheet_cell_foreach (sheet.c:3094)
==31506==    by 0x410CF18: sheet_destroy_contents (sheet.c:3536)
==31506==    by 0x4150FC6: workbook_dispose (workbook.c:113)
==31506==    by 0x4F6CD17: g_object_unref (gobject.c:2389)
==31506==    by 0x804A069: convert (ssconvert.c:339)
==31506==    by 0x804A2C1: main (ssconvert.c:402)
==31506==  Address 0x73d3929 is 9 bytes inside a block of size 16 free'd
==31506==    at 0x4024B4A: free (vg_replace_malloc.c:323)
==31506==    by 0x4FE5C05: g_free (gmem.c:190)
==31506==    by 0x40892C7: colrow_reset_defaults (colrow.c:1188)
==31506==    by 0x75B8C28: oo_colrow_reset_defaults (openoffice-read.c:572)
==31506==    by 0x75B8DD4: oo_table_end (openoffice-read.c:613)
==31506==    by 0x45C85B6: gsf_xml_in_end_element (gsf-libxml.c:784)
==31506==    by 0x4661559: (within /usr/lib/libxml2.so.2.6.32)
==31506==    by 0x4669241: xmlParseElement (in /usr/lib/libxml2.so.2.6.32)
==31506==    by 0x46695DC: xmlParseContent (in /usr/lib/libxml2.so.2.6.32)
==31506==    by 0x46690F9: xmlParseElement (in /usr/lib/libxml2.so.2.6.32)
==31506==    by 0x46695DC: xmlParseContent (in /usr/lib/libxml2.so.2.6.32)
==31506==    by 0x46690F9: xmlParseElement (in /usr/lib/libxml2.so.2.6.32)
==31506== 
==31506== Invalid write of size 1
==31506==    at 0x408024C: gnm_cell_cleanout (cell.c:69)
==31506==    by 0x410C5DB: cell_free (sheet.c:3266)
==31506==    by 0x410CD2F: cb_remove_allcells (sheet.c:3484)
==31506==    by 0x4FCF2A5: g_hash_table_foreach (ghash.c:1076)
==31506==    by 0x410C0AD: sheet_cell_foreach (sheet.c:3094)
==31506==    by 0x410CF18: sheet_destroy_contents (sheet.c:3536)
==31506==    by 0x4150FC6: workbook_dispose (workbook.c:113)
==31506==    by 0x4F6CD17: g_object_unref (gobject.c:2389)
==31506==    by 0x804A069: convert (ssconvert.c:339)
==31506==    by 0x804A2C1: main (ssconvert.c:402)
==31506==  Address 0x73d3929 is 9 bytes inside a block of size 16 free'd
==31506==    at 0x4024B4A: free (vg_replace_malloc.c:323)
==31506==    by 0x4FE5C05: g_free (gmem.c:190)
==31506==    by 0x40892C7: colrow_reset_defaults (colrow.c:1188)
==31506==    by 0x75B8C28: oo_colrow_reset_defaults (openoffice-read.c:572)
==31506==    by 0x75B8DD4: oo_table_end (openoffice-read.c:613)
==31506==    by 0x45C85B6: gsf_xml_in_end_element (gsf-libxml.c:784)
==31506==    by 0x4661559: (within /usr/lib/libxml2.so.2.6.32)
==31506==    by 0x4669241: xmlParseElement (in /usr/lib/libxml2.so.2.6.32)
==31506==    by 0x46695DC: xmlParseContent (in /usr/lib/libxml2.so.2.6.32)
==31506==    by 0x46690F9: xmlParseElement (in /usr/lib/libxml2.so.2.6.32)
==31506==    by 0x46695DC: xmlParseContent (in /usr/lib/libxml2.so.2.6.32)
==31506==    by 0x46690F9: xmlParseElement (in /usr/lib/libxml2.so.2.6.32)
Comment 7 Morten Welinder 2009-02-22 00:35:12 UTC
This problem has been fixed in the development version. The fix will be available in the next major software release. Thank you for your bug report.