dinhvh / libetpan

Mail Framework for C Language
www.etpan.org
Other
613 stars 284 forks source link

newsnntp_xhdr_range() returns empty clist for huge server responses #283

Open deacomm opened 7 years ago

deacomm commented 7 years ago

If one tries to do XHDR for a huge range, the function returns successfully (NEWSNNTP_NO_ERROR), but the resulting clist pointer is still set to NULL. Minimal test case will be attached.

deacomm commented 7 years ago

Attached as .txt, because of github's file extension filters. large_nntp_group.txt

Observed results: $ ./large_nntp_group connect result 0 group result 0 xhdr result 0 xhdr result NULL

dinhvh commented 7 years ago

Could you show the kind of response you get from the server?

deacomm commented 7 years ago

The "XHDR TO 1-476101" command stalls for a minute or two, and then returns many, many lines. You can easily try it manually at news.gmane.org:119:

MODE READER GROUP gmane.linux.redhat.fedora.general XHDR TO 1-476101

dinhvh commented 6 years ago

You'd rather split the queries in several parts.