summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Sterrett <mr_bones_@gentoo.org>2016-01-23 13:35:22 -0500
committerMichael Sterrett <mr_bones_@gentoo.org>2016-01-23 13:37:04 -0500
commitc2c3350ada353ca2c523210909a4fea07fcc5a10 (patch)
treeb9f354ff68ccb4d166dcc5ea2dbdc1da7e2e31fa /media-libs/plib/files/plib-1.8.5-CVE-2011-4552.patch
parentsys-kernel/gentoo-sources: Fix header (diff)
downloadgentoo-c2c3350ada353ca2c523210909a4fea07fcc5a10.tar.gz
gentoo-c2c3350ada353ca2c523210909a4fea07fcc5a10.tar.bz2
gentoo-c2c3350ada353ca2c523210909a4fea07fcc5a10.zip
media-libs/plib: add patches from Debian (bug #395553 and bug #440762)
Package-Manager: portage-2.2.26
Diffstat (limited to 'media-libs/plib/files/plib-1.8.5-CVE-2011-4552.patch')
-rw-r--r--media-libs/plib/files/plib-1.8.5-CVE-2011-4552.patch54
1 files changed, 54 insertions, 0 deletions
diff --git a/media-libs/plib/files/plib-1.8.5-CVE-2011-4552.patch b/media-libs/plib/files/plib-1.8.5-CVE-2011-4552.patch
new file mode 100644
index 000000000000..78f1b22ae129
--- /dev/null
+++ b/media-libs/plib/files/plib-1.8.5-CVE-2011-4552.patch
@@ -0,0 +1,54 @@
+--- plib-1.8.5/src/ssg/ssgParser.cxx~
++++ plib-1.8.5/src/ssg/ssgParser.cxx
+@@ -57,18 +57,16 @@ void _ssgParser::error( const char *form
+ char msgbuff[ 255 ];
+ va_list argp;
+
+- char* msgptr = msgbuff;
+- if (linenum)
+- {
+- msgptr += sprintf ( msgptr,"%s, line %d: ",
+- path, linenum );
+- }
+-
+ va_start( argp, format );
+- vsprintf( msgptr, format, argp );
++ vsnprintf( msgbuff, sizeof(msgbuff), format, argp );
+ va_end( argp );
+
+- ulSetError ( UL_WARNING, "%s", msgbuff ) ;
++ if (linenum)
++ {
++ ulSetError ( UL_WARNING, "%s, line %d: %s", path, linenum, msgbuff ) ;
++ } else {
++ ulSetError ( UL_WARNING, "%s", msgbuff ) ;
++ }
+ }
+
+
+@@ -78,18 +76,16 @@ void _ssgParser::message( const char *fo
+ char msgbuff[ 255 ];
+ va_list argp;
+
+- char* msgptr = msgbuff;
+- if (linenum)
+- {
+- msgptr += sprintf ( msgptr,"%s, line %d: ",
+- path, linenum );
+- }
+-
+ va_start( argp, format );
+- vsprintf( msgptr, format, argp );
++ vsnprintf( msgbuff, sizeof(msgbuff), format, argp );
+ va_end( argp );
+
+- ulSetError ( UL_DEBUG, "%s", msgbuff ) ;
++ if (linenum)
++ {
++ ulSetError ( UL_DEBUG, "%s, line %d: %s", path, linenum, msgbuff ) ;
++ } else {
++ ulSetError ( UL_DEBUG, "%s", msgbuff ) ;
++ }
+ }
+
+ // Opens the file and does a few internal calculations based on the spec.