Hi Tim,
Just sent new version of this patch.
Shouldn't be any memleaks now.
Piotr
On 21/10/16 12:36, Tim Rühsen wrote:
Hi Piotr,
please include netrc.h in utils.c.
In getftp():
struct net_credentials *ftp_cred = malloc (sizeof *ftp_cred);
...
ftp_cred = pick_credentials()
This looks
Hi Piotr,
please include netrc.h in utils.c.
In getftp():
struct net_credentials *ftp_cred = malloc (sizeof *ftp_cred);
...
ftp_cred = pick_credentials()
This looks like a memleak. Also, where do you free ftp_cred ?
Is it really necessary to allocate ftp_cred on each call to getftp (just
* src/ftp.c: Leverage new struct net_credentials and function pick_credentials.
pick_credentials is responsible for taking proper order when selecting source
of credentials.
* src/http.c: Leverage new struct net_credentials and function
pick_credentials.
* src/utils.c: New function