summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPacho Ramos <pacho@gentoo.org>2012-03-04 09:54:46 +0000
committerPacho Ramos <pacho@gentoo.org>2012-03-04 09:54:46 +0000
commit1d1275baf533294abf1f9e1c2b535d24c37da9f8 (patch)
tree073b09cd29f29db7b73fa8150193f90e593b0227 /dev-util
parentAdopt deps to unbundled x11-libs/libGLw situation (diff)
downloadgentoo-2-1d1275baf533294abf1f9e1c2b535d24c37da9f8.tar.gz
gentoo-2-1d1275baf533294abf1f9e1c2b535d24c37da9f8.tar.bz2
gentoo-2-1d1275baf533294abf1f9e1c2b535d24c37da9f8.zip
Prevent crashes, bug #382033 by Nico R. Drop broken version.
(Portage version: 2.1.10.49/cvs/Linux x86_64)
Diffstat (limited to 'dev-util')
-rw-r--r--dev-util/biew/ChangeLog10
-rw-r--r--dev-util/biew/biew-6.1.0-r2.ebuild (renamed from dev-util/biew/biew-6.1.0-r1.ebuild)5
-rw-r--r--dev-util/biew/files/biew-610-crash.patch28
3 files changed, 39 insertions, 4 deletions
diff --git a/dev-util/biew/ChangeLog b/dev-util/biew/ChangeLog
index c1cc1f2dde69..33ed997f564b 100644
--- a/dev-util/biew/ChangeLog
+++ b/dev-util/biew/ChangeLog
@@ -1,6 +1,12 @@
# ChangeLog for dev-util/biew
-# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/dev-util/biew/ChangeLog,v 1.32 2011/12/28 08:08:40 xmw Exp $
+# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/dev-util/biew/ChangeLog,v 1.33 2012/03/04 09:54:46 pacho Exp $
+
+*biew-6.1.0-r2 (04 Mar 2012)
+
+ 04 Mar 2012; Pacho Ramos <pacho@gentoo.org> +biew-6.1.0-r2.ebuild,
+ +files/biew-610-crash.patch, -biew-6.1.0-r1.ebuild:
+ Prevent crashes, bug #382033 by Nico R. Drop broken version.
28 Dec 2011; Michael Weber <xmw@gentoo.org> metadata.xml:
taking maint
diff --git a/dev-util/biew/biew-6.1.0-r1.ebuild b/dev-util/biew/biew-6.1.0-r2.ebuild
index c1be1d2e9c40..7912e6029934 100644
--- a/dev-util/biew/biew-6.1.0-r1.ebuild
+++ b/dev-util/biew/biew-6.1.0-r2.ebuild
@@ -1,6 +1,6 @@
-# Copyright 1999-2011 Gentoo Foundation
+# Copyright 1999-2012 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/dev-util/biew/biew-6.1.0-r1.ebuild,v 1.3 2011/04/05 15:30:44 signals Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-util/biew/biew-6.1.0-r2.ebuild,v 1.1 2012/03/04 09:54:46 pacho Exp $
EAPI=4
inherit eutils flag-o-matic toolchain-funcs versionator
@@ -28,6 +28,7 @@ pkg_setup() {
src_prepare() {
epatch "${FILESDIR}/${PN}-610-fix_localedep-1.patch"
epatch "${FILESDIR}/${PN}-610-portable_configure-1.patch"
+ epatch "${FILESDIR}/${PN}-610-crash.patch"
sed -i -e 's^man/man1/biew.1^share/man/man1/biew.1^' makefile || die "Failed to edit makefile."
}
diff --git a/dev-util/biew/files/biew-610-crash.patch b/dev-util/biew/files/biew-610-crash.patch
new file mode 100644
index 000000000000..244f94a7ad53
--- /dev/null
+++ b/dev-util/biew/files/biew-610-crash.patch
@@ -0,0 +1,28 @@
+If .biewrc does not exist, the setup dialog appears at program start. If you try
+to click a checkbox with the mouse, biew tries to dereference a null pointer
+(because the MainWindow is not yet set).
+
+This patch adds a workaround. Note that you actually cannot click a checkbox.
+But that is what users might expect. (Maybe the biew code should be changed to
+handle this properly.) Well, it is better not to crash, even if the checkboxes
+are not clickable.
+
+ –nico
+
+
+diff -Naur biew-610.orig/events.c biew-610/events.c
+--- biew-610.orig/events.c 2009-09-03 16:57:40.000000000 +0000
++++ biew-610/events.c 2011-09-06 09:41:01.000000000 +0000
+@@ -118,7 +118,11 @@
+ }
+ else
+ {
+- X1 = 0; X2 = twGetClientWidth(MainWnd); Y1 = 1; Y2 = twGetClientHeight(MainWnd) - 1;
++ TWindow *wnd =
++ MainWnd ? MainWnd : /*XXX:drop this line?*/
++ twGetWinAtPos(mx, my);
++ if(!wnd) return KE_MOUSE;
++ X1 = 0; X2 = twGetClientWidth(wnd); Y1 = 1; Y2 = twGetClientHeight(wnd) - 1;
+ }
+ wdh = X2 - X1;
+ hght = Y2 - Y1;