[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [vile] Here is the file which demonstrates the insert bug
From: |
Chris G |
Subject: |
Re: [vile] Here is the file which demonstrates the insert bug |
Date: |
Wed, 23 Apr 2008 22:35:28 +0100 |
User-agent: |
Mutt/1.5.17 (2007-11-01) |
On Wed, Apr 23, 2008 at 04:00:44PM -0400, Thomas Dickey wrote:
> On Wed, 23 Apr 2008, Chris G wrote:
>
>> That should help, I hope. I'll go and look at the code myself but,
>> being unfamiliar with it, I don't promise anything exciting/useful.
>
> I see the problem - reproducing these is the hard part.
> (about an hour to narrow down the traces so I could see the error).
>
> Here's a fix:
>
> diff -u -r1.86 word.c
> --- word.c 2008/01/22 00:13:57 1.86
> +++ word.c 2008/04/23 19:52:53
> @@ -42,13 +42,15 @@
> LINE *lp = DOT.l;
> to_delete = 0L;
> if (DOT.o >= 0 && !n && !isSpace(lgetc(lp, DOT.o))) {
> + int tmp = 0;
> for (c = DOT.o; c >= 0; c -= BytesBefore(DOT.l, c)) {
> if (isSpace(lgetc(lp, c))) {
> to_append = n;
> - cnt = (DOT.o - c);
> + cnt = tmp;
> DOT.o = c;
> break;
> }
> + ++tmp;
> }
> }
> for (c = DOT.o; c >= 0; c -= BytesBefore(DOT.l, c)) {
>
> The problem was that 'cnt' is supposed to be a character count rather than
> a byte-count, but it was computed there as a byte-count.
>
I'm afraid that hasn't fixed my bug, it still hangs and says
"working..." alternating with "...working".
--
Chris Green
- Re: [vile] Here is the file which demonstrates the insert bug, (continued)
- Re: [vile] Here is the file which demonstrates the insert bug, Chris G, 2008/04/22
- Re: [vile] Here is the file which demonstrates the insert bug, Thomas Dickey, 2008/04/22
- Re: [vile] Here is the file which demonstrates the insert bug, Chris G, 2008/04/22
- Re: [vile] Here is the file which demonstrates the insert bug, Thomas Dickey, 2008/04/22
- Re: [vile] Here is the file which demonstrates the insert bug, Thomas Dickey, 2008/04/22
- Re: [vile] Here is the file which demonstrates the insert bug, Chris G, 2008/04/23
- Re: [vile] Here is the file which demonstrates the insert bug, Chris G, 2008/04/23
- Re: [vile] Here is the file which demonstrates the insert bug, Thomas Dickey, 2008/04/23
- Re: [vile] Here is the file which demonstrates the insert bug, Chris G, 2008/04/23
- Re: [vile] Here is the file which demonstrates the insert bug, Thomas Dickey, 2008/04/23
- Re: [vile] Here is the file which demonstrates the insert bug,
Chris G <=
- Message not available
- Re: [vile] Here is the file which demonstrates the insert bug, Chris G, 2008/04/23
- Re: [vile] Here is the file which demonstrates the insert bug, Thomas Dickey, 2008/04/23
- Re: [vile] Here is the file which demonstrates the insert bug, Chris G, 2008/04/24
- Re: [vile] Here is the file which demonstrates the insert bug, Thomas Dickey, 2008/04/24
- Re: [vile] Here is the file which demonstrates the insert bug, Thomas Dickey, 2008/04/23
- Re: [vile] Here is the file which demonstrates the insert bug, Chris G, 2008/04/24
- Re: [vile] Here is the file which demonstrates the insert bug, Thomas Dickey, 2008/04/24
- Re: [vile] Here is the file which demonstrates the insert bug, Thomas Dickey, 2008/04/24