Login
[x]
Log in using an account from:
Fedora Account System
Red Hat Associate
Red Hat Customer
Or login using a Red Hat Bugzilla account
Forgot Password
Login:
Hide Forgot
Create an Account
Red Hat Bugzilla – Attachment 908226 Details for
Bug 1037042
drgeo FTBFS if "-Werror=format-security" flag is used
[?]
New
Simple Search
Advanced Search
My Links
Browse
Requests
Reports
Current State
Search
Tabular reports
Graphical reports
Duplicates
Other Reports
User Changes
Plotly Reports
Bug Status
Bug Severity
Non-Defaults
|
Product Dashboard
Help
Page Help!
Bug Writing Guidelines
What's new
Browser Support Policy
5.0.4.rh83 Release notes
FAQ
Guides index
User guide
Web Services
Contact
Legal
This site requires JavaScript to be enabled to function correctly, please enable it.
[patch]
Patch for rawhide
drgeo-Fix-for-Werror-format-security-1037024-1106158.patch (text/plain), 5.38 KB, created by
Yaakov Selkowitz
on 2014-06-12 17:42:26 UTC
(
hide
)
Description:
Patch for rawhide
Filename:
MIME Type:
Creator:
Yaakov Selkowitz
Created:
2014-06-12 17:42:26 UTC
Size:
5.38 KB
patch
obsolete
>From 242392f4f88b546e26907320e8722e3a605394d0 Mon Sep 17 00:00:00 2001 >From: Yaakov Selkowitz <yselkowitz@users.sourceforge.net> >Date: Thu, 12 Jun 2014 12:41:07 -0500 >Subject: [PATCH] Fix for -Werror=format-security (#1037024, #1106158) > >--- > drgeo-1.1.0-format-security.patch | 82 +++++++++++++++++++++++++++++++++++++++ > drgeo.spec | 7 +++- > 2 files changed, 88 insertions(+), 1 deletion(-) > create mode 100644 drgeo-1.1.0-format-security.patch > >diff --git a/drgeo-1.1.0-format-security.patch b/drgeo-1.1.0-format-security.patch >new file mode 100644 >index 0000000..ec39ecb >--- /dev/null >+++ b/drgeo-1.1.0-format-security.patch >@@ -0,0 +1,82 @@ >+These are actually arrays of string literals, but there doesn't seem to >+be a way of convincing gcc of that >+ >+--- a/geo/drgeo_postscriptdrawable.cc >++++ b/geo/drgeo_postscriptdrawable.cc >+@@ -130,8 +130,8 @@ drgeoPostScriptDrawable::drawPoint (drgeoStyle & style, drgeoPoint & point) >+ p = areaToPostScript (point); >+ >+ /* we're initializing color and line width */ >+- fprintf (fileHandle, postscriptColor[style.color]); >+- fprintf (fileHandle, postscriptLineWidth[drgeoThicknessNormal + 1]); >++ fprintf (fileHandle, "%s", postscriptColor[style.color]); >++ fprintf (fileHandle, "%s", postscriptLineWidth[drgeoThicknessNormal + 1]); >+ >+ switch (style.pointShape) >+ { >+@@ -207,9 +207,9 @@ drawPolygon (drgeoStyle & style, drgeoPoint * point, gint number) >+ gint nb; >+ >+ /* we're initializing color and line width */ >+- fprintf (fileHandle, postscriptColor[style.color]); >++ fprintf (fileHandle, "%s", postscriptColor[style.color]); >+ /* Invisible line. */ >+- fprintf (fileHandle, postscriptLineWidth[0]); >++ fprintf (fileHandle, "%s", postscriptLineWidth[0]); >+ >+ fprintf (fileHandle, "%%Polygon\nnewpath\n"); >+ >+@@ -235,11 +235,11 @@ drawSegment (drgeoStyle & style, drgeoPoint & start, drgeoPoint & end) >+ p2 = areaToPostScript (end); >+ p1 = areaToPostScript (start); >+ >+- fprintf (fileHandle, postscriptColor[style.color]); >++ fprintf (fileHandle, "%s", postscriptColor[style.color]); >+ if (style.mask == yes) >+- fprintf (fileHandle, postscriptLineWidth[0]); >++ fprintf (fileHandle, "%s", postscriptLineWidth[0]); >+ else >+- fprintf (fileHandle, postscriptLineWidth[style.thick + 1]); >++ fprintf (fileHandle, "%s", postscriptLineWidth[style.thick + 1]); >+ fprintf (fileHandle, >+ "%% Segment\n%f %f moveto %f %f lineto stroke\n", >+ p1.getX () * PostScriptScale, p1.getY () * PostScriptScale, >+@@ -263,11 +263,11 @@ drawCircle (drgeoStyle & style, drgeoPoint & center, double radius) >+ drgeoPoint p; >+ >+ p = areaToPostScript (center); >+- fprintf (fileHandle, postscriptColor[style.color]); >++ fprintf (fileHandle, "%s", postscriptColor[style.color]); >+ if (style.mask == yes) >+- fprintf (fileHandle, postscriptLineWidth[0]); >++ fprintf (fileHandle, "%s", postscriptLineWidth[0]); >+ else >+- fprintf (fileHandle, postscriptLineWidth[style.thick + 1]); >++ fprintf (fileHandle, "%s", postscriptLineWidth[style.thick + 1]); >+ fprintf (fileHandle, >+ /* is there a better way to draw a circle in ps ? */ >+ "%% Circle\n%f %f moveto %f %f %f 0 360 arc closepath stroke\n", >+@@ -285,11 +285,11 @@ drawArc (drgeoStyle & style, drgeoPoint & center, double radius, >+ drgeoPoint p, startPoint; >+ >+ p = areaToPostScript (center); >+- fprintf (fileHandle, postscriptColor[style.color]); >++ fprintf (fileHandle, "%s", postscriptColor[style.color]); >+ if (style.mask == yes) >+- fprintf (fileHandle, postscriptLineWidth[0]); >++ fprintf (fileHandle, "%s", postscriptLineWidth[0]); >+ else >+- fprintf (fileHandle, postscriptLineWidth[style.thick + 1]); >++ fprintf (fileHandle, "%s", postscriptLineWidth[style.thick + 1]); >+ >+ >+ >+@@ -336,7 +336,7 @@ drawText (drgeoPoint & where, char *text, drgeoColorType fontColor) >+ // FIXME: how to handle this correctly ? >+ convString = g_convert (text, -1, "iso8859-1", "utf-8", NULL, NULL, NULL); >+ >+- fprintf (fileHandle, postscriptColor[fontColor]); >++ fprintf (fileHandle, "%s", postscriptColor[fontColor]); >+ /* The size of the font is arbitrary : 10 points */ >+ fprintf (fileHandle, >+ "%% Text\n/Times findfont 10 scalefont setfont %f %f moveto (%s) show\n", >diff --git a/drgeo.spec b/drgeo.spec >index 1821095..3f3a430 100644 >--- a/drgeo.spec >+++ b/drgeo.spec >@@ -1,7 +1,7 @@ > Summary: Interactive educational geometry software > Name: drgeo > Version: 1.1.0 >-Release: 26%{?dist} >+Release: 27%{?dist} > License: GPLv2+ > Group: Applications/Engineering > URL: http://www.ofset.org/drgeo >@@ -11,6 +11,7 @@ Patch0: drgeo-1.1.0-htmlview.patch > Patch1: drgeo.patch > Patch2: drgeo-1.1.0-anonymous-type.patch > Patch3: drgeo-1.1.0-guile-fixups.patch >+Patch4: drgeo-1.1.0-format-security.patch > > BuildRequires: flex, bison, gmp-devel >= 2.0.2, desktop-file-utils > BuildRequires: guile-devel, libglade2-devel, intltool, gettext >@@ -27,6 +28,7 @@ situation with students from primary or secondary level. > %patch1 -p1 > %patch2 -p1 > %patch3 -p1 >+%patch4 -p1 > > %build > %configure >@@ -56,6 +58,9 @@ rmdir %{buildroot}%{_datadir}/texmacs/ > %{_datadir}/applications/drgeo.desktop > > %changelog >+* Thu Jun 12 2014 Yaakov Selkowitz <yselkowi@redhat.com> - 1.1.0-27 >+- Fix for -Werror=format-security (#1037024, #1106158) >+ > * Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.1.0-26 > - Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild > >-- >1.9.3 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 1037042
: 908226 |
908340