[gnumeric] xls: fix hang on save.



commit 202c821155a9c74b4e75ae3a276a6c77453c6eb4
Author: Morten Welinder <terra gnome org>
Date:   Sun Feb 16 12:10:00 2014 -0500

    xls: fix hang on save.

 NEWS                           |    3 +++
 plugins/excel/ChangeLog        |    4 ++++
 plugins/excel/ms-excel-write.c |    3 ++-
 3 files changed, 9 insertions(+), 1 deletions(-)
---
diff --git a/NEWS b/NEWS
index 54aad2c..8f7b40c 100644
--- a/NEWS
+++ b/NEWS
@@ -1,5 +1,8 @@
 Gnumeric 1.12.11
 
+Jean:
+       * Fix hang on xls/biff7 save.  [#724399]
+
 --------------------------------------------------------------------------
 Gnumeric 1.12.10
 
diff --git a/plugins/excel/ChangeLog b/plugins/excel/ChangeLog
index 1c98594..20a6b15 100644
--- a/plugins/excel/ChangeLog
+++ b/plugins/excel/ChangeLog
@@ -1,3 +1,7 @@
+2014-02-16  Morten Welinder  <terra gnome org>
+
+       * ms-excel-write.c (excel_write_string): Fix hand.  #724399.
+
 2014-02-11  Morten Welinder <terra gnome org>
 
        * Release 1.12.10
diff --git a/plugins/excel/ms-excel-write.c b/plugins/excel/ms-excel-write.c
index d85bf98..e029020 100644
--- a/plugins/excel/ms-excel-write.c
+++ b/plugins/excel/ms-excel-write.c
@@ -373,7 +373,8 @@ excel_write_string (BiffPut *bp, WriteStringFlags flags,
                                out_bytes++;
                        }
                        avail = MIN (avail, output_len);
-                       avail = (avail - offset) / 2 * 2 + offset; /* we need to export an even byte number */
+                       if (avail != output_len)
+                               avail = (avail - offset) / 2 * 2 + offset; /* we need to export an even byte 
number */
                        ms_biff_put_var_write (bp, tmp, avail);
                        output_len -= avail;
                        tmp += avail;


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