diff options
author | Michael Januszewski <spock@gentoo.org> | 2004-07-12 13:30:46 +0000 |
---|---|---|
committer | Michael Januszewski <spock@gentoo.org> | 2004-07-12 13:30:46 +0000 |
commit | 804fa74944df0c0db7a858d9e260de5726f15d37 (patch) | |
tree | 8fa1715c7f2bcebbf8584f1647b1ae79e76a3fd2 /x11-terms | |
parent | add 0.8.5, mark 0.8.3 x86 (diff) | |
download | historical-804fa74944df0c0db7a858d9e260de5726f15d37.tar.gz historical-804fa74944df0c0db7a858d9e260de5726f15d37.tar.bz2 historical-804fa74944df0c0db7a858d9e260de5726f15d37.zip |
Added a patch to fix saveLines-related crashes.
Diffstat (limited to 'x11-terms')
-rw-r--r-- | x11-terms/aterm/ChangeLog | 10 | ||||
-rw-r--r-- | x11-terms/aterm/Manifest | 5 | ||||
-rw-r--r-- | x11-terms/aterm/aterm-0.4.2-r10.ebuild | 88 | ||||
-rw-r--r-- | x11-terms/aterm/files/aterm-0.4.2-savelines.patch | 121 | ||||
-rw-r--r-- | x11-terms/aterm/files/digest-aterm-0.4.2-r10 | 2 |
5 files changed, 224 insertions, 2 deletions
diff --git a/x11-terms/aterm/ChangeLog b/x11-terms/aterm/ChangeLog index b722d24b759c..91f95d2bb696 100644 --- a/x11-terms/aterm/ChangeLog +++ b/x11-terms/aterm/ChangeLog @@ -1,6 +1,14 @@ # ChangeLog for x11-terms/aterm # Copyright 2002-2004 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/x11-terms/aterm/ChangeLog,v 1.34 2004/07/03 12:08:49 spock Exp $ +# $Header: /var/cvsroot/gentoo-x86/x11-terms/aterm/ChangeLog,v 1.35 2004/07/12 13:30:46 spock Exp $ + +*aterm-0.4.2-r10 (12 Jul 2004) + + 12 Jul 2004; Michal Januszewski <spock@gentoo.org> + +files/aterm-0.4.2-savelines.patch, +aterm-0.4.2-r10.ebuild: + Added a patch to make aterm accept saveLines values > 32767 (and <= 65535). + This fixes the crashes people were getting when they had their saveLines set + to a value close to the boundary (32676) and closes bug #56506. 03 Jul 2004; Michal Januszewski <spock@gentoo.org> aterm-0.4.2-r9.ebuild: Stable on x86 diff --git a/x11-terms/aterm/Manifest b/x11-terms/aterm/Manifest index 36eb31aa9b0f..6351523da2f0 100644 --- a/x11-terms/aterm/Manifest +++ b/x11-terms/aterm/Manifest @@ -1,8 +1,9 @@ MD5 94afa6d1796000410eb4e041bdfbe587 aterm-0.4.2-r6.ebuild 1738 MD5 0074e8fa3d2d91f2136f53b31625ce80 aterm-0.4.2-r8.ebuild 2077 MD5 afe0fc08df362a634be9e9e9ca4d20cb aterm-0.4.2-r5.ebuild 1693 +MD5 3c7266b6da456776620ec0326542f239 aterm-0.4.2-r10.ebuild 2209 MD5 63102af3b03f129145c4923b3db98ba7 aterm-0.4.2-r7.ebuild 1871 -MD5 770267f895e56bd8fe4180397f450e05 ChangeLog 5842 +MD5 5321c27c04b169a4336ad8e9ab279f82 ChangeLog 6214 MD5 57b7e119c37945e22e782b71e303af12 aterm-0.4.2-r9.ebuild 2158 MD5 d94d306da3804e41296e1bf04c7c9cae metadata.xml 255 MD5 477341401a10ec6b77eb225f4702ae2e aterm-0.4.2-r4.ebuild 1635 @@ -13,6 +14,7 @@ MD5 4f1a0f3cc352be6439ac5810085e1be0 files/digest-aterm-0.4.2-r6 128 MD5 4f1a0f3cc352be6439ac5810085e1be0 files/digest-aterm-0.4.2-r7 128 MD5 4f1a0f3cc352be6439ac5810085e1be0 files/digest-aterm-0.4.2-r8 128 MD5 4f1a0f3cc352be6439ac5810085e1be0 files/digest-aterm-0.4.2-r9 128 +MD5 4f1a0f3cc352be6439ac5810085e1be0 files/digest-aterm-0.4.2-r10 128 MD5 1ddbe9b625c32cb9e67d8ee23af57110 files/aterm-0.4.2-patch-pack000.patch 4124 MD5 df2652026f1f4f3e4444db9cddc145b6 files/aterm-0.4.2-qtpaste.patch 2510 MD5 cc3291cba64add4b46d22268878043f7 files/aterm-0.4.2-copynpaste-r2.patch 5308 @@ -20,3 +22,4 @@ MD5 80558db5a2d61eaaf6998877b616bbd0 files/aterm-0.4.2-copynpaste-r3.patch 6358 MD5 e91e244a20f4bff5ed4238e4cdb4d87a files/aterm-0.4.2-paste_mouse_outside.patch 6267 MD5 1c869d8199dea55badd3758c5967e182 files/aterm-0.4.2-copynpaste.patch 3668 MD5 56383dccdb085d09e33858081b774724 files/aterm-0.4.2-borderless.patch 4692 +MD5 8faf173b6f8032958f1bc48d7877353c files/aterm-0.4.2-savelines.patch 4081 diff --git a/x11-terms/aterm/aterm-0.4.2-r10.ebuild b/x11-terms/aterm/aterm-0.4.2-r10.ebuild new file mode 100644 index 000000000000..552fd84ef85e --- /dev/null +++ b/x11-terms/aterm/aterm-0.4.2-r10.ebuild @@ -0,0 +1,88 @@ +# Copyright 1999-2004 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/x11-terms/aterm/aterm-0.4.2-r10.ebuild,v 1.1 2004/07/12 13:30:46 spock Exp $ + +inherit eutils + +IUSE="cjk" +DESCRIPTION="A terminal emulator with transparency support as well as rxvt backwards compatibility" +SRC_URI="mirror://sourceforge/aterm/${P}.tar.bz2 + cjk? (http://dev.gentoo.org/~spock/portage/distfiles/aterm-0.4.2-ja.patch)" +HOMEPAGE="http://aterm.sourceforge.net" +LICENSE="GPL-2" +SLOT="0" +KEYWORDS="~x86 ~ppc ~sparc ~alpha ~amd64" + +DEPEND="media-libs/jpeg + media-libs/libpng + virtual/x11" + +src_unpack() { + unpack ${P}.tar.bz2 + cd ${S}/src + cp feature.h feature.h.orig + sed "s:\(#define LINUX_KEYS\):/\*\1\*/:" \ + feature.h.orig > feature.h + + sed -i "s: KeySym keysym;: KeySym keysym = 0;:" command.c + + cd ${S} + epatch ${FILESDIR}/aterm-0.4.2-borderless.patch + epatch ${FILESDIR}/aterm-0.4.2-paste.patch + epatch ${FILESDIR}/aterm-0.4.2-paste_mouse_outside.patch + + if use cjk ; then + epatch ${DISTDIR}/aterm-0.4.2-ja.patch + else + epatch ${FILESDIR}/aterm-0.4.2-copynpaste-r3.patch + fi + + epatch ${FILESDIR}/aterm-0.4.2-patch-pack000.patch + epatch ${FILESDIR}/aterm-0.4.2-savelines.patch +} + +src_compile() { + local myconf + + # You can't --enable-big5 with aterm-0.4.2-ja.patch + # I think it's very bad thing but as nobody complains it + # and we don't have per-language flag atm, I stick to + # use --enable-kanji/--enable-thai (and leave --enable-big5) + use cjk && myconf="$myconf + --enable-kanji + --enable-thai + --enable-xim + --enable-linespace" + + econf \ + --enable-transparency \ + --enable-fading \ + --enable-background-image \ + --enable-menubar \ + --enable-graphics \ + --enable-utmp \ + --with-x \ + ${myconf} || die + + emake || die +} + +src_install () { + make DESTDIR=${D} install || die + + fperms g+s /usr/bin/aterm + fowners root:utmp /usr/bin/aterm + + doman doc/aterm.1 + dodoc ChangeLog INSTALL doc/BUGS doc/FAQ doc/README.* + docinto menu + dodoc doc/menu/* + dohtml -r . +} + +pkg_postinst () { + einfo + einfo "Hint: you can copy text from aterm to the clipboard by holding the ALT key" + einfo "while highlighting the text." + einfo +} diff --git a/x11-terms/aterm/files/aterm-0.4.2-savelines.patch b/x11-terms/aterm/files/aterm-0.4.2-savelines.patch new file mode 100644 index 000000000000..adcc76b68b89 --- /dev/null +++ b/x11-terms/aterm/files/aterm-0.4.2-savelines.patch @@ -0,0 +1,121 @@ +diff -Naur aterm-0.4.2/src/main.c aterm-0.4.2-new/src/main.c +--- aterm-0.4.2/src/main.c 2004-07-12 15:16:50.000000000 +0200 ++++ aterm-0.4.2-new/src/main.c 2004-07-12 13:37:52.000000000 +0200 +@@ -1582,6 +1582,7 @@ + int saved_argc = argc; + char **saved_argv = (char **)MALLOC((argc + 1) * sizeof(char *)); + ++ int t; + + PixColors = &(PixColorsFocused[0]); + +@@ -1754,12 +1755,21 @@ + rs_title = rs_name; + if (!rs_iconName) + rs_iconName = rs_title; +- if (!rs_minBufferWidth || (TermWin.min_bcol = atoi(rs_minBufferWidth)) < 0) ++ ++ if (!rs_minBufferWidth || (t = atoi(rs_minBufferWidth)) < 0) + TermWin.min_bcol = 1; +- if (!rs_saveLines || (TermWin.saveLines = atoi(rs_saveLines)) < 0) +- TermWin.saveLines = SAVELINES; +- if (!rs_borderWidth || (TermWin.borderWidth = atoi(rs_borderWidth)) < 0) ++ else ++ TermWin.min_bcol = t; ++ ++ if (!rs_saveLines || (t = atoi(rs_saveLines)) < 0) ++ TermWin.saveLines = SAVELINES; ++ else ++ TermWin.saveLines = t; ++ ++ if (!rs_borderWidth || (t = atoi(rs_borderWidth)) < 0) + TermWin.borderWidth = BORDERWIDTH; ++ else ++ TermWin.borderWidth = t; + + /* no point having a scrollbar without having any scrollback! */ + if (!TermWin.saveLines) +diff -Naur aterm-0.4.2/src/rxvt.h aterm-0.4.2-new/src/rxvt.h +--- aterm-0.4.2/src/rxvt.h 2004-07-12 15:16:50.000000000 +0200 ++++ aterm-0.4.2-new/src/rxvt.h 2004-07-12 12:32:09.000000000 +0200 +@@ -259,7 +259,7 @@ + + + typedef struct { +- R_int16_t width, /* window width [pixels] */ ++ R_u_int16_t width, /* window width [pixels] */ + height, /* window height [pixels] */ + fwidth, /* font width [pixels] */ + fheight, /* font height [pixels] */ +diff -Naur aterm-0.4.2/src/screen.c aterm-0.4.2-new/src/screen.c +--- aterm-0.4.2/src/screen.c 2004-07-12 15:16:50.000000000 +0200 ++++ aterm-0.4.2-new/src/screen.c 2004-07-12 15:20:02.029447392 +0200 +@@ -236,12 +236,13 @@ + + if (TermWin.bcol == prev_bcol && TermWin.nrow == prev_nrow) + return; +- ++#if 0 + #ifdef DEBUG_STRICT + assert(TermWin.saveLines >= 0); + #else /* drive with your eyes closed */ + MAX_IT(TermWin.saveLines, 0); + #endif ++#endif + + total_rows = TermWin.nrow + TermWin.saveLines; + prev_total_rows = prev_nrow + TermWin.saveLines; +@@ -751,7 +752,10 @@ + return 0; + + if ((count > 0) && (row1 == 0) && (current_screen == PRIMARY)) { +- TermWin.nscrolled += count; ++ if (TermWin.saveLines - TermWin.nscrolled < count) ++ TermWin.nscrolled += TermWin.saveLines - TermWin.nscrolled; ++ else ++ TermWin.nscrolled += count; + MIN_IT(TermWin.nscrolled, TermWin.saveLines); + } else if (!spec) + row1 += TermWin.saveLines; +@@ -1865,15 +1869,17 @@ + int + scr_move_to(int y, int len) + { +- int start; ++ int start, t; + + start = TermWin.view_start; +- TermWin.view_start = ((len - y) * (TermWin.nrow - 1 + TermWin.nscrolled) ++ t = ((len - y) * (TermWin.nrow - 1 + TermWin.nscrolled) + / (len)) - (TermWin.nrow - 1); +- D_SCREEN((stderr, "scr_move_to(%d, %d) view_start:%d", y, len, TermWin.view_start)); ++ D_SCREEN((stderr, "scr_move_to(%d, %d) view_start:%d", y, len, t)); + +- MAX_IT(TermWin.view_start, 0); +- MIN_IT(TermWin.view_start, TermWin.nscrolled); ++ MAX_IT(t, 0); ++ MIN_IT(t, TermWin.nscrolled); ++ ++ TermWin.view_start = t; + + if (Gr_Displayed()) + Gr_scroll(0); +@@ -1896,8 +1902,16 @@ + start = TermWin.view_start; + MAX_IT(nlines, 1); + MIN_IT(nlines, TermWin.nrow); +- TermWin.view_start += (nlines * dirn); +- MAX_IT(TermWin.view_start, 0); ++ ++ if ((dirn == -1 && TermWin.view_start < nlines)) ++ TermWin.view_start = 0; ++ else ++ TermWin.view_start += (nlines * dirn); ++ ++ if (dirn == 1 && start > TermWin.view_start) ++ TermWin.view_start = TermWin.nscrolled; ++ ++// MAX_IT(TermWin.view_start, 0); + MIN_IT(TermWin.view_start, TermWin.nscrolled); + + if (Gr_Displayed()) diff --git a/x11-terms/aterm/files/digest-aterm-0.4.2-r10 b/x11-terms/aterm/files/digest-aterm-0.4.2-r10 new file mode 100644 index 000000000000..a1aafd5e085e --- /dev/null +++ b/x11-terms/aterm/files/digest-aterm-0.4.2-r10 @@ -0,0 +1,2 @@ +MD5 5c29d0cde4225bdbd63ccb6a4dd94c56 aterm-0.4.2.tar.bz2 243419 +MD5 2bd8629ea2a1926bca13841b0aca6604 aterm-0.4.2-ja.patch 84282 |