nano

nano with my custom patches
git clone git://bsandro.tech/nano
Log | Files | Refs | README | LICENSE

commit e67bf806bd4d839c94f81e41e241d0404794fa6c
parent ed505f5893808af47c5df23148b940ed96020521
Author: Chris Allegretta <chrisa@asty.org>
Date:   Sat, 31 May 2008 22:23:16 +0000

Fix for segfault when window size is too small by Andreas Amann <andreas.amann@tyndall.ie>



git-svn-id: svn://svn.savannah.gnu.org/nano/trunk/nano@4256 35c25a1d-7b9e-4130-9fde-d3aeb78583b8

Diffstat:
MChangeLog | 4++++
Msrc/nano.c | 2+-
2 files changed, 5 insertions(+), 1 deletion(-)

diff --git a/ChangeLog b/ChangeLog @@ -1,6 +1,10 @@ GNU nano 2.1.1 - 2008.04.01 2008-05-31 Chris Allegretta <chrisa@asty.org> + * Fix for seg fault when window size too small, by + Andreas Amann <andreas.amann@tyndall.ie> + +2008-05-31 Chris Allegretta <chrisa@asty.org> * Added the following contributed files, by owner: Donnie Berkholz <dberkholz@gentoo.org> * Sample awk.nanorc diff --git a/src/nano.c b/src/nano.c @@ -611,7 +611,7 @@ void die(const char *msg, ...) va_end(ap); /* Save the current file buffer if it's been modified. */ - if (openfile->modified) { + if (openfile && openfile->modified) { /* If we've partitioned the filestruct, unpartition it now. */ if (filepart != NULL) unpartition_filestruct(&filepart);