[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Problem with 1.9.2
In article <36EC3052.BeroList-2.5.2@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>,
Cornelius Krasel <krasel@xxxxxxxxxxxxxxxxxxxxxxxxxxxx> writes
>xcitor wrote:
>
>> After adding a new group tonight:
>
>[fetch dumps core]
>
I joined this list after 1.9.2 was released but I have discovered that
nntpd segfaults the first time an ARTICLE command is issued using a
message ID. This is due to free() freeing the same memory twice. This
problem manifests itself when used with Turnpike Connect v4.01 as the
client.
The good news: here's a patch. p and q are pointers; p is the result of
a malloc and q is a copy of p which is then updated. Consequently, only
p should be free()d. This also means that I can confirm that leafnode
works with Turnpike 4.01.
John
PS I'm sorry if this patch comes out garbled; it is simple enough to
apply by hand if it gets mangled.
*** orig_nntpd.c Wed Mar 3 12:56:06 1999
--- nntpd.c Fri Mar 5 16:54:51 1999
***************
*** 414,421 ****
}
if ( p )
free( p );
- if ( q )
- free( q );
sprintf( s, "%3d %lu %s article retrieved - ", 223-what,
localartno, localmsgid );
--- 414,419 ----
--
John Gray | jgray@xxxxxxxxxxx 0121 688 8897
Azuli IT Services, Birmingham | Web, databases, custom Linux solutions
www.azuli.co.uk