W3C home > Mailing lists > Public > www-lib@w3.org > October to December 2001

BUG: segmentation fault with unexpected http server answer

From: Alex Cyn <alexcyn_reg@hotmail.ru>
Date: Thu, 06 Dec 2001 21:32:48 +0300
Message-ID: <20011206183248.6194.qmail@grif.newmail.ru>
To: www-lib@w3.org
(sorry for off-topic, but www-lib-bugs@w3.org doesnt seem 
to work)

When doing any HTTP client request, library fails 
(segmentation fault) if server returns unexpected answer.
How to reproduce:
1) run: netcat -l -p $port
2) connect to this port via Libwww
3) type in netcat window "200 OK\n"
Client app is crashed.

I guess, that problem is in line 674 in HTTP.c file - 
HTNextField(&ptr) can return NULL and it is needed to check 
it"s result against NULL before passing result to the atoi
() function.

=Alex
__________
www.newmail.ru -- Новая Почта: все по новому.
Received on Thursday, 6 December 2001 13:32:50 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 23 April 2007 18:18:40 GMT