diff options
author | Nicolas Reynolds <fauno@kiwwwi.com.ar> | 2011-05-05 16:07:43 -0300 |
---|---|---|
committer | Nicolas Reynolds <fauno@kiwwwi.com.ar> | 2011-05-05 16:07:43 -0300 |
commit | 3a0008bd8a3e6f4f21181c1fadc17c3da3108907 (patch) | |
tree | 175c9e1755980b2a955b1b9e6b93c1a3d431276f /extra/libxcb | |
parent | 933e5d274b2a4e386565d2f3bb982682e168438b (diff) | |
parent | 2bba02fdaa36de05dffef6a54b57c73259d7db53 (diff) |
Merge branch 'master' of ssh://vparabola/home/parabola/abslibre-pre-mips64el
Conflicts:
community/alienarena/PKGBUILD
community/mumble/PKGBUILD
community/mysql-workbench/PKGBUILD
community/paintown/PKGBUILD
community/ufoai/PKGBUILD
core/dcron/PKGBUILD
core/udev/PKGBUILD
extra/qt/PKGBUILD
extra/texlive-bin/PKGBUILD
testing/opencv/PKGBUILD
testing/pciutils/PKGBUILD
testing/usbutils/PKGBUILD
Diffstat (limited to 'extra/libxcb')
-rw-r--r-- | extra/libxcb/PKGBUILD | 9 | ||||
-rw-r--r-- | extra/libxcb/xcb_auth-fix-memory-leak.patch | 38 |
2 files changed, 44 insertions, 3 deletions
diff --git a/extra/libxcb/PKGBUILD b/extra/libxcb/PKGBUILD index 8ae96209f..9696ea620 100644 --- a/extra/libxcb/PKGBUILD +++ b/extra/libxcb/PKGBUILD @@ -1,10 +1,10 @@ -# $Id: PKGBUILD 101448 2010-11-29 09:38:40Z jgc $ +# $Id: PKGBUILD 122471 2011-05-04 08:36:03Z jgc $ # Maintainer: Jan de Groot <jgc@archlinux.org> # Contributor: Alexander Baldeck <alexander@archlinux.org> pkgname=libxcb pkgver=1.7 -pkgrel=1 +pkgrel=2 pkgdesc="X11 client-side library" arch=(i686 x86_64 'mips64el') url="http://xcb.freedesktop.org/" @@ -14,13 +14,16 @@ conflicts=('libx11<1.1.99.2') options=('!libtool') license=('custom') source=(${url}/dist/${pkgname}-${pkgver}.tar.bz2 + xcb_auth-fix-memory-leak.patch libxcb-1.1-no-pthread-stubs.patch) sha1sums=('7540f0587907bce421914f0ddb813810cb2f36f8' - '3455e84642283bc91c8313af319002a20bbcbdf4') + '0c9246fd2ea270bfa06cb8ef93df2f8227d83c2a' + '3455e84642283bc91c8313af319002a20bbcbdf4') build() { cd "${srcdir}/${pkgname}-${pkgver}" patch -Np1 -i "${srcdir}/libxcb-1.1-no-pthread-stubs.patch" + patch -Np1 -i "${srcdir}/xcb_auth-fix-memory-leak.patch" libtoolize --force --copy aclocal autoconf diff --git a/extra/libxcb/xcb_auth-fix-memory-leak.patch b/extra/libxcb/xcb_auth-fix-memory-leak.patch new file mode 100644 index 000000000..d1000913a --- /dev/null +++ b/extra/libxcb/xcb_auth-fix-memory-leak.patch @@ -0,0 +1,38 @@ +From 5755582444ad0ba79e661ab3173cc38e9e588d83 Mon Sep 17 00:00:00 2001 +From: Nick Bowler <nbowler@draconx.ca> +Date: Thu, 11 Nov 2010 01:49:41 +0000 +Subject: xcb_auth: Fix memory leak in _xcb_get_auth_info. + +If the initial get_peer_sock_name(getpeername ...) succeeds, the +pointer to allocated memory is overwritten by the later call to +get_peer_sock_name(getsockname ...). Fix that up by freeing +the allocated memory before overwriting the pointer. + +Signed-off-by: Nick Bowler <nbowler@draconx.ca> +Signed-off-by: Julien Danjou <julien@danjou.info> +--- +diff --git a/src/xcb_auth.c b/src/xcb_auth.c +index 1af27fc..4839b78 100644 +--- a/src/xcb_auth.c ++++ b/src/xcb_auth.c +@@ -327,10 +327,15 @@ int _xcb_get_auth_info(int fd, xcb_auth_info_t *info, int display) + if (!info->namelen) + goto no_auth; /* out of memory */ + +- if (!gotsockname && (sockname = get_peer_sock_name(getsockname, fd)) == NULL) ++ if (!gotsockname) + { +- free(info->name); +- goto no_auth; /* can only authenticate sockets */ ++ free(sockname); ++ ++ if ((sockname = get_peer_sock_name(getsockname, fd)) == NULL) ++ { ++ free(info->name); ++ goto no_auth; /* can only authenticate sockets */ ++ } + } + + ret = compute_auth(info, authptr, sockname); +-- +cgit v0.8.3-6-g21f6 |