wget-dev
[Top][All Lists]
Advanced

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

Re: wget2 | Draft: Small fixes (!505)


From: Avinash Sonawane (@rootkea)
Subject: Re: wget2 | Draft: Small fixes (!505)
Date: Tue, 07 Jun 2022 04:06:04 +0000



Avinash Sonawane commented on a discussion on libwget/http.c: 
https://gitlab.com/gnuwget/wget2/-/merge_requests/505#note_973261922

>  
>               if (nread < 4) continue;
>  
> -             if (nread - nbytes <= 4)
> +             if (nread - nbytes <= 3)

> With your change the check is `if (5 - 1 <= 3)` which is false.

Ah, no. The check is `if (5 - 4 <= 3)` which is true.

> I wonder how we can craft a test for this situation.

I could only find `MHD_create_response_from_fd_at_offset()` which allows to 
control the no. of bytes sent from the server. But I think it's body data so 
may not be relevant here.

-- 
Reply to this email directly or view it on GitLab: 
https://gitlab.com/gnuwget/wget2/-/merge_requests/505#note_973261922
You're receiving this email because of your account on gitlab.com.




reply via email to

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