[gnumeric] Fix ODF crash. [#702197]



commit dd10e2c9604b5d1e4e5177c30be0e05006855653
Author: Andreas J Guelzow <aguelzow pyrshep ca>
Date:   Thu Jun 13 14:54:12 2013 -0600

    Fix ODF crash. [#702197]
    
    2013-06-13  Andreas J. Guelzow <aguelzow pyrshep ca>
    
        * openoffice-read.c (od_draw_object): We do not parse tables
        inside charts! So no need to worry about them!

 NEWS                                 |    1 +
 plugins/openoffice/ChangeLog         |    5 +++++
 plugins/openoffice/openoffice-read.c |   10 ----------
 3 files changed, 6 insertions(+), 10 deletions(-)
---
diff --git a/NEWS b/NEWS
index 3a57b6a..4264132 100644
--- a/NEWS
+++ b/NEWS
@@ -21,6 +21,7 @@ Andreas:
        * Fix in-cell-combos attached to merged cells. [#702146]
        * Use the pagesetup setting to determine the landscape option in LaTeX
          export [#702169]
+       * Fix ODF crash. [#702197]
 
 Darrell Tangman:
        * Update documentation for Edit and Insert menus. [#700596]
diff --git a/plugins/openoffice/ChangeLog b/plugins/openoffice/ChangeLog
index c9a5587..7598d93 100644
--- a/plugins/openoffice/ChangeLog
+++ b/plugins/openoffice/ChangeLog
@@ -1,5 +1,10 @@
 2013-06-06  Andreas J. Guelzow <aguelzow pyrshep ca>
 
+       * openoffice-read.c (od_draw_object): We do not parse tables
+       inside charts! So no need to worry about them!
+
+2013-06-06  Andreas J. Guelzow <aguelzow pyrshep ca>
+
        * openoffice-read.c (odf_text_content_end): check for NULL
        before dereferencing to avoid fedora crash
        https://bugzilla.redhat.com/show_bug.cgi?id=971573
diff --git a/plugins/openoffice/openoffice-read.c b/plugins/openoffice/openoffice-read.c
index 0523405..ed6ab59 100644
--- a/plugins/openoffice/openoffice-read.c
+++ b/plugins/openoffice/openoffice-read.c
@@ -7636,7 +7636,6 @@ od_draw_object (GsfXMLIn *xin, xmlChar const **attrs)
        gchar * name;
        gint name_len;
        GsfInput        *content = NULL;
-       gint old_sheet_count, sc;
 
        if (state->chart.so != NULL) {
                if (IS_SHEET_OBJECT_GRAPH (state->chart.so))
@@ -7709,12 +7708,6 @@ od_draw_object (GsfXMLIn *xin, xmlChar const **attrs)
 
        /* We should be saving/protecting some info to avoid it being overwritten. */
 
-       /* ODF objects can contain there own tables. During parsing of the object we will */
-       /* add these tables as new sheets to the workbook. After we are done with this    */
-       /* workbook we have to remove those sheets again.                                 */
-
-       old_sheet_count = workbook_sheet_count (state->pos.wb);
-
        if (state->debug)
                g_print ("START %s\n", name);
 
@@ -7756,9 +7749,6 @@ od_draw_object (GsfXMLIn *xin, xmlChar const **attrs)
                  &state->chart.fill_image_styles);
        pop_hash (&state->chart.saved_gradient_styles,
                  &state->chart.gradient_styles);
-
-       for (sc = workbook_sheet_count (state->pos.wb); sc > old_sheet_count; sc--)
-               workbook_sheet_delete (workbook_sheet_by_index (state->pos.wb, sc - 1));
 }
 
 static void


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]