Fixed crash that can occur if term is resized during irssi init

(init-resize-crash-fix patch)
  Resolves: rhbz#796457
This commit is contained in:
Jaroslav Škarvada 2012-02-24 11:20:22 +01:00
parent 71f82182e0
commit ac1ea1677d
2 changed files with 22 additions and 1 deletions

View File

@ -0,0 +1,13 @@
diff -up irssi-0.8.15/src/fe-text/irssi.c.old irssi-0.8.15/src/fe-text/irssi.c
diff -up irssi-0.8.15/src/fe-text/mainwindows.c.old irssi-0.8.15/src/fe-text/mainwindows.c
--- irssi-0.8.15/src/fe-text/mainwindows.c.old 2010-04-03 18:19:42.000000000 +0200
+++ irssi-0.8.15/src/fe-text/mainwindows.c 2012-02-24 10:47:51.215293213 +0100
@@ -355,7 +355,7 @@ static void mainwindows_resize_smaller(i
int space;
sorted = mainwindows_get_sorted(TRUE);
- for (;;) {
+ for (;sorted != NULL;) {
space = 0;
for (tmp = mainwindows; tmp != NULL; tmp = tmp->next) {
rec = tmp->data;

View File

@ -3,13 +3,15 @@
Summary: Modular text mode IRC client with Perl scripting
Name: irssi
Version: 0.8.15
Release: 6%{?dist}
Release: 7%{?dist}
License: GPLv2+
Group: Applications/Communications
URL: http://irssi.org/
Source0: http://irssi.org/files/irssi-%{version}.tar.bz2
Source1: irssi-config.h
# Bug 796457
Patch0: irssi-0.8.15-init-resize-crash-fix.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-buildroot
BuildRequires: ncurses-devel openssl-devel zlib-devel
BuildRequires: pkgconfig glib2-devel perl-devel perl(ExtUtils::Embed)
@ -35,6 +37,7 @@ being maintained.
%prep
%setup -q -n %{name}-%{version}
%patch0 -p1 -b .init-resize-crash-fix
%build
%configure --enable-ipv6 --with-textui \
@ -84,6 +87,11 @@ rm -rf $RPM_BUILD_ROOT
%changelog
* Fri Feb 24 2012 Jaroslav Škarvada <jskarvad@redhat.com> - 0.8.15-7
- Fixed crash that can occur if term is resized during irssi init
(init-resize-crash-fix patch)
Resolves: rhbz#796457
* Mon Jun 20 2011 Marcela Mašláňová <mmaslano@redhat.com> - 0.8.15-6
- Perl mass rebuild