Multi.hpp interface change

6 views
Skip to first unread message

Philippe Vaucher

unread,
Apr 1, 2009, 4:40:55 AM4/1/09
to curlpp-devel
Hello,

In Multi.hpp there's the following typedef:

typedef std::list<std::pair<const curlpp::Easy *, Multi::Info> > Msgs;

I think you should remove the const, because we need to be able to
modify the easy handle in order to reuse it in the middle of a Multi-
transfer. For example when you dynamically reuse finished transfers in
order to provide the functionnality of a "queue" of like 10 files
transfering at the same time.

Then the following API:

void fdset(fd_set * read_fd_set, fd_set * write_fd_set, fd_set *
exc_fd_set, int * max_fd);

I think it'd return the CURLMcode for consistency with the C api.

Thanks,
Philippe

Jean-Philippe Barette-LaPierre

unread,
Apr 1, 2009, 8:50:24 AM4/1/09
to curlpp...@googlegroups.com


On Wed, Apr 1, 2009 at 4:40 AM, Philippe Vaucher <philippe...@gmail.com> wrote:

Hello,

Hi!
 


In Multi.hpp there's the following typedef:

typedef std::list<std::pair<const curlpp::Easy *, Multi::Info> > Msgs;

I think you should remove the const, because we need to be able to
modify the easy handle in order to reuse it in the middle of a Multi-
transfer. For example when you dynamically reuse finished transfers in
order to provide the functionnality of a "queue" of like 10 files
transfering at the same time.

Absolutely true. The change is in my repository, I just need to push it in bitbucket
(don't have my laptop with me at the office)
 

Then the following API:

void fdset(fd_set * read_fd_set, fd_set * write_fd_set, fd_set *
exc_fd_set, int * max_fd);

I think it'd return the CURLMcode for consistency with the C api.

Well, as "perform" function, every code different than CURLM_OK will
throws an exception. I think it's the good way of handling things. If
you got more objections, don't hesitate.

 

Thanks,
Philippe



Reply all
Reply to author
Forward
0 new messages