[goffice] GOFormat: Fix ABR.



commit c13b51e1b713e26d15c164319a8da216f2f8edd6
Author: Morten Welinder <terra gnome org>
Date:   Sat May 9 16:07:38 2015 -0400

    GOFormat: Fix ABR.
    
    ABR for global variable, so Valgrind is no help.

 ChangeLog                 |    7 ++++++-
 NEWS                      |    3 +++
 goffice/utils/go-format.c |    2 +-
 3 files changed, 10 insertions(+), 2 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index d022a3e..c169f4d 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,7 +1,12 @@
+2015-05-09  Morten Welinder  <terra gnome org>
+
+       * goffice/utils/go-format.c (go_format_parse): Don't read beyond
+       global variable's end.  [#749167]
+
 2015-05-06  Jean Brefort  <jean brefort normalesup org>
 
        * goffice/utils/go-pixbuf.c (go_pixbuf_save): don't save when no data is
-       available [see #748493, comments 13 to 16] 
+       available [see #748493, comments 13 to 16]
 
 2015-05-04  Morten Welinder  <terra gnome org>
 
diff --git a/NEWS b/NEWS
index 33d96c0..1ebb503 100644
--- a/NEWS
+++ b/NEWS
@@ -3,6 +3,9 @@ goffice 0.10.23:
 Jean:
        * Disable metafiles support when there is no screen. [#748493]
 
+Morten:
+       * Fix ABR [#749167]
+
 --------------------------------------------------------------------------
 goffice 0.10.22:
 
diff --git a/goffice/utils/go-format.c b/goffice/utils/go-format.c
index 195e4b4..e65d00e 100644
--- a/goffice/utils/go-format.c
+++ b/goffice/utils/go-format.c
@@ -2548,7 +2548,7 @@ go_format_parse (const char *str)
                                GO_FMT_COND_TEXT
                        };
                        GOFormatCondition *cond = conditions + i;
-                       if (i <= 4 && cond->op == GO_FMT_COND_NONE) {
+                       if (i < 4 && cond->op == GO_FMT_COND_NONE) {
                                cond->implicit = TRUE;
                                cond->val = 0;
                                if (i == 0 && no_zero_format && !negative_explicit)


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