* src/ftp.c (ftp_loop_internal): Remove use of alloca

This commit is contained in:
Tim Rühsen 2020-02-13 20:02:25 +01:00
parent 6a3e96275b
commit d0695e269f

View File

@ -1840,7 +1840,7 @@ ftp_loop_internal (struct url *u, struct url *original_url, struct fileinfo *f,
/* Declare WARC variables. */
bool warc_enabled = (opt.warc_filename != NULL);
FILE *warc_tmp = NULL;
ip_address *warc_ip = NULL;
ip_address warc_ip_buf, *warc_ip = NULL;
wgint last_expected_bytes = 0;
/* Get the target, and set the name for the message accordingly. */
@ -1922,7 +1922,7 @@ ftp_loop_internal (struct url *u, struct url *original_url, struct fileinfo *f,
if (!con->proxy && con->csock != -1)
{
warc_ip = (ip_address *) alloca (sizeof (ip_address));
warc_ip = &warc_ip_buf;
socket_ip_address (con->csock, warc_ip, ENDPOINT_PEER);
}
}