[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Nano-devel] Segfault on justify+cut+cut

From: Josh Diakun
Subject: Re: [Nano-devel] Segfault on justify+cut+cut
Date: Mon, 6 May 2002 04:36:02 -0400

I can confirm the same behaviour on Slackware 8.0 kernel v2.4.18 running nano
1.0.9 but then this bug does not exist when run on FreeBSD 4.0-CURRENT with
the same nano version.

Under Slackware it segfaults, under FreeBSD it works as normal.

On a different note, does the timestamp on this email seem a little whacky?
Also nano-devel has been moved off of sourceforge I do believe and over to

Hope this information helps.


Josh Diakun
ACPO Development Team Member
----- Original Message -----
From: "Derek McKay" <address@hidden>
To: <address@hidden>
Sent: Monday, February 04, 2002 1:49 PM
Subject: [Nano-devel] Segfault on justify+cut+cut

> Hi all,
> I think I may have found a bug in version 1.0.8 (compiled on SuSE Linux
> 7.3). To replicate the fault, create a file with the following lines:
> ------ cut here ------
> aaa aaa aaa aaa aaa aaa
> aaa aaa aaa aaa aaa aaa
> aaa aaa aaa aaa aaa aaa
> aaa aaa aaa aaa aaa aaa
> aaa aaa aaa aaa aaa aaa
> bbb
> ------ cut here ------
> Then cut and copy this block (including the last blank line) several times
> (I did it about 15 times) to create lots of "aaa" paragraphs and single
> "bbb" words, separated by blank lines. Then go to the top of the file and
> type "^J^K^K" over and over. I.e., you justify the "aaa"s and then delete
> the intervening "bbb" and then repeat to create lots of paragraphs of
> justified "aaa"s. Provided you do not press any other keys during this
> repeated sequence, nano will evenutally crash. The only point I've noted
> is that if the "aaa"s don't justify to more than one line, then it doesn't
> seem to fail.
> Trying to trace through the source code, the problem comes from
> do_cut_text(), which calls edit_refresh() which calls update_line() which
> calls nmalloc() which calls malloc()... which is the routine that actually
> fails. However, I would not expect that sort of behaviour from a malloc()
> on a Linux system. I tried inserting some debug lines into the nmalloc()
> call, and the variable "howmuch" was "48" at the time of the crash. I've
> also tried unwrapping the malloc() call out of the "if" statement.
> I have tried this on two independent machines, but they were both running
> SuSE Linux (one was v7.2 and the other 7.3).
> I'm happy to help out with any testing/debugging etc, but before I
> proceed, I'd be curious to know whether the problem occurs on any other
> systems, or whether it is just me.
> regards, Derek. (address@hidden)
> _______________________________________________________________
> Have big pipes? is looking for download mirrors. We supply
> the hardware. You get the recognition. Email Us: address@hidden
> _______________________________________________
> Nano-devel mailing list
> address@hidden

reply via email to

[Prev in Thread] Current Thread [Next in Thread]