rpms/gcalctool/devel gcalctool-5.8.24-matherr.patch, NONE, 1.1 gcalctool.spec, 1.24, 1.25

fedora-cvs-commits at redhat.com fedora-cvs-commits at redhat.com
Sun Oct 1 05:00:32 UTC 2006


Author: mclasen

Update of /cvs/dist/rpms/gcalctool/devel
In directory cvs.devel.redhat.com:/tmp/cvs-serv15852

Modified Files:
	gcalctool.spec 
Added Files:
	gcalctool-5.8.24-matherr.patch 
Log Message:
fix a segfault in the or_IN locale


gcalctool-5.8.24-matherr.patch:
 calctool.c |    3 ++-
 gtk.c      |    2 +-
 2 files changed, 3 insertions(+), 2 deletions(-)

--- NEW FILE gcalctool-5.8.24-matherr.patch ---
--- gcalctool-5.8.24/gcalctool/calctool.c.matherr	2006-07-24 13:24:20.000000000 -0400
+++ gcalctool-5.8.24/gcalctool/calctool.c	2006-10-01 00:57:18.000000000 -0400
@@ -1231,7 +1231,8 @@
     if (!v->started) {
         return;
     }
-    STRCPY(v->display, errmes);
+    strncpy(v->display, errmes, MAXLINE - 1);
+    v->display[MAXLINE - 1] = '\0';
     set_error_state(TRUE);
     set_display(v->display, FALSE);
     beep();
--- gcalctool-5.8.24/gcalctool/gtk.c.matherr	2006-08-09 12:54:01.000000000 -0400
+++ gcalctool-5.8.24/gcalctool/gtk.c	2006-10-01 00:59:24.000000000 -0400
@@ -2353,7 +2353,7 @@
 {
     char tooltip[MAXLINE];
 
-    SPRINTF(tooltip, _("Set accuracy from 0 to %d numeric places. Currently set to %d places. [a]"), 
+    snprintf (tooltip, MAXLINE, _("Set accuracy from 0 to %d numeric places. Currently set to %d places. [a]"), 
             MAXACC, accuracy);
     gtk_tooltips_set_tip(X->tips, BUT_ACC, tooltip, "");
 }


Index: gcalctool.spec
===================================================================
RCS file: /cvs/dist/rpms/gcalctool/devel/gcalctool.spec,v
retrieving revision 1.24
retrieving revision 1.25
diff -u -r1.24 -r1.25
--- gcalctool.spec	4 Sep 2006 22:18:49 -0000	1.24
+++ gcalctool.spec	1 Oct 2006 05:00:30 -0000	1.25
@@ -1,6 +1,6 @@
 Name:           gcalctool
 Version:        5.8.24
-Release:        1%{?dist}
+Release:        2%{?dist}
 Summary:        A desktop calculator
 
 Group:          Applications/System
@@ -27,6 +27,7 @@
 Requires(preun): GConf2
 
 Patch1: gcalctool-flex-crap.patch
+Patch2: gcalctool-5.8.24-matherr.patch
 
 %description
 gcalctool is a powerful graphical calculator with financial, logical and 
@@ -36,6 +37,7 @@
 %prep
 %setup -q
 %patch1 -p1 -b .flex-crap
+%patch2 -p1 -b .matherr
 
 
 %build
@@ -93,6 +95,10 @@
 
 
 %changelog
+* Sun Oct  1 2006 Matthias Clasen <mclasen at redhat.com> - 5.8.24-2
+- Fix a segfault in the or_IN locale due to careless
+  string handling.  (#208695)
+
 * Mon Sep  4 2006 Matthias Clasen <mclasen at redhat.com> - 5.8.24-1.fc6
 - Update to 5.8.24
 




More information about the fedora-cvs-commits mailing list