Merge branch '2.2' into 2.3

This commit is contained in:
Juergen Daubert 2007-03-07 18:05:51 +01:00
commit 80416a8a9a
25 changed files with 57 additions and 600 deletions

View File

@ -51,6 +51,7 @@ drwxr-xr-x root/root lib/modules/<kernel-version>/kernel/sound/i2c/
drwxr-xr-x root/root lib/modules/<kernel-version>/kernel/sound/i2c/other/
-rw-r--r-- root/root lib/modules/<kernel-version>/kernel/sound/i2c/other/snd-ak4114.ko
-rw-r--r-- root/root lib/modules/<kernel-version>/kernel/sound/i2c/other/snd-ak4xxx-adda.ko
-rw-r--r-- root/root lib/modules/<kernel-version>/kernel/sound/i2c/other/snd-pt2258.ko
-rw-r--r-- root/root lib/modules/<kernel-version>/kernel/sound/i2c/snd-cs8427.ko
-rw-r--r-- root/root lib/modules/<kernel-version>/kernel/sound/i2c/snd-i2c.ko
-rw-r--r-- root/root lib/modules/<kernel-version>/kernel/sound/i2c/snd-tea6330t.ko
@ -105,9 +106,10 @@ drwxr-xr-x root/root lib/modules/<kernel-version>/kernel/sound/isa/sb/
-rw-r--r-- root/root lib/modules/<kernel-version>/kernel/sound/isa/snd-sscape.ko
drwxr-xr-x root/root lib/modules/<kernel-version>/kernel/sound/isa/wavefront/
-rw-r--r-- root/root lib/modules/<kernel-version>/kernel/sound/isa/wavefront/snd-wavefront.ko
drwxr-xr-x root/root lib/modules/<kernel-version>/kernel/sound/misc/
-rw-r--r-- root/root lib/modules/<kernel-version>/kernel/sound/misc/ac97_bus.ko
drwxr-xr-x root/root lib/modules/<kernel-version>/kernel/sound/pci/
drwxr-xr-x root/root lib/modules/<kernel-version>/kernel/sound/pci/ac97/
-rw-r--r-- root/root lib/modules/<kernel-version>/kernel/sound/pci/ac97/snd-ac97-bus.ko
-rw-r--r-- root/root lib/modules/<kernel-version>/kernel/sound/pci/ac97/snd-ac97-codec.ko
-rw-r--r-- root/root lib/modules/<kernel-version>/kernel/sound/pci/ac97/snd-ak4531-codec.ko
drwxr-xr-x root/root lib/modules/<kernel-version>/kernel/sound/pci/ali5451/
@ -193,6 +195,8 @@ drwxr-xr-x root/root lib/modules/<kernel-version>/kernel/sound/pci/vx222/
-rw-r--r-- root/root lib/modules/<kernel-version>/kernel/sound/pci/vx222/snd-vx222.ko
drwxr-xr-x root/root lib/modules/<kernel-version>/kernel/sound/pci/ymfpci/
-rw-r--r-- root/root lib/modules/<kernel-version>/kernel/sound/pci/ymfpci/snd-ymfpci.ko
drwxr-xr-x root/root lib/modules/<kernel-version>/kernel/sound/soc/
-rw-r--r-- root/root lib/modules/<kernel-version>/kernel/sound/soc/snd-soc-core.ko
drwxr-xr-x root/root lib/modules/<kernel-version>/kernel/sound/synth/
drwxr-xr-x root/root lib/modules/<kernel-version>/kernel/sound/synth/emux/
-rw-r--r-- root/root lib/modules/<kernel-version>/kernel/sound/synth/emux/snd-emux-synth.ko
@ -254,6 +258,7 @@ drwxr-xr-x root/root usr/include/sound/
-rw-r--r-- root/root usr/include/sound/pcm.h
-rw-r--r-- root/root usr/include/sound/pcm_oss.h
-rw-r--r-- root/root usr/include/sound/pcm_params.h
-rw-r--r-- root/root usr/include/sound/pt2258.h
-rw-r--r-- root/root usr/include/sound/rawmidi.h
-rw-r--r-- root/root usr/include/sound/sb.h
-rw-r--r-- root/root usr/include/sound/sb16_csp.h
@ -267,6 +272,8 @@ drwxr-xr-x root/root usr/include/sound/
-rw-r--r-- root/root usr/include/sound/seq_virmidi.h
-rw-r--r-- root/root usr/include/sound/sfnt_info.h
-rw-r--r-- root/root usr/include/sound/snd_wavefront.h
-rw-r--r-- root/root usr/include/sound/soc-dapm.h
-rw-r--r-- root/root usr/include/sound/soc.h
-rw-r--r-- root/root usr/include/sound/soundfont.h
-rw-r--r-- root/root usr/include/sound/sscape_ioctl.h
-rw-r--r-- root/root usr/include/sound/tea575x-tuner.h
@ -274,7 +281,6 @@ drwxr-xr-x root/root usr/include/sound/
-rw-r--r-- root/root usr/include/sound/timer.h
-rw-r--r-- root/root usr/include/sound/tlv.h
-rw-r--r-- root/root usr/include/sound/trident.h
-rw-r--r-- root/root usr/include/sound/typedefs.h
-rw-r--r-- root/root usr/include/sound/uda1341.h
-rw-r--r-- root/root usr/include/sound/util_mem.h
-rw-r--r-- root/root usr/include/sound/version.h

View File

@ -1 +1 @@
3fe79d8fd475a442b59d4716f7bb20a5 alsa-driver-1.0.13.tar.bz2
b1d0d43a05ea5c2f7d06a9c5a471a4a1 alsa-driver-1.0.14rc2.tar.bz2

View File

@ -3,9 +3,9 @@
# Maintainer: Matt Housh, jaeger at morpheus dot net
name=alsa-driver
version=1.0.13
version=1.0.14rc2
release=1
source=(ftp://ftp.alsa-project.org/pub/driver/$name-$version.tar.bz2)
source=(http://gentoo.osuosl.org/distfiles/$name-$version.tar.bz2)
build() {

View File

@ -1 +1 @@
d55a9d7d2a79d738a1b7a511cffda4b6 alsa-lib-1.0.13.tar.bz2
7ea3319690672d4bbd5f950947b705b7 alsa-lib-1.0.14rc2.tar.bz2

View File

@ -3,9 +3,9 @@
# Maintainer: Matt Housh, jaeger at morpheus dot net
name=alsa-lib
version=1.0.13
version=1.0.14rc2
release=1
source=(ftp://ftp.alsa-project.org/pub/lib/$name-$version.tar.bz2)
source=(http://gentoo.osuosl.org/distfiles/$name-$version.tar.bz2)
build() {
cd $name-$version

View File

@ -1 +1 @@
dfe4bb5d3217f3ec662b172ce8397cf0 alsa-utils-1.0.13.tar.bz2
7e9f132b34b7773d2a29b0ff14719a49 alsa-utils-1.0.14rc2.tar.bz2

View File

@ -4,9 +4,9 @@
# Depends on: gettext, alsa-lib, dialog
name=alsa-utils
version=1.0.13
version=1.0.14rc2
release=1
source=(ftp://ftp.alsa-project.org/pub/utils/$name-$version.tar.bz2)
source=(http://gentoo.osuosl.org/distfiles/$name-$version.tar.bz2)
build() {
cd $name-$version

View File

@ -1,3 +1,3 @@
1c37d911bc42fb40f0ef5a3f5822b170 dovecot
14e9981e9828a65526b8e683657434d4 dovecot-1.0.rc25.tar.gz
04baf547c684838ce9703845779f04fb dovecot-config.patch
2f6fb150c60a8f9c0bad12c5fb2b1d15 dovecot-1.0.rc26.tar.gz
66ba2a6d25ed70dbfe251a79d15758e0 dovecot-config.patch

View File

@ -4,7 +4,7 @@
# Depends on: openssl
name=dovecot
version=1.0.rc25
version=1.0.rc26
release=1
source=(http://dovecot.org/releases/$name-$version.tar.gz \
dovecot-config.patch dovecot)

View File

@ -1,6 +1,6 @@
diff -Nru dovecot-1.0.rc23.orig/dovecot-example.conf dovecot-1.0.rc23/dovecot-example.conf
--- dovecot-1.0.rc23.orig/dovecot-example.conf 2007-02-20 16:19:23.000000000 +0100
+++ dovecot-1.0.rc23/dovecot-example.conf 2007-02-20 16:22:00.000000000 +0100
diff -Nru dovecot-1.0.rc26.orig/dovecot-example.conf dovecot-1.0.rc26/dovecot-example.conf
--- dovecot-1.0.rc26.orig/dovecot-example.conf 2007-03-07 07:10:26.000000000 +0100
+++ dovecot-1.0.rc26/dovecot-example.conf 2007-03-07 07:10:39.000000000 +0100
@@ -13,11 +13,11 @@
# --with-ssldir=/etc/ssl
@ -75,7 +75,7 @@ diff -Nru dovecot-1.0.rc23.orig/dovecot-example.conf dovecot-1.0.rc23/dovecot-ex
#last_valid_gid = 0
# Maximum number of running mail processes. When this limit is reached,
@@ -487,19 +487,19 @@
@@ -489,19 +489,19 @@
protocol imap {
# Login executable location.
@ -99,7 +99,7 @@ diff -Nru dovecot-1.0.rc23.orig/dovecot-example.conf dovecot-1.0.rc23/dovecot-ex
# Maximum IMAP command line length in bytes. Some clients generate very long
# command lines with huge mailboxes, so you may need to raise this if you get
@@ -552,11 +552,11 @@
@@ -554,11 +554,11 @@
protocol pop3 {
# Login executable location.
@ -113,7 +113,7 @@ diff -Nru dovecot-1.0.rc23.orig/dovecot-example.conf dovecot-1.0.rc23/dovecot-ex
# Don't try to set mails non-recent or seen with POP3 sessions. This is
# mostly intended to reduce disk I/O. With maildir it doesn't move files
@@ -601,7 +601,7 @@
@@ -603,7 +603,7 @@
# installations. %08Xu%08Xv will be the new default, so use it for new
# installations.
#
@ -122,7 +122,7 @@ diff -Nru dovecot-1.0.rc23.orig/dovecot-example.conf dovecot-1.0.rc23/dovecot-ex
# POP3 logout format string:
# %t - number of TOP commands
@@ -647,7 +647,7 @@
@@ -649,7 +649,7 @@
#mail_plugin_dir = /usr/lib/dovecot/lda
# Binary to use for sending mails.
@ -131,7 +131,7 @@ diff -Nru dovecot-1.0.rc23.orig/dovecot-example.conf dovecot-1.0.rc23/dovecot-ex
# UNIX socket path to master authentication server to find users.
#auth_socket_path = /var/run/dovecot/auth-master
@@ -658,7 +658,7 @@
@@ -660,7 +660,7 @@
##
# Executable location
@ -140,7 +140,7 @@ diff -Nru dovecot-1.0.rc23.orig/dovecot-example.conf dovecot-1.0.rc23/dovecot-ex
# Set max. process size in megabytes.
#auth_process_size = 256
@@ -772,7 +772,7 @@
@@ -774,7 +774,7 @@
# REMEMBER: You'll need /etc/pam.d/dovecot file created for PAM
# authentication to actually work.
# http://wiki.dovecot.org/PasswordDatabase/PAM
@ -149,7 +149,7 @@ diff -Nru dovecot-1.0.rc23.orig/dovecot-example.conf dovecot-1.0.rc23/dovecot-ex
# [blocking=yes] [session=yes] [setcred=yes]
# [cache_key=<key>] [<service name>]
#
@@ -805,7 +805,7 @@
@@ -807,7 +807,7 @@
# args = session=yes *
# args = cache_key=%u dovecot
#args = dovecot
@ -158,7 +158,7 @@ diff -Nru dovecot-1.0.rc23.orig/dovecot-example.conf dovecot-1.0.rc23/dovecot-ex
# /etc/passwd or similar, using getpwnam()
# In many systems nowadays this uses Name Service Switch, which is
@@ -820,8 +820,8 @@
@@ -822,8 +822,8 @@
# /etc/shadow or similiar, using getspnam(). Deprecated by PAM nowadays.
# http://wiki.dovecot.org/PasswordDatabase/Shadow

View File

@ -1 +1 @@
6e49ad34c9a6242fbc25900a79932d4f gl-select
70d02d5a850489d2a9ce0c95b8bb6477 gl-select

View File

@ -6,11 +6,11 @@
# Jose V Beneyto, joberui at ei dot upv dot es
#
##### CHANGELOG #####
Feb 20, 2007 - version 1.1
changelog was not kept prior to this date
added abstractions and ati support contributed by Jose V Beneyto (sepen)
#####################
##### CHANGELOG ##############################################################
# Feb 20, 2007 - version 1.1
# changelog was not kept prior to this date
# added abstractions and ati support contributed by Jose V Beneyto (sepen)
##############################################################################
infoUsage() {
echo "Usage: $0 [x11|nvidia|ati]"

View File

@ -1,3 +1,4 @@
18c05d88e22c3b815a43ca8d7152ccdc MPlayer-1.0rc1.tar.bz2
f0b71c38b1207c1d604be091876ac051 asmrules_fix_20061231.diff
1ecd31d17b51f16332b1fcc7da36b312 font-arial-iso-8859-1.tar.bz2
c64631601912913f3e5dfbecc3b79d44 mplayer.conf

View File

@ -11,14 +11,18 @@
name=mplayer
version=1.0rc1
release=1
release=2
source=(http://www1.mplayerhq.hu/MPlayer/releases/MPlayer-$version.tar.bz2 \
http://www1.mplayerhq.hu/MPlayer/patches/asmrules_fix_20061231.diff \
http://www1.mplayerhq.hu/MPlayer/releases/fonts/font-arial-iso-8859-1.tar.bz2 \
mplayer.conf)
build() {
cd MPlayer-$version
# fix for asmrp buffer overflow
patch -p0 -i $SRC/asmrules_fix_20061231.diff
# mplayer decides optimizations at configure time, don't use CRUX's
unset CFLAGS
./configure --prefix=/usr \

View File

@ -1,3 +1,3 @@
be543b65525f544386a2d8395ea19cdf aliases
a3ce7f2e5d8a6f688571bb55b792b848 postfix-2.3.7.tar.gz
a6c560657788fc7a5444fa9ea32f5513 postfix-2.3.8.tar.gz
d18be5c17604f9c712a28339ff0f61cb postfix.rc

View File

@ -5,7 +5,7 @@
# Depends on: cyrus-sasl, openssl, db
name=postfix
version=2.3.7
version=2.3.8
release=1
source=(ftp://ftp.porcupine.org/mirrors/postfix-release/official/$name-$version.tar.gz
aliases postfix.rc)

View File

@ -1 +1 @@
ec3625130168176257f4239ece2508ae socat-1.5.0.0.tar.gz
1c223880febe6d55703739a1c0fea27d socat-1.6.0.0.tar.gz

View File

@ -4,7 +4,7 @@
# Depends on: ncurses, openssl, readline
name=socat
version=1.5.0.0
version=1.6.0.0
release=1
source=(http://www.dest-unreach.org/socat/download/$name-$version.tar.gz)

View File

@ -759,6 +759,7 @@ drwxr-xr-x root/root usr/lib/wine/
-rwxr-xr-x root/root usr/lib/wine/rsaenh.dll.so
-rwxr-xr-x root/root usr/lib/wine/rundll32.exe.so
-rwxr-xr-x root/root usr/lib/wine/sane.ds.so
-rwxr-xr-x root/root usr/lib/wine/schannel.dll.so
-rwxr-xr-x root/root usr/lib/wine/secur32.dll.so
-rwxr-xr-x root/root usr/lib/wine/security.dll.so
-rwxr-xr-x root/root usr/lib/wine/sensapi.dll.so
@ -840,6 +841,7 @@ drwxr-xr-x root/root usr/lib/wine/
-rwxr-xr-x root/root usr/lib/wine/winevdm.exe.so
-rwxr-xr-x root/root usr/lib/wine/winex11.drv.so
-rw-r--r-- root/root usr/lib/wine/wing.dll16
-rwxr-xr-x root/root usr/lib/wine/wing32.dll.so
-rwxr-xr-x root/root usr/lib/wine/winhelp.exe.so
-rwxr-xr-x root/root usr/lib/wine/wininet.dll.so
-rwxr-xr-x root/root usr/lib/wine/winmm.dll.so

View File

@ -1 +1 @@
ec1aef4cbcbb9596cd79f43deb10dd65 wine-0.9.31.tar.bz2
f9ae61fee02e0b3e72f9aad093a7096c wine-0.9.32.tar.bz2

View File

@ -5,7 +5,7 @@
# Depends on: fontforge
name=wine
version=0.9.31
version=0.9.32
release=1
source=(http://dl.sourceforge.net/sourceforge/$name/wine-$version.tar.bz2)

View File

@ -1,3 +1 @@
6acd0925240e9b7e7f917cd6cf28ab61 xpdf-3.01-noftinternals.patch
e004c69c7dddef165d768b1362b44268 xpdf-3.01.tar.gz
8f1f5d37153c7e98f794f18d0b80fc25 xpdf-3.01pl2.patch
599dc4cc65a07ee868cf92a667a913d2 xpdf-3.02.tar.gz

View File

@ -5,17 +5,12 @@
# Depends on: lesstif, t1lib
name=xpdf
version=3.01pl2
release=2
source=(ftp://ftp.foolabs.com/pub/xpdf/$name-3.01.tar.gz \
$name-$version.patch
$name-3.01-noftinternals.patch)
version=3.02
release=1
source=(ftp://ftp.foolabs.com/pub/xpdf/$name-$version.tar.gz)
build()
{
cd $name-3.01
patch -p1 < ../$name-$version.patch
patch -p1 < ../$name-3.01-noftinternals.patch
build() {
cd $name-$version
./configure \
--prefix=/usr \
--with-Xm-library=/usr/lib \

View File

@ -1,78 +0,0 @@
diff -urN xpdf-3.01-org/splash/SplashFTFont.cc xpdf-3.01/splash/SplashFTFont.cc
--- xpdf-3.01-org/splash/SplashFTFont.cc 2005-12-23 16:57:18.076514614 +0100
+++ xpdf-3.01/splash/SplashFTFont.cc 2005-12-23 17:33:42.731318339 +0100
@@ -14,7 +14,8 @@
#include <ft2build.h>
#include FT_OUTLINE_H
-#include FT_INTERNAL_OBJECTS_H // needed for FT_New_Size decl
+#include FT_SIZES_H // needed for FT_New_Size decl
+#include FT_GLYPH_H
#include "gmem.h"
#include "SplashMath.h"
#include "SplashGlyphBitmap.h"
@@ -25,11 +26,12 @@
//------------------------------------------------------------------------
-static int glyphPathMoveTo(FT_Vector *pt, void *path);
-static int glyphPathLineTo(FT_Vector *pt, void *path);
-static int glyphPathConicTo(FT_Vector *ctrl, FT_Vector *pt, void *path);
-static int glyphPathCubicTo(FT_Vector *ctrl1, FT_Vector *ctrl2,
- FT_Vector *pt, void *path);
+static int glyphPathMoveTo( const FT_Vector *pt, void *path);
+static int glyphPathLineTo( const FT_Vector *pt, void *path);
+static int glyphPathConicTo( const FT_Vector *ctrl, const FT_Vector *pt,
+ void* path );
+static int glyphPathCubicTo( const FT_Vector *ctrl1, const FT_Vector *ctrl2,
+ const FT_Vector *pt, void *path);
//------------------------------------------------------------------------
// SplashFTFont
@@ -210,7 +212,7 @@
};
SplashPath *SplashFTFont::getGlyphPath(int c) {
- static FT_Outline_Funcs outlineFuncs = {
+ static const FT_Outline_Funcs outlineFuncs = {
&glyphPathMoveTo,
&glyphPathLineTo,
&glyphPathConicTo,
@@ -249,7 +251,7 @@
return path.path;
}
-static int glyphPathMoveTo(FT_Vector *pt, void *path) {
+static int glyphPathMoveTo( const FT_Vector *pt, void *path) {
SplashFTFontPath *p = (SplashFTFontPath *)path;
if (p->needClose) {
@@ -260,7 +262,7 @@
return 0;
}
-static int glyphPathLineTo(FT_Vector *pt, void *path) {
+static int glyphPathLineTo(const FT_Vector *pt, void *path) {
SplashFTFontPath *p = (SplashFTFontPath *)path;
p->path->lineTo(pt->x / 64.0, -pt->y / 64.0);
@@ -268,7 +270,7 @@
return 0;
}
-static int glyphPathConicTo(FT_Vector *ctrl, FT_Vector *pt, void *path) {
+static int glyphPathConicTo(const FT_Vector *ctrl, const FT_Vector *pt, void *path) {
SplashFTFontPath *p = (SplashFTFontPath *)path;
SplashCoord x0, y0, x1, y1, x2, y2, x3, y3, xc, yc;
@@ -306,8 +308,8 @@
return 0;
}
-static int glyphPathCubicTo(FT_Vector *ctrl1, FT_Vector *ctrl2,
- FT_Vector *pt, void *path) {
+static int glyphPathCubicTo(const FT_Vector *ctrl1, const FT_Vector *ctrl2,
+ const FT_Vector *pt, void *path) {
SplashFTFontPath *p = (SplashFTFontPath *)path;
p->path->curveTo(ctrl1->x / 64.0, -ctrl1->y / 64.0,

View File

@ -1,471 +0,0 @@
diff -cr xpdf-3.01.orig/goo/gmem.c xpdf-3.01/goo/gmem.c
*** xpdf-3.01.orig/goo/gmem.c Tue Aug 16 22:34:30 2005
--- xpdf-3.01/goo/gmem.c Tue Jan 17 17:03:57 2006
***************
*** 11,16 ****
--- 11,17 ----
#include <stdlib.h>
#include <stddef.h>
#include <string.h>
+ #include <limits.h>
#include "gmem.h"
#ifdef DEBUG_MEM
***************
*** 63,69 ****
int lst;
unsigned long *trl, *p;
! if (size == 0)
return NULL;
size1 = gMemDataSize(size);
if (!(mem = (char *)malloc(size1 + gMemHdrSize + gMemTrlSize))) {
--- 64,70 ----
int lst;
unsigned long *trl, *p;
! if (size <= 0)
return NULL;
size1 = gMemDataSize(size);
if (!(mem = (char *)malloc(size1 + gMemHdrSize + gMemTrlSize))) {
***************
*** 86,92 ****
#else
void *p;
! if (size == 0)
return NULL;
if (!(p = malloc(size))) {
fprintf(stderr, "Out of memory\n");
--- 87,93 ----
#else
void *p;
! if (size <= 0)
return NULL;
if (!(p = malloc(size))) {
fprintf(stderr, "Out of memory\n");
***************
*** 102,108 ****
void *q;
int oldSize;
! if (size == 0) {
if (p)
gfree(p);
return NULL;
--- 103,109 ----
void *q;
int oldSize;
! if (size <= 0) {
if (p)
gfree(p);
return NULL;
***************
*** 120,126 ****
#else
void *q;
! if (size == 0) {
if (p)
free(p);
return NULL;
--- 121,127 ----
#else
void *q;
! if (size <= 0) {
if (p)
free(p);
return NULL;
***************
*** 140,147 ****
void *gmallocn(int nObjs, int objSize) {
int n;
n = nObjs * objSize;
! if (objSize == 0 || n / objSize != nObjs) {
fprintf(stderr, "Bogus memory allocation size\n");
exit(1);
}
--- 141,151 ----
void *gmallocn(int nObjs, int objSize) {
int n;
+ if (nObjs == 0) {
+ return NULL;
+ }
n = nObjs * objSize;
! if (objSize <= 0 || nObjs < 0 || nObjs >= INT_MAX / objSize) {
fprintf(stderr, "Bogus memory allocation size\n");
exit(1);
}
***************
*** 151,158 ****
void *greallocn(void *p, int nObjs, int objSize) {
int n;
n = nObjs * objSize;
! if (objSize == 0 || n / objSize != nObjs) {
fprintf(stderr, "Bogus memory allocation size\n");
exit(1);
}
--- 155,168 ----
void *greallocn(void *p, int nObjs, int objSize) {
int n;
+ if (nObjs == 0) {
+ if (p) {
+ gfree(p);
+ }
+ return NULL;
+ }
n = nObjs * objSize;
! if (objSize <= 0 || nObjs < 0 || nObjs >= INT_MAX / objSize) {
fprintf(stderr, "Bogus memory allocation size\n");
exit(1);
}
diff -cr xpdf-3.01.orig/xpdf/JBIG2Stream.cc xpdf-3.01/xpdf/JBIG2Stream.cc
*** xpdf-3.01.orig/xpdf/JBIG2Stream.cc Tue Aug 16 22:34:31 2005
--- xpdf-3.01/xpdf/JBIG2Stream.cc Tue Jan 17 17:29:46 2006
***************
*** 13,18 ****
--- 13,19 ----
#endif
#include <stdlib.h>
+ #include <limits.h>
#include "GList.h"
#include "Error.h"
#include "JArithmeticDecoder.h"
***************
*** 681,686 ****
--- 682,691 ----
w = wA;
h = hA;
line = (wA + 7) >> 3;
+ if (w <= 0 || h <= 0 || line <= 0 || h >= (INT_MAX - 1) / line) {
+ data = NULL;
+ return;
+ }
// need to allocate one extra guard byte for use in combine()
data = (Guchar *)gmalloc(h * line + 1);
data[h * line] = 0;
***************
*** 692,697 ****
--- 697,706 ----
w = bitmap->w;
h = bitmap->h;
line = bitmap->line;
+ if (w <= 0 || h <= 0 || line <= 0 || h >= (INT_MAX - 1) / line) {
+ data = NULL;
+ return;
+ }
// need to allocate one extra guard byte for use in combine()
data = (Guchar *)gmalloc(h * line + 1);
memcpy(data, bitmap->data, h * line);
***************
*** 720,726 ****
}
void JBIG2Bitmap::expand(int newH, Guint pixel) {
! if (newH <= h) {
return;
}
// need to allocate one extra guard byte for use in combine()
--- 729,735 ----
}
void JBIG2Bitmap::expand(int newH, Guint pixel) {
! if (newH <= h || line <= 0 || newH >= (INT_MAX - 1) / line) {
return;
}
// need to allocate one extra guard byte for use in combine()
***************
*** 2294,2299 ****
--- 2303,2316 ----
!readUWord(&stepX) || !readUWord(&stepY)) {
goto eofError;
}
+ if (w == 0 || h == 0 || w >= INT_MAX / h) {
+ error(getPos(), "Bad bitmap size in JBIG2 halftone segment");
+ return;
+ }
+ if (gridH == 0 || gridW >= INT_MAX / gridH) {
+ error(getPos(), "Bad grid size in JBIG2 halftone segment");
+ return;
+ }
// get pattern dictionary
if (nRefSegs != 1) {
diff -cr xpdf-3.01.orig/xpdf/JPXStream.cc xpdf-3.01/xpdf/JPXStream.cc
*** xpdf-3.01.orig/xpdf/JPXStream.cc Tue Aug 16 22:34:31 2005
--- xpdf-3.01/xpdf/JPXStream.cc Tue Jan 17 17:14:06 2006
***************
*** 12,17 ****
--- 12,18 ----
#pragma implementation
#endif
+ #include <limits.h>
#include "gmem.h"
#include "Error.h"
#include "JArithmeticDecoder.h"
***************
*** 818,823 ****
--- 819,830 ----
/ img.xTileSize;
img.nYTiles = (img.ySize - img.yTileOffset + img.yTileSize - 1)
/ img.yTileSize;
+ // check for overflow before allocating memory
+ if (img.nXTiles <= 0 || img.nYTiles <= 0 ||
+ img.nXTiles >= INT_MAX / img.nYTiles) {
+ error(getPos(), "Bad tile count in JPX SIZ marker segment");
+ return gFalse;
+ }
img.tiles = (JPXTile *)gmallocn(img.nXTiles * img.nYTiles,
sizeof(JPXTile));
for (i = 0; i < img.nXTiles * img.nYTiles; ++i) {
diff -cr xpdf-3.01.orig/xpdf/Stream.cc xpdf-3.01/xpdf/Stream.cc
*** xpdf-3.01.orig/xpdf/Stream.cc Tue Aug 16 22:34:31 2005
--- xpdf-3.01/xpdf/Stream.cc Tue Jan 17 17:31:52 2006
***************
*** 15,20 ****
--- 15,21 ----
#include <stdio.h>
#include <stdlib.h>
#include <stddef.h>
+ #include <limits.h>
#ifndef WIN32
#include <unistd.h>
#endif
***************
*** 406,418 ****
--- 407,432 ----
width = widthA;
nComps = nCompsA;
nBits = nBitsA;
+ predLine = NULL;
+ ok = gFalse;
nVals = width * nComps;
+ if (width <= 0 || nComps <= 0 || nBits <= 0 ||
+ nComps >= INT_MAX / nBits ||
+ width >= INT_MAX / nComps / nBits ||
+ nVals * nBits + 7 < 0) {
+ return;
+ }
pixBytes = (nComps * nBits + 7) >> 3;
rowBytes = ((nVals * nBits + 7) >> 3) + pixBytes;
+ if (rowBytes <= 0) {
+ return;
+ }
predLine = (Guchar *)gmalloc(rowBytes);
memset(predLine, 0, rowBytes);
predIdx = rowBytes;
+
+ ok = gTrue;
}
StreamPredictor::~StreamPredictor() {
***************
*** 1004,1009 ****
--- 1018,1027 ----
FilterStream(strA) {
if (predictor != 1) {
pred = new StreamPredictor(this, predictor, columns, colors, bits);
+ if (!pred->isOk()) {
+ delete pred;
+ pred = NULL;
+ }
} else {
pred = NULL;
}
***************
*** 1259,1264 ****
--- 1277,1285 ----
if (columns < 1) {
columns = 1;
}
+ if (columns + 4 <= 0) {
+ columns = INT_MAX - 4;
+ }
rows = rowsA;
endOfBlock = endOfBlockA;
black = blackA;
***************
*** 2899,2904 ****
--- 2920,2930 ----
height = read16();
width = read16();
numComps = str->getChar();
+ if (numComps <= 0 || numComps > 4) {
+ error(getPos(), "Bad number of components in DCT stream");
+ numComps = 0;
+ return gFalse;
+ }
if (prec != 8) {
error(getPos(), "Bad DCT precision %d", prec);
return gFalse;
***************
*** 2925,2930 ****
--- 2951,2961 ----
height = read16();
width = read16();
numComps = str->getChar();
+ if (numComps <= 0 || numComps > 4) {
+ error(getPos(), "Bad number of components in DCT stream");
+ numComps = 0;
+ return gFalse;
+ }
if (prec != 8) {
error(getPos(), "Bad DCT precision %d", prec);
return gFalse;
***************
*** 2947,2952 ****
--- 2978,2988 ----
length = read16() - 2;
scanInfo.numComps = str->getChar();
+ if (scanInfo.numComps <= 0 || scanInfo.numComps > 4) {
+ error(getPos(), "Bad number of components in DCT stream");
+ scanInfo.numComps = 0;
+ return gFalse;
+ }
--length;
if (length != 2 * scanInfo.numComps + 3) {
error(getPos(), "Bad DCT scan info block");
***************
*** 3041,3046 ****
--- 3077,3083 ----
numACHuffTables = index+1;
tbl = &acHuffTables[index];
} else {
+ index &= 0x0f;
if (index >= numDCHuffTables)
numDCHuffTables = index+1;
tbl = &dcHuffTables[index];
***************
*** 3827,3832 ****
--- 3864,3873 ----
FilterStream(strA) {
if (predictor != 1) {
pred = new StreamPredictor(this, predictor, columns, colors, bits);
+ if (!pred->isOk()) {
+ delete pred;
+ pred = NULL;
+ }
} else {
pred = NULL;
}
diff -cr xpdf-3.01.orig/xpdf/Stream.h xpdf-3.01/xpdf/Stream.h
*** xpdf-3.01.orig/xpdf/Stream.h Tue Aug 16 22:34:31 2005
--- xpdf-3.01/xpdf/Stream.h Tue Jan 17 17:19:54 2006
***************
*** 232,237 ****
--- 232,239 ----
~StreamPredictor();
+ GBool isOk() { return ok; }
+
int lookChar();
int getChar();
***************
*** 249,254 ****
--- 251,257 ----
int rowBytes; // bytes per line
Guchar *predLine; // line buffer
int predIdx; // current index in predLine
+ GBool ok;
};
//------------------------------------------------------------------------
***************
*** 527,533 ****
short getWhiteCode();
short getBlackCode();
short lookBits(int n);
! void eatBits(int n) { inputBits -= n; }
};
//------------------------------------------------------------------------
--- 530,536 ----
short getWhiteCode();
short getBlackCode();
short lookBits(int n);
! void eatBits(int n) { if ((inputBits -= n) < 0) inputBits = 0; }
};
//------------------------------------------------------------------------
diff -cr xpdf-3.01.orig/splash/SplashXPathScanner.cc xpdf-3.01/splash/SplashXPathScanner.cc
*** xpdf-3.01.orig/splash/SplashXPathScanner.cc Tue Aug 16 22:34:31 2005
--- xpdf-3.01/splash/SplashXPathScanner.cc Wed Feb 1 17:01:14 2006
***************
*** 186,192 ****
}
void SplashXPathScanner::computeIntersections(int y) {
! SplashCoord ySegMin, ySegMax, xx0, xx1;
SplashXPathSeg *seg;
int i, j;
--- 186,192 ----
}
void SplashXPathScanner::computeIntersections(int y) {
! SplashCoord xSegMin, xSegMax, ySegMin, ySegMax, xx0, xx1;
SplashXPathSeg *seg;
int i, j;
***************
*** 236,254 ****
} else if (seg->flags & splashXPathVert) {
xx0 = xx1 = seg->x0;
} else {
! if (ySegMin <= y) {
! // intersection with top edge
! xx0 = seg->x0 + ((SplashCoord)y - seg->y0) * seg->dxdy;
} else {
! // x coord of segment endpoint with min y coord
! xx0 = (seg->flags & splashXPathFlip) ? seg->x1 : seg->x0;
}
! if (ySegMax >= y + 1) {
! // intersection with bottom edge
! xx1 = seg->x0 + ((SplashCoord)y + 1 - seg->y0) * seg->dxdy;
! } else {
! // x coord of segment endpoint with max y coord
! xx1 = (seg->flags & splashXPathFlip) ? seg->x0 : seg->x1;
}
}
if (xx0 < xx1) {
--- 236,262 ----
} else if (seg->flags & splashXPathVert) {
xx0 = xx1 = seg->x0;
} else {
! if (seg->x0 < seg->x1) {
! xSegMin = seg->x0;
! xSegMax = seg->x1;
} else {
! xSegMin = seg->x1;
! xSegMax = seg->x0;
}
! // intersection with top edge
! xx0 = seg->x0 + ((SplashCoord)y - seg->y0) * seg->dxdy;
! // intersection with bottom edge
! xx1 = seg->x0 + ((SplashCoord)y + 1 - seg->y0) * seg->dxdy;
! // the segment may not actually extend to the top and/or bottom edges
! if (xx0 < xSegMin) {
! xx0 = xSegMin;
! } else if (xx0 > xSegMax) {
! xx0 = xSegMax;
! }
! if (xx1 < xSegMin) {
! xx1 = xSegMin;
! } else if (xx1 > xSegMax) {
! xx1 = xSegMax;
}
}
if (xx0 < xx1) {