pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/x11/kdelibs3 Apply the official KDE patches for CAN-20...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/32acbbaef34a
branches:  trunk
changeset: 493245:32acbbaef34a
user:      markd <markd%pkgsrc.org@localhost>
date:      Sun May 01 04:35:39 2005 +0000

description:
Apply the official KDE patches for CAN-2005-1046.
http://www.kde.org/info/security/advisory-20050421-1.txt
Bump PKGREVISION.

diffstat:

 x11/kdelibs3/Makefile         |    4 +-
 x11/kdelibs3/distinfo         |   13 +-
 x11/kdelibs3/patches/patch-dc |  418 ++++++++++++++++++++++++++++++++++++++++-
 x11/kdelibs3/patches/patch-dd |    7 +-
 x11/kdelibs3/patches/patch-de |   92 +++++++-
 x11/kdelibs3/patches/patch-dg |   84 ++++++++-
 x11/kdelibs3/patches/patch-di |   39 +++
 x11/kdelibs3/patches/patch-dj |   65 ++++++
 x11/kdelibs3/patches/patch-dk |   55 +++++
 9 files changed, 733 insertions(+), 44 deletions(-)

diffs (truncated from 963 to 300 lines):

diff -r 69e6e75dd030 -r 32acbbaef34a x11/kdelibs3/Makefile
--- a/x11/kdelibs3/Makefile     Sat Apr 30 23:07:53 2005 +0000
+++ b/x11/kdelibs3/Makefile     Sun May 01 04:35:39 2005 +0000
@@ -1,7 +1,7 @@
-# $NetBSD: Makefile,v 1.83 2005/04/28 23:39:35 jlam Exp $
+# $NetBSD: Makefile,v 1.84 2005/05/01 04:35:39 markd Exp $
 
 DISTNAME=      kdelibs-${_KDE_VERSION}
-PKGREVISION=   2
+PKGREVISION=   3
 CATEGORIES=    x11
 COMMENT=       Support libraries for the KDE integrated X11 desktop
 
diff -r 69e6e75dd030 -r 32acbbaef34a x11/kdelibs3/distinfo
--- a/x11/kdelibs3/distinfo     Sat Apr 30 23:07:53 2005 +0000
+++ b/x11/kdelibs3/distinfo     Sun May 01 04:35:39 2005 +0000
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.54 2005/04/18 16:54:00 drochner Exp $
+$NetBSD: distinfo,v 1.55 2005/05/01 04:35:39 markd Exp $
 
 SHA1 (kdelibs-3.4.0.tar.bz2) = ca3ded4105a500dae5170ccf85cd62af98b33961
 RMD160 (kdelibs-3.4.0.tar.bz2) = 75917f60d115d770b5a8aa3922591e118c6bfdf0
@@ -20,9 +20,12 @@
 SHA1 (patch-cg) = e68fc3f4147b1c4760669318319e59bcf67cea51
 SHA1 (patch-da) = f84186eb73af08023f7d9960c2086a60d5042e14
 SHA1 (patch-db) = 3235276a2aad256e59d2c83d49785cb672433abc
-SHA1 (patch-dc) = c4976f2883d35d7dd366c356eeac07d17d672068
-SHA1 (patch-dd) = 161bf22a8e4178fd01e08f98be3a6534a6c74895
-SHA1 (patch-de) = 6765fbda3d248e164d5694fe54fb85c7a28d6a34
+SHA1 (patch-dc) = be18891ac90f164c145140f8286c5bc281fcf70b
+SHA1 (patch-dd) = 7bfa26bfa6962f4ebaaf4015c3c76a769998c062
+SHA1 (patch-de) = 08732b0fac0630b60ebcd92e7b566a323a0eb790
 SHA1 (patch-df) = 4c7c73e8942e6842f58420bbe5b9491e7116002d
-SHA1 (patch-dg) = de05b75ab2f7d41fb0feaccd74cb460ef8a3412c
+SHA1 (patch-dg) = a10324f6c8e82672a62af45113887e14ea80f344
 SHA1 (patch-dh) = 9981f590f83e4543e2e3478b607aed36afe373c5
+SHA1 (patch-di) = 6bbf926ec725cd3b931a9afc5e209cd3bed054cb
+SHA1 (patch-dj) = a90296d5453d4b7f776338c29300e3c475473d6b
+SHA1 (patch-dk) = c365d357c4bbc65238e04795d9012d1f3ebb54fe
diff -r 69e6e75dd030 -r 32acbbaef34a x11/kdelibs3/patches/patch-dc
--- a/x11/kdelibs3/patches/patch-dc     Sat Apr 30 23:07:53 2005 +0000
+++ b/x11/kdelibs3/patches/patch-dc     Sun May 01 04:35:39 2005 +0000
@@ -1,44 +1,432 @@
-$NetBSD: patch-dc,v 1.1 2005/04/12 11:00:03 drochner Exp $
+$NetBSD: patch-dc,v 1.2 2005/05/01 04:35:40 markd Exp $
 
---- kimgio/pcx.cpp.orig        2004-11-22 04:48:27.000000000 +0100
+--- kimgio/pcx.cpp.orig        2004-11-22 16:48:27.000000000 +1300
 +++ kimgio/pcx.cpp
-@@ -134,7 +134,8 @@ static void readImage1( QDataStream &s )
+@@ -1,5 +1,5 @@
+ /* This file is part of the KDE project
+-   Copyright (C) 2002-2003 Nadeem Hasan <nhasan%kde.org@localhost>
++   Copyright (C) 2002-2005 Nadeem Hasan <nhasan%kde.org@localhost>
+ 
+    This program is free software; you can redistribute it and/or
+    modify it under the terms of the GNU Lesser General Public
+@@ -44,6 +44,11 @@ static QDataStream &operator>>( QDataStr
+   s >> ph.HScreenSize;
+   s >> ph.VScreenSize;
+ 
++  // Skip the rest of the header
++  Q_UINT8 byte;
++  while ( s.device()->at() < 128 )
++    s >> byte;
++
+   return s;
+ }
+ 
+@@ -85,25 +90,22 @@ static QDataStream &operator<<( QDataStr
+   return s;
+ }
+ 
+-static PCXHEADER header;
+-static QImage img;
+-static Q_UINT16 w, h;
+-
+-void PCXHEADER::reset()
++PCXHEADER::PCXHEADER()
+ {
++  // Initialize all data to zero
+   QByteArray dummy( 128 );
+   dummy.fill( 0 );
+   QDataStream s( dummy, IO_ReadOnly );
+   s >> *this;
+ }
+ 
+-static void readLine( QDataStream &s, QByteArray &buf )
++static void readLine( QDataStream &s, QByteArray &buf, const PCXHEADER &header )
+ {
+   Q_UINT32 i=0;
+   Q_UINT32 size = buf.size();
+   Q_UINT8 byte, count;
+ 
+-  if ( header.Encoding == 1 )
++  if ( header.isCompressed() )
+   {
+     // Uncompress the image data
+     while ( i < size )
+@@ -130,13 +132,14 @@ static void readLine( QDataStream &s, QB
+   }
+ }
+ 
+-static void readImage1( QDataStream &s )
++static void readImage1( QImage &img, QDataStream &s, const PCXHEADER &header )
  {
    QByteArray buf( header.BytesPerLine );
  
 -  img.create( w, h, 1, 2, QImage::BigEndian );
-+  if( !img.create( w, h, 1, 2, QImage::BigEndian ))
++  if(!img.create( header.width(), header.height(), 1, 2, QImage::BigEndian ))
 +    return;
  
-   for ( int y=0; y<h; ++y )
+-  for ( int y=0; y<h; ++y )
++  for ( int y=0; y<header.height(); ++y )
    {
-@@ -160,7 +161,8 @@ static void readImage4( QDataStream &s )
+     if ( s.atEnd() )
+     {
+@@ -144,10 +147,11 @@ static void readImage1( QDataStream &s )
+       return;
+     }
+ 
+-    readLine( s, buf );
+-
+-    for ( int x=0; x<header.BytesPerLine; ++x )
+-      *( img.scanLine( y )+x ) = buf[ x ];
++    readLine( s, buf, header );
++    uchar *p = img.scanLine( y );
++    unsigned int bpl = QMIN((header.width()+7)/8, header.BytesPerLine);
++    for ( unsigned int x=0; x< bpl; ++x )
++      p[ x ] = buf[x];
+   }
+ 
+   // Set the color palette
+@@ -155,14 +159,15 @@ static void readImage1( QDataStream &s )
+   img.setColor( 1, qRgb( 255, 255, 255 ) );
+ }
+ 
+-static void readImage4( QDataStream &s )
++static void readImage4( QImage &img, QDataStream &s, const PCXHEADER &header )
+ {
    QByteArray buf( header.BytesPerLine*4 );
-   QByteArray pixbuf( w );
+-  QByteArray pixbuf( w );
++  QByteArray pixbuf( header.width() );
  
 -  img.create( w, h, 8, 16, QImage::IgnoreEndian );
-+  if( !img.create( w, h, 8, 16, QImage::IgnoreEndian ))
++  if(!img.create( header.width(), header.height(), 8, 16 ))
 +    return;
  
-   for ( int y=0; y<h; ++y )
+-  for ( int y=0; y<h; ++y )
++  for ( int y=0; y<header.height(); ++y )
    {
-@@ -196,7 +198,8 @@ static void readImage8( QDataStream &s )
+     if ( s.atEnd() )
+     {
+@@ -171,20 +176,19 @@ static void readImage4( QDataStream &s )
+     }
+ 
+     pixbuf.fill( 0 );
+-    readLine( s, buf );
++    readLine( s, buf, header );
+ 
+     for ( int i=0; i<4; i++ )
+     {
+       Q_UINT32 offset = i*header.BytesPerLine;
+-      for ( int x=0; x<w; ++x )
++      for ( unsigned int x=0; x<header.width(); ++x )
+         if ( buf[ offset + ( x/8 ) ] & ( 128 >> ( x%8 ) ) )
+           pixbuf[ x ] += ( 1 << i );
+     }
+ 
+     uchar *p = img.scanLine( y );
+-
+-    for ( int x=0; x<w; ++x )
+-      *p++ = pixbuf[ x ];
++    for ( unsigned int x=0; x<header.width(); ++x )
++      p[ x ] = pixbuf[ x ];
+   }
+ 
+   // Read the palette
+@@ -192,13 +196,14 @@ static void readImage4( QDataStream &s )
+     img.setColor( i, header.ColorMap.color( i ) );
+ }
+ 
+-static void readImage8( QDataStream &s )
++static void readImage8( QImage &img, QDataStream &s, const PCXHEADER &header )
  {
    QByteArray buf( header.BytesPerLine );
  
 -  img.create( w, h, 8, 256, QImage::IgnoreEndian );
-+  if( !img.create( w, h, 8, 256, QImage::IgnoreEndian ))
++  if(!img.create( header.width(), header.height(), 8, 256 ))
 +    return;
  
-   for ( int y=0; y<h; ++y )
+-  for ( int y=0; y<h; ++y )
++  for ( int y=0; y<header.height(); ++y )
    {
-@@ -236,7 +239,8 @@ static void readImage24( QDataStream &s 
+     if ( s.atEnd() )
+     {
+@@ -206,19 +211,19 @@ static void readImage8( QDataStream &s )
+       return;
+     }
+ 
+-    readLine( s, buf );
++    readLine( s, buf, header );
+ 
+     uchar *p = img.scanLine( y );
+-
+-    for ( int x=0; x<header.BytesPerLine; ++x )
+-      *p++ = buf[ x ];
++    unsigned int bpl = QMIN(header.BytesPerLine, header.width());
++    for ( unsigned int x=0; x<bpl; ++x )
++      p[ x ] = buf[ x ];
+   }
+ 
+   Q_UINT8 flag;
+   s >> flag;
+-  kdDebug() << "Flag: " << flag << endl;
++  kdDebug( 399 ) << "Palette Flag: " << flag << endl;
+ 
+-  if ( flag == 12 && header.Version == 5 )
++  if ( flag == 12 && ( header.Version == 5 || header.Version == 2 ) )
+   {
+     // Read the palette
+     Q_UINT8 r, g, b;
+@@ -230,15 +235,16 @@ static void readImage8( QDataStream &s )
+   }
+ }
+ 
+-static void readImage24( QDataStream &s )
++static void readImage24( QImage &img, QDataStream &s, const PCXHEADER &header )
+ {
+   QByteArray r_buf( header.BytesPerLine );
    QByteArray g_buf( header.BytesPerLine );
    QByteArray b_buf( header.BytesPerLine );
  
 -  img.create( w, h, 32 );
-+  if( !img.create( w, h, 32 ))
++  if(!img.create( header.width(), header.height(), 32 ))
 +    return;
  
-   for ( int y=0; y<h; ++y )
+-  for ( int y=0; y<h; ++y )
++  for ( int y=0; y<header.height(); ++y )
+   {
+     if ( s.atEnd() )
+     {
+@@ -246,14 +252,13 @@ static void readImage24( QDataStream &s 
+       return;
+     }
+ 
+-    readLine( s, r_buf );
+-    readLine( s, g_buf );
+-    readLine( s, b_buf );
++    readLine( s, r_buf, header );
++    readLine( s, g_buf, header );
++    readLine( s, b_buf, header );
+ 
+     uint *p = ( uint * )img.scanLine( y );
+-
+-    for ( int x=0; x<header.BytesPerLine; ++x )
+-      *p++ = qRgb( r_buf[ x ], g_buf[ x ], b_buf[ x ] );
++    for ( unsigned int x=0; x<header.width(); ++x )
++      p[ x ] = qRgb( r_buf[ x ], g_buf[ x ], b_buf[ x ] );
+   }
+ }
+ 
+@@ -268,6 +273,8 @@ KDE_EXPORT void kimgio_pcx_read( QImageI
+     return;
+   }
+ 
++  PCXHEADER header;
++
+   s >> header;
+ 
+   if ( header.Manufacturer != 10 || s.atEnd())
+@@ -276,10 +283,8 @@ KDE_EXPORT void kimgio_pcx_read( QImageI
+     return;
+   }
+ 
+-  w = ( header.XMax-header.XMin ) + 1;
+-  h = ( header.YMax-header.YMin ) + 1;
+-
+-  img.reset();
++  int w = header.width();
++  int h = header.height();
+ 
+   kdDebug( 399 ) << "Manufacturer: " << header.Manufacturer << endl;
+   kdDebug( 399 ) << "Version: " << header.Version << endl;
+@@ -288,30 +293,27 @@ KDE_EXPORT void kimgio_pcx_read( QImageI
+   kdDebug( 399 ) << "Width: " << w << endl;
+   kdDebug( 399 ) << "Height: " << h << endl;
+   kdDebug( 399 ) << "Window: " << header.XMin << "," << header.XMax << "," 



Home | Main Index | Thread Index | Old Index