curl / Mailing Lists / curl-library / Single Mail
Buy commercial curl support from WolfSSL. We help you work out your issues, debug your libcurl applications, use the API, port to new platforms, add new features and more. With a team lead by the curl founder himself.

Re: Memory leak with curl_multi_socket_action

From: James Read via curl-library <curl-library_at_cool.haxx.se>
Date: Mon, 25 May 2020 23:15:29 +0100

On Mon, May 25, 2020 at 10:37 PM Daniel Stenberg <daniel_at_haxx.se> wrote:

> On Mon, 25 May 2020, James Read wrote:
>
> > I call curl_multi_cleanup here:
>
> > I call curl_easy_cleanup here:
>
> > What am I missing?
>
> I don't think we'll be able to tell you that. We can't reproduce this
> problem.
> We don't see any memory leak in any builds on any platforms.
>
> I suggest you write up a sample program based on your experiences that
> reproduces the problem, and show that to us. Then we can help out more!
>

#include <errno.h>
#include <fcntl.h>
#include <signal.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <sys/epoll.h>
#include <sys/stat.h>
#include <sys/time.h>
#include <sys/timerfd.h>
#include <sys/types.h>
#include <sys/resource.h>
#include <sys/socket.h>
#include <arpa/inet.h>
#include <time.h>
#include <unistd.h>
#include <pthread.h>
#include <netdb.h>
#include <time.h>
#include <netinet/in.h>

#include <curl/curl.h>

#define MSG_OUT stdout
#define DEFAULT_QUEUE_LENGTH 10000
#define mycase(code) \
        case code: s = __STRING(code)

typedef struct _CrawlerConfig
{
char redis_address[1024];
int redis_port;
char mongo_address[1024];
int mongo_port;

char url_file[1024];

int queue_length;
} CrawlerConfig;

/* Global information, common to all connections */
typedef struct _GlobalInfo
{
int epfd; /* epoll filedescriptor */
int tfd; /* timer filedescriptor */
CURLM *multi;
int still_running;
pthread_mutex_t lock;
int concurrent_connections;
pthread_mutex_t parsed_lock;
int parsed_sites;

CrawlerConfig config;
} GlobalInfo;

/* Information associated with a specific easy handle */
typedef struct _ConnInfo
{
CURL *easy;
char *url;
GlobalInfo *global;
char error[CURL_ERROR_SIZE];
size_t size;
char *data;
} ConnInfo;

/* Information associated with a specific socket */
typedef struct _SockInfo
{
curl_socket_t sockfd;
CURL *easy;
int action;
long timeout;
GlobalInfo *global;
} SockInfo;

/* Die if we get a bad CURLMcode somewhere */
static void
mcode_or_die(const char *where, CURLMcode code)
{
if (CURLM_OK != code) {
const char *s;

switch (code) {
mycase(CURLM_BAD_HANDLE); break;
mycase(CURLM_BAD_EASY_HANDLE); break;
mycase(CURLM_OUT_OF_MEMORY); break;
mycase(CURLM_INTERNAL_ERROR); break;
mycase(CURLM_UNKNOWN_OPTION); break;
mycase(CURLM_LAST); break;
default: s = "CURLM_unknown"; break;
mycase(CURLM_BAD_SOCKET);
fprintf(MSG_OUT, "ERROR: %s returns %s\n", where, s);
/* ignore this error */
return;
}

fprintf(MSG_OUT, "ERROR: %s returns %s\n", where, s);
exit(code);
}
}

void
concurrent_connections_inc(GlobalInfo *g)
{
g->concurrent_connections++;

printf("\rParsed sites: %d, %d parallel connections, %d still running\t",
g->parsed_sites, g->concurrent_connections, g->still_running);
fflush(stdout);
}

void
concurrent_connections_dec(GlobalInfo *g)
{
g->concurrent_connections--;

printf("\rParsed sites: %d, %d parallel connections, %d still running\t",
g->parsed_sites, g->concurrent_connections, g->still_running);
fflush(stdout);
}

static void timer_cb(GlobalInfo* g, int revents);

/* Update the timer after curl_multi library does it's thing. Curl will
 * inform us through this callback what it wants the new timeout to be,
 * after it does some work. */
static int
multi_timer_cb(CURLM *multi, long timeout_ms, GlobalInfo *g)
{
struct itimerspec its;

//fprintf(MSG_OUT, "multi_timer_cb: Setting timeout to %ld ms\n",
timeout_ms);

if (timeout_ms > 0) {
its.it_interval.tv_sec = 1;
its.it_interval.tv_nsec = 0;
its.it_value.tv_sec = timeout_ms / 1000;
its.it_value.tv_nsec = (timeout_ms % 1000) * 1000 * 1000;
} else if(timeout_ms == 0) {
/* libcurl wants us to timeout now, however setting both fields of
* new_value.it_value to zero disarms the timer. The closest we can
* do is to schedule the timer to fire in 1 ns. */
its.it_interval.tv_sec = 1;
its.it_interval.tv_nsec = 0;
its.it_value.tv_sec = 0;
its.it_value.tv_nsec = 1;
} else {
memset(&its, 0, sizeof(struct itimerspec));
}

timerfd_settime(g->tfd, /*flags=*/ 0, &its, NULL);

return (0);
}

/* Check for completed transfers, and remove their easy handles */
static void
check_multi_info(GlobalInfo *g)
{
char *eff_url;
CURLMsg *msg;
int msgs_left;
ConnInfo *conn;
CURL *easy;
char *ct;
double time;
double dl;
//CURLcode res;

while ((msg = curl_multi_info_read(g->multi, &msgs_left))) {
if (msg->msg == CURLMSG_DONE) {
easy = msg->easy_handle;
//res = msg->data.result;
curl_easy_getinfo(easy, CURLINFO_PRIVATE, &conn);
curl_easy_getinfo(easy, CURLINFO_EFFECTIVE_URL, &eff_url);
curl_easy_getinfo(easy, CURLINFO_CONTENT_TYPE, &ct);
curl_easy_getinfo(easy, CURLINFO_TOTAL_TIME, &time);
curl_easy_getinfo(easy, CURLINFO_SIZE_DOWNLOAD, &dl);

//fprintf(MSG_OUT, "DONE: %s => (%d) %s\n", eff_url, res, conn->error);

curl_multi_remove_handle(g->multi, easy);
//free(conn->url);
free(conn->data);
curl_easy_cleanup(easy);
free(conn);
}
}
}

/* Called by libevent when we get action on a multi socket filedescriptor*/
static void
event_cb(GlobalInfo *g, int fd, int revents)
{
CURLMcode rc;
struct itimerspec its;

int action = ((revents & EPOLLIN) ? CURL_CSELECT_IN : 0) |
((revents & EPOLLOUT) ? CURL_CSELECT_OUT : 0);

rc = curl_multi_socket_action(g->multi, fd, action, &g->still_running);
mcode_or_die("event_cb: curl_multi_socket_action", rc);

check_multi_info(g);

if (g->still_running <= 0) {
//fprintf(MSG_OUT, "last transfer done, kill timeout\n");
memset(&its, 0, sizeof(struct itimerspec));
timerfd_settime(g->tfd, 0, &its, NULL);
}
}

/* Called by main loop when our timeout expires */
static void
timer_cb(GlobalInfo* g, int revents)
{
CURLMcode rc;
uint64_t count = 0;
ssize_t err = 0;

err = read(g->tfd, &count, sizeof(uint64_t));
if (err == -1) {
/* Note that we may call the timer callback even if the timerfd isn't
* readable. It's possible that there are multiple events stored in the
* epoll buffer (i.e. the timer may have fired multiple times). The
* event count is cleared after the first call so future events in the
* epoll buffer will fail to read from the timer. */
if (errno == EAGAIN) {
//fprintf(MSG_OUT, "EAGAIN on tfd %d\n", g->tfd);
return;
}
}

if (err != sizeof(uint64_t)) {
fprintf(stderr, "read(tfd) == %ld", err);
perror("read(tfd)");
}

rc = curl_multi_socket_action(g->multi, CURL_SOCKET_TIMEOUT, 0,
&g->still_running);
mcode_or_die("timer_cb: curl_multi_socket_action", rc);
check_multi_info(g);
}

/* Assign information to a SockInfo structure */
static void
setsock(SockInfo *f, curl_socket_t s, CURL *e, int act, GlobalInfo *g)
{
struct epoll_event ev;
int kind = ((act & CURL_POLL_IN) ? EPOLLIN : 0) |
  ((act & CURL_POLL_OUT) ? EPOLLOUT : 0);

if (f->sockfd) {
concurrent_connections_dec(g);
if (epoll_ctl(g->epfd, EPOLL_CTL_DEL, f->sockfd, NULL))
fprintf(stderr, "EPOLL_CTL_DEL failed for fd: %d : %s\n",
 f->sockfd, strerror(errno));
}

f->sockfd = s;
f->action = act;
f->easy = e;

ev.events = kind;
ev.data.fd = s;

concurrent_connections_inc(g);
if (epoll_ctl(g->epfd, EPOLL_CTL_ADD, s, &ev)) {
fprintf(stderr, "EPOLL_CTL_ADD failed for fd: %d : %s\n",
 s, strerror(errno));
}
}

/* Initialize a new SockInfo structure */
static void
addsock(curl_socket_t s, CURL *easy, int action, GlobalInfo *g)
{
SockInfo *fdp = (SockInfo *)calloc(sizeof(SockInfo), 1);

fdp->global = g;
setsock(fdp, s, easy, action, g);
curl_multi_assign(g->multi, s, fdp);
}

static size_t
write_cb(void *contents, size_t size, size_t nmemb, void *p)
{
ConnInfo *conn = (ConnInfo *)p;
size_t realsize = size * nmemb;

conn->data = realloc(conn->data, conn->size + realsize + 1);
if (conn->data == NULL) {
/* out of memory! */
printf("not enough memory (realloc returned NULL)\n");
return 0;
}

memcpy(&(conn->data[conn->size]), contents, realsize);
conn->size += realsize;
conn->data[conn->size] = 0;

return realsize;
}

/* Create a new easy handle, and add it to the global curl_multi */
int
new_conn(char *url, GlobalInfo *g)
{
ConnInfo *conn;
CURLMcode rc;
char buffer1[1024];
char buffer2[1024];

memset(buffer1, 0, sizeof(buffer1));
memset(buffer2, 0, sizeof(buffer2));

conn = (ConnInfo*)calloc(1, sizeof(ConnInfo));
conn->error[0]='\0';
conn->global = g;

conn->easy = curl_easy_init();
if (!conn->easy) {
fprintf(MSG_OUT, "curl_easy_init() failed, exiting!\n");
exit(2);
}

int autoresolve = 0;

conn->global = g;
conn->url = url;
curl_easy_setopt(conn->easy, CURLOPT_URL, conn->url);
curl_easy_setopt(conn->easy, CURLOPT_WRITEFUNCTION, write_cb);
curl_easy_setopt(conn->easy, CURLOPT_WRITEDATA, conn);
curl_easy_setopt(conn->easy, CURLOPT_FOLLOWLOCATION, 1L);
curl_easy_setopt(conn->easy, CURLOPT_ERRORBUFFER, conn->error);
curl_easy_setopt(conn->easy, CURLOPT_PRIVATE, conn);
curl_easy_setopt(conn->easy, CURLOPT_NOPROGRESS, 1L);
curl_easy_setopt(conn->easy, CURLOPT_PROGRESSDATA, conn);
curl_easy_setopt(conn->easy, CURLOPT_FOLLOWLOCATION, 1L);
curl_easy_setopt(conn->easy, CURLOPT_LOW_SPEED_TIME, 3L);
curl_easy_setopt(conn->easy, CURLOPT_LOW_SPEED_LIMIT, 100L);
curl_easy_setopt(conn->easy, CURLOPT_CONNECTTIMEOUT, 10L);
curl_easy_setopt(conn->easy, CURLOPT_CLOSESOCKETDATA, g);

rc = curl_multi_add_handle(g->multi, conn->easy);
mcode_or_die("new_conn: curl_multi_add_handle", rc);

/* note that the add_handle() will set a time-out to trigger very soon so
     that the necessary socket_action() call will be called by this app */

return (0);
}

/* Clean up the SockInfo structure */
static void
remsock(SockInfo *f, GlobalInfo* g)
{
if (f) {
if (f->sockfd) {
g->concurrent_connections--;
if (epoll_ctl(g->epfd, EPOLL_CTL_DEL, f->sockfd, NULL))
fprintf(stderr, "EPOLL_CTL_DEL failed for fd: %d : %s\n",
 f->sockfd, strerror(errno));
}

free(f);
}
}

/* CURLMOPT_SOCKETFUNCTION */
static int
sock_cb(CURL *e, curl_socket_t s, int what, void *cbp, void *sockp)
{
GlobalInfo *g = (GlobalInfo*) cbp;
SockInfo *fdp = (SockInfo*) sockp;

if (what == CURL_POLL_REMOVE) {
remsock(fdp, g);
} else {
if (!fdp) {
addsock(s, e, what, g);
} else {
setsock(fdp, s, e, what, g);
}
}

return (0);
}

int should_exit = 0;

void
signal_handler(int signo)
{
should_exit = 1;
}

static void
thread_sighandler(int signum)
{
printf("\nCrawler exiting.\n");
pthread_exit(NULL);
}

void *
crawler_init(void *arg)
{
GlobalInfo g;
struct itimerspec its;
struct epoll_event ev;
struct epoll_event events[10000];

signal(SIGUSR1, thread_sighandler);

memset(&g, 0, sizeof(GlobalInfo));

memcpy(&g.config, arg, sizeof(CrawlerConfig));

g.epfd = epoll_create1(EPOLL_CLOEXEC);
if (g.epfd == -1) {
perror("epoll_create1 failed\n");
exit(1);
}

g.tfd = timerfd_create(CLOCK_MONOTONIC, TFD_NONBLOCK | TFD_CLOEXEC);
if (g.tfd == -1) {
perror("timerfd_create failed\n");
exit(1);
}

memset(&its, 0, sizeof(struct itimerspec));
its.it_interval.tv_sec = 1;
its.it_value.tv_sec = 1;
timerfd_settime(g.tfd, 0, &its, NULL);

ev.events = EPOLLIN;
ev.data.fd = g.tfd;
epoll_ctl(g.epfd, EPOLL_CTL_ADD, g.tfd, &ev);

curl_global_init(CURL_GLOBAL_DEFAULT);
g.multi = curl_multi_init();

/* setup the generic multi interface options we want */
curl_multi_setopt(g.multi, CURLMOPT_SOCKETFUNCTION, sock_cb);
curl_multi_setopt(g.multi, CURLMOPT_SOCKETDATA, &g);
curl_multi_setopt(g.multi, CURLMOPT_TIMERFUNCTION, multi_timer_cb);
curl_multi_setopt(g.multi, CURLMOPT_TIMERDATA, &g);

/* we don't call any curl_multi_socket*() function yet as we have no
handles added! */

//printf("Starting crawler...\n");

while (!should_exit) {
int idx;
int err = epoll_wait(g.epfd, events, sizeof(events)/sizeof(struct
epoll_event), 10000);

new_conn("www.google.com", &g);
new_conn("www.yahoo.com", &g);
new_conn("www.bing.com", &g);

if (err == -1) {
if (errno == EINTR) {
fprintf(MSG_OUT, "note: wait interrupted\n");
continue;
} else {
perror("epoll_wait");
exit(1);
}
}

for (idx = 0; idx < err; ++idx) {
if (events[idx].data.fd == g.tfd) {
timer_cb(&g, events[idx].events);
} else {
event_cb(&g, events[idx].data.fd, events[idx].events);
}
}
}

fprintf(MSG_OUT, "Exiting normally.\n");
fflush(MSG_OUT);

curl_multi_cleanup(g.multi);
curl_global_cleanup();

return (NULL);
}

int
main(int argc, char **argv)
{
int cleanup = 0, opt, ret;
CrawlerConfig config;

memset(&config, 0, sizeof(config));
config.queue_length = DEFAULT_QUEUE_LENGTH;

should_exit = 0;
signal(SIGINT, signal_handler);
signal(SIGKILL, signal_handler);

crawler_init( (void *)&config);

printf("Exiting.\n");

return (0);
}

Valgrind output:

==14068== Memcheck, a memory error detector
==14068== Copyright (C) 2002-2017, and GNU GPL'd, by Julian Seward et al.
==14068== Using Valgrind-3.15.0-608cb11914-20190413 and LibVEX; rerun with
-h for copyright info
==14068== Command: ./a.out
==14068== Parent PID: 12453
==14068==
--14068--
--14068-- Valgrind options:
--14068-- -v
--14068-- --tool=memcheck
--14068-- --leak-check=full
--14068-- --show-reachable=yes
--14068-- --track-origins=yes
--14068-- --log-file=memcheck.log
--14068-- Contents of /proc/version:
--14068-- Linux version 5.4.0-31-generic (buildd_at_lgw01-amd64-059) (gcc
version 9.3.0 (Ubuntu 9.3.0-10ubuntu2)) #35-Ubuntu SMP Thu May 7 20:20:34
UTC 2020
--14068--
--14068-- Arch and hwcaps: AMD64, LittleEndian,
amd64-cx16-lzcnt-rdtscp-sse3-ssse3-avx-avx2-bmi-f16c-rdrand
--14068-- Page sizes: currently 4096, max supported 4096
--14068-- Valgrind library directory: /usr/lib/x86_64-linux-gnu/valgrind
--14068-- Reading syms from /home/yaakov/libcurlbugreport/a.out
--14068-- Reading syms from /usr/lib/x86_64-linux-gnu/ld-2.31.so
--14068-- Considering /usr/lib/x86_64-linux-gnu/ld-2.31.so ..
--14068-- .. CRC mismatch (computed 387b17ea wanted d28cf5ef)
--14068-- Considering /lib/x86_64-linux-gnu/ld-2.31.so ..
--14068-- .. CRC mismatch (computed 387b17ea wanted d28cf5ef)
--14068-- Considering /usr/lib/debug/lib/x86_64-linux-gnu/ld-2.31.so ..
--14068-- .. CRC is valid
--14068-- Reading syms from
/usr/lib/x86_64-linux-gnu/valgrind/memcheck-amd64-linux
--14068-- object doesn't have a symbol table
--14068-- object doesn't have a dynamic symbol table
--14068-- Scheduler: using generic scheduler lock implementation.
--14068-- Reading suppressions file:
/usr/lib/x86_64-linux-gnu/valgrind/default.supp
==14068== embedded gdbserver: reading from
/tmp/vgdb-pipe-from-vgdb-to-14068-by-yaakov-on-???
==14068== embedded gdbserver: writing to
/tmp/vgdb-pipe-to-vgdb-from-14068-by-yaakov-on-???
==14068== embedded gdbserver: shared mem
/tmp/vgdb-pipe-shared-mem-vgdb-14068-by-yaakov-on-???
==14068==
==14068== TO CONTROL THIS PROCESS USING vgdb (which you probably
==14068== don't want to do, unless you know exactly what you're doing,
==14068== or are doing some strange experiment):
==14068== /usr/lib/x86_64-linux-gnu/valgrind/../../bin/vgdb --pid=14068
...command...
==14068==
==14068== TO DEBUG THIS PROCESS USING GDB: start GDB like this
==14068== /path/to/gdb ./a.out
==14068== and then give GDB the following command
==14068== target remote |
/usr/lib/x86_64-linux-gnu/valgrind/../../bin/vgdb --pid=14068
==14068== --pid is optional if only one valgrind process is running
==14068==
--14068-- REDIR: 0x4022d80 (ld-linux-x86-64.so.2:strlen) redirected to
0x580c9ce2 (???)
--14068-- REDIR: 0x4022b50 (ld-linux-x86-64.so.2:index) redirected to
0x580c9cfc (???)
--14068-- Reading syms from
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_core-amd64-linux.so
--14068-- object doesn't have a symbol table
--14068-- Reading syms from
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so
--14068-- object doesn't have a symbol table
==14068== WARNING: new redirection conflicts with existing -- ignoring it
--14068-- old: 0x04022d80 (strlen ) R-> (0000.0)
0x580c9ce2 ???
--14068-- new: 0x04022d80 (strlen ) R-> (2007.0)
0x0483f060 strlen
--14068-- REDIR: 0x401f560 (ld-linux-x86-64.so.2:strcmp) redirected to
0x483ffd0 (strcmp)
--14068-- REDIR: 0x40232e0 (ld-linux-x86-64.so.2:mempcpy) redirected to
0x4843a20 (mempcpy)
--14068-- Reading syms from /usr/local/lib/libcurl.so.4.6.0
--14068-- Reading syms from /usr/lib/x86_64-linux-gnu/libc-2.31.so
--14068-- Considering /usr/lib/x86_64-linux-gnu/libc-2.31.so ..
--14068-- .. CRC mismatch (computed a6f43087 wanted 6555436e)
--14068-- Considering /lib/x86_64-linux-gnu/libc-2.31.so ..
--14068-- .. CRC mismatch (computed a6f43087 wanted 6555436e)
--14068-- Considering /usr/lib/debug/lib/x86_64-linux-gnu/libc-2.31.so ..
--14068-- .. CRC is valid
--14068-- Reading syms from /usr/lib/x86_64-linux-gnu/libssl.so.1.1
--14068-- object doesn't have a symbol table
--14068-- Reading syms from /usr/lib/x86_64-linux-gnu/libcrypto.so.1.1
--14068-- object doesn't have a symbol table
--14068-- Reading syms from /usr/lib/x86_64-linux-gnu/libz.so.1.2.11
--14068-- object doesn't have a symbol table
--14068-- Reading syms from /usr/lib/x86_64-linux-gnu/libpthread-2.31.so
--14068-- Considering
/usr/lib/debug/.build-id/77/5cbbfff814456660786780b0b3b40096b4c05e.debug ..
--14068-- .. build-id is valid
--14068-- Reading syms from /usr/lib/x86_64-linux-gnu/libdl-2.31.so
--14068-- Considering /usr/lib/x86_64-linux-gnu/libdl-2.31.so ..
--14068-- .. CRC mismatch (computed 4fd191ca wanted df8dd39a)
--14068-- Considering /lib/x86_64-linux-gnu/libdl-2.31.so ..
--14068-- .. CRC mismatch (computed 4fd191ca wanted df8dd39a)
--14068-- Considering /usr/lib/debug/lib/x86_64-linux-gnu/libdl-2.31.so ..
--14068-- .. CRC is valid
--14068-- REDIR: 0x49e7600 (libc.so.6:memmove) redirected to 0x48311d0
(_vgnU_ifunc_wrapper)
--14068-- REDIR: 0x49e6900 (libc.so.6:strncpy) redirected to 0x48311d0
(_vgnU_ifunc_wrapper)
--14068-- REDIR: 0x49e7930 (libc.so.6:strcasecmp) redirected to 0x48311d0
(_vgnU_ifunc_wrapper)
--14068-- REDIR: 0x49e6220 (libc.so.6:strcat) redirected to 0x48311d0
(_vgnU_ifunc_wrapper)
--14068-- REDIR: 0x49e6960 (libc.so.6:rindex) redirected to 0x48311d0
(_vgnU_ifunc_wrapper)
--14068-- REDIR: 0x49e8dd0 (libc.so.6:rawmemchr) redirected to 0x48311d0
(_vgnU_ifunc_wrapper)
--14068-- REDIR: 0x4a03e60 (libc.so.6:wmemchr) redirected to 0x48311d0
(_vgnU_ifunc_wrapper)
--14068-- REDIR: 0x4a039a0 (libc.so.6:wcscmp) redirected to 0x48311d0
(_vgnU_ifunc_wrapper)
--14068-- REDIR: 0x49e7760 (libc.so.6:mempcpy) redirected to 0x48311d0
(_vgnU_ifunc_wrapper)
--14068-- REDIR: 0x49e7590 (libc.so.6:bcmp) redirected to 0x48311d0
(_vgnU_ifunc_wrapper)
--14068-- REDIR: 0x49e6890 (libc.so.6:strncmp) redirected to 0x48311d0
(_vgnU_ifunc_wrapper)
--14068-- REDIR: 0x49e62d0 (libc.so.6:strcmp) redirected to 0x48311d0
(_vgnU_ifunc_wrapper)
--14068-- REDIR: 0x49e76c0 (libc.so.6:memset) redirected to 0x48311d0
(_vgnU_ifunc_wrapper)
--14068-- REDIR: 0x4a03960 (libc.so.6:wcschr) redirected to 0x48311d0
(_vgnU_ifunc_wrapper)
--14068-- REDIR: 0x49e67f0 (libc.so.6:strnlen) redirected to 0x48311d0
(_vgnU_ifunc_wrapper)
--14068-- REDIR: 0x49e63b0 (libc.so.6:strcspn) redirected to 0x48311d0
(_vgnU_ifunc_wrapper)
--14068-- REDIR: 0x49e7980 (libc.so.6:strncasecmp) redirected to 0x48311d0
(_vgnU_ifunc_wrapper)
--14068-- REDIR: 0x49e6350 (libc.so.6:strcpy) redirected to 0x48311d0
(_vgnU_ifunc_wrapper)
--14068-- REDIR: 0x49e7ad0 (libc.so.6:memcpy@@GLIBC_2.14) redirected to
0x48311d0 (_vgnU_ifunc_wrapper)
--14068-- REDIR: 0x4a050d0 (libc.so.6:wcsnlen) redirected to 0x48311d0
(_vgnU_ifunc_wrapper)
--14068-- REDIR: 0x4a039e0 (libc.so.6:wcscpy) redirected to 0x48311d0
(_vgnU_ifunc_wrapper)
--14068-- REDIR: 0x49e69a0 (libc.so.6:strpbrk) redirected to 0x48311d0
(_vgnU_ifunc_wrapper)
--14068-- REDIR: 0x49e6280 (libc.so.6:index) redirected to 0x48311d0
(_vgnU_ifunc_wrapper)
--14068-- REDIR: 0x49e67b0 (libc.so.6:strlen) redirected to 0x48311d0
(_vgnU_ifunc_wrapper)
--14068-- REDIR: 0x49efd20 (libc.so.6:memrchr) redirected to 0x48311d0
(_vgnU_ifunc_wrapper)
--14068-- REDIR: 0x49e79d0 (libc.so.6:strcasecmp_l) redirected to 0x48311d0
(_vgnU_ifunc_wrapper)
--14068-- REDIR: 0x49e7550 (libc.so.6:memchr) redirected to 0x48311d0
(_vgnU_ifunc_wrapper)
--14068-- REDIR: 0x4a03ab0 (libc.so.6:wcslen) redirected to 0x48311d0
(_vgnU_ifunc_wrapper)
--14068-- REDIR: 0x49e6c60 (libc.so.6:strspn) redirected to 0x48311d0
(_vgnU_ifunc_wrapper)
--14068-- REDIR: 0x49e78d0 (libc.so.6:stpncpy) redirected to 0x48311d0
(_vgnU_ifunc_wrapper)
--14068-- REDIR: 0x49e7870 (libc.so.6:stpcpy) redirected to 0x48311d0
(_vgnU_ifunc_wrapper)
--14068-- REDIR: 0x49e8e10 (libc.so.6:strchrnul) redirected to 0x48311d0
(_vgnU_ifunc_wrapper)
--14068-- REDIR: 0x49e7a20 (libc.so.6:strncasecmp_l) redirected to
0x48311d0 (_vgnU_ifunc_wrapper)
--14068-- REDIR: 0x4a74750 (libc.so.6:__memcpy_chk) redirected to 0x48311d0
(_vgnU_ifunc_wrapper)
--14068-- REDIR: 0x49e7470 (libc.so.6:strstr) redirected to 0x48311d0
(_vgnU_ifunc_wrapper)
--14068-- REDIR: 0x4acf300 (libc.so.6:__strrchr_avx2) redirected to
0x483ea10 (rindex)
--14068-- REDIR: 0x4acf4d0 (libc.so.6:__strlen_avx2) redirected to
0x483ef40 (strlen)
--14068-- REDIR: 0x4ad2960 (libc.so.6:__memset_avx2_unaligned_erms)
redirected to 0x48428e0 (memset)
==14068== Warning: ignored attempt to set SIGKILL handler in sigaction();
==14068== the SIGKILL signal is uncatchable
==14068== Syscall param epoll_ctl(event) points to uninitialised byte(s)
==14068== at 0x4A66ACE: epoll_ctl (syscall-template.S:78)
==14068== by 0x10A684: crawler_init (crawler.c:436)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068== Address 0x1ffefe10ac is on thread 1's stack
==14068== in frame #1, created by crawler_init (crawler.c:405)
==14068== Uninitialised value was created by a stack allocation
==14068== at 0x10A4FF: crawler_init (crawler.c:405)
==14068==
--14068-- REDIR: 0x49e1260 (libc.so.6:malloc) redirected to 0x483b780
(malloc)
--14068-- REDIR: 0x4ad0a10 (libc.so.6:__strcpy_avx2) redirected to
0x483f090 (strcpy)
--14068-- REDIR: 0x49e2000 (libc.so.6:realloc) redirected to 0x483df30
(realloc)
--14068-- REDIR: 0x49e1850 (libc.so.6:free) redirected to 0x483c9d0 (free)
--14068-- REDIR: 0x4ad1700 (libc.so.6:__stpcpy_avx2) redirected to
0x4842300 (stpcpy)
--14068-- REDIR: 0x4ad24c0 (libc.so.6:__mempcpy_avx_unaligned_erms)
redirected to 0x4843660 (mempcpy)
--14068-- REDIR: 0x4ad24e0 (libc.so.6:__memcpy_avx_unaligned_erms)
redirected to 0x48429f0 (memmove)
--14068-- REDIR: 0x4aca9d0 (libc.so.6:__strcmp_avx2) redirected to
0x483fed0 (strcmp)
--14068-- REDIR: 0x49e7120 (libc.so.6:__GI_strstr) redirected to 0x4843ca0
(__strstr_sse2)
--14068-- REDIR: 0x4aceee0 (libc.so.6:__strchr_avx2) redirected to
0x483ebf0 (index)
--14068-- REDIR: 0x4acb330 (libc.so.6:__memchr_avx2) redirected to
0x4840050 (memchr)
--14068-- REDIR: 0x4acae10 (libc.so.6:__strncmp_avx2) redirected to
0x483f670 (strncmp)
--14068-- REDIR: 0x49e2c90 (libc.so.6:calloc) redirected to 0x483dce0
(calloc)
--14068-- REDIR: 0x4aca620 (libc.so.6:__strcspn_sse42) redirected to
0x4843e10 (strcspn)
--14068-- REDIR: 0x4acb600 (libc.so.6:__rawmemchr_avx2) redirected to
0x4843580 (rawmemchr)
--14068-- REDIR: 0x4acf110 (libc.so.6:__strchrnul_avx2) redirected to
0x4843540 (strchrnul)
==14068== Syscall param epoll_ctl(event) points to uninitialised byte(s)
==14068== at 0x4A66ACE: epoll_ctl (syscall-template.S:78)
==14068== by 0x109E02: setsock (crawler.c:266)
==14068== by 0x109EA2: addsock (crawler.c:279)
==14068== by 0x10A47A: sock_cb (crawler.c:379)
==14068== by 0x48B60B1: singlesocket (multi.c:2593)
==14068== by 0x48B6878: multi_socket (multi.c:2839)
==14068== by 0x48B7053: curl_multi_socket_action (multi.c:2956)
==14068== by 0x109CCE: timer_cb (crawler.c:238)
==14068== by 0x10A843: crawler_init (crawler.c:472)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068== Address 0x1ffefe0d94 is on thread 1's stack
==14068== in frame #1, created by setsock (crawler.c:246)
==14068== Uninitialised value was created by a stack allocation
==14068== at 0x109D08: setsock (crawler.c:246)
==14068==
--14068-- REDIR: 0x4acbac0 (libc.so.6:__memcmp_avx2_movbe) redirected to
0x48421e0 (bcmp)
--14068-- REDIR: 0x4acd520 (libc.so.6:__strncasecmp_avx) redirected to
0x483f910 (strncasecmp)
--14068-- REDIR: 0x4aca760 (libc.so.6:__strpbrk_sse42) redirected to
0x4843da0 (strpbrk)
--14068-- Reading syms from /usr/lib/x86_64-linux-gnu/libnss_files-2.31.so
--14068-- Considering /usr/lib/x86_64-linux-gnu/libnss_files-2.31.so ..
--14068-- .. CRC mismatch (computed d61da5d9 wanted 3c29bbce)
--14068-- Considering /lib/x86_64-linux-gnu/libnss_files-2.31.so ..
--14068-- .. CRC mismatch (computed d61da5d9 wanted 3c29bbce)
--14068-- Considering /usr/lib/debug/lib/x86_64-linux-gnu/
libnss_files-2.31.so ..
--14068-- .. CRC is valid
--14068-- REDIR: 0x4acbea0 (libc.so.6:__strcasecmp_avx) redirected to
0x483f830 (strcasecmp)
--14068-- Reading syms from
/usr/lib/x86_64-linux-gnu/libnss_mdns4_minimal.so.2
--14068-- object doesn't have a symbol table
--14068-- Reading syms from /usr/lib/x86_64-linux-gnu/libresolv-2.31.so
--14068-- Considering /usr/lib/x86_64-linux-gnu/libresolv-2.31.so ..
--14068-- .. CRC mismatch (computed 5c5a0ea5 wanted 7eb6f788)
--14068-- Considering /lib/x86_64-linux-gnu/libresolv-2.31.so ..
--14068-- .. CRC mismatch (computed 5c5a0ea5 wanted 7eb6f788)
--14068-- Considering /usr/lib/debug/lib/x86_64-linux-gnu/
libresolv-2.31.so ..
--14068-- .. CRC is valid
--14068-- Reading syms from /usr/lib/x86_64-linux-gnu/libnss_dns-2.31.so
--14068-- Considering /usr/lib/x86_64-linux-gnu/libnss_dns-2.31.so ..
--14068-- .. CRC mismatch (computed e989e5a4 wanted 00ac370c)
--14068-- Considering /lib/x86_64-linux-gnu/libnss_dns-2.31.so ..
--14068-- .. CRC mismatch (computed e989e5a4 wanted 00ac370c)
--14068-- Considering /usr/lib/debug/lib/x86_64-linux-gnu/
libnss_dns-2.31.so ..
--14068-- .. CRC is valid
==14068== Syscall param epoll_ctl(event) points to uninitialised byte(s)
==14068== at 0x4A66ACE: epoll_ctl (syscall-template.S:78)
==14068== by 0x109E02: setsock (crawler.c:266)
==14068== by 0x10A499: sock_cb (crawler.c:381)
==14068== by 0x48B60B1: singlesocket (multi.c:2593)
==14068== by 0x48B6878: multi_socket (multi.c:2839)
==14068== by 0x48B7053: curl_multi_socket_action (multi.c:2956)
==14068== by 0x109BA0: event_cb (crawler.c:200)
==14068== by 0x10A89C: crawler_init (crawler.c:474)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068== Address 0x1ffefe0db4 is on thread 1's stack
==14068== in frame #1, created by setsock (crawler.c:246)
==14068== Uninitialised value was created by a stack allocation
==14068== at 0x109D08: setsock (crawler.c:246)
==14068==
--14068-- Discarding syms at 0x9af55c0-0x9afba1c in
/usr/lib/x86_64-linux-gnu/libnss_files-2.31.so (have_dinfo 1)
--14068-- Discarding syms at 0x9b073a0-0x9b0884a in
/usr/lib/x86_64-linux-gnu/libnss_mdns4_minimal.so.2 (have_dinfo 1)
--14068-- Discarding syms at 0x9b2a320-0x9b2d998 in
/usr/lib/x86_64-linux-gnu/libnss_dns-2.31.so (have_dinfo 1)
--14068-- Discarding syms at 0x9b10720-0x9b1f11c in
/usr/lib/x86_64-linux-gnu/libresolv-2.31.so (have_dinfo 1)
==14068==
==14068== HEAP SUMMARY:
==14068== in use at exit: 2,377,175 bytes in 1,138 blocks
==14068== total heap usage: 123,804 allocs, 122,666 frees, 943,468,716
bytes allocated
==14068==
==14068== Searching for pointers to 1,138 not-freed blocks
==14068== Checked 294,240 bytes
==14068==
==14068== 63 bytes in 3 blocks are indirectly lost in loss record 1 of 48
==14068== at 0x483B7F3: malloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9DB8: curl_dbg_malloc (memdebug.c:174)
==14068== by 0x48A9FDE: curl_dbg_strdup (memdebug.c:229)
==14068== by 0x48E51E5: seturl (urlapi.c:831)
==14068== by 0x48E584C: parseurl (urlapi.c:958)
==14068== by 0x48E6A4F: curl_url_set (urlapi.c:1332)
==14068== by 0x488D142: parseurlandfillconn (url.c:1849)
==14068== by 0x48908FF: create_conn (url.c:3390)
==14068== by 0x4891A37: Curl_connect (url.c:3893)
==14068== by 0x48B4135: multi_runsingle (multi.c:1643)
==14068== by 0x48B6841: multi_socket (multi.c:2833)
==14068== by 0x48B7053: curl_multi_socket_action (multi.c:2956)
==14068==
==14068== 87 bytes in 3 blocks are indirectly lost in loss record 2 of 48
==14068== at 0x483B7F3: malloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9DB8: curl_dbg_malloc (memdebug.c:174)
==14068== by 0x48A9FDE: curl_dbg_strdup (memdebug.c:229)
==14068== by 0x48E54B5: seturl (urlapi.c:890)
==14068== by 0x48E584C: parseurl (urlapi.c:958)
==14068== by 0x48E6A4F: curl_url_set (urlapi.c:1332)
==14068== by 0x488D142: parseurlandfillconn (url.c:1849)
==14068== by 0x48908FF: create_conn (url.c:3390)
==14068== by 0x4891A37: Curl_connect (url.c:3893)
==14068== by 0x48B4135: multi_runsingle (multi.c:1643)
==14068== by 0x48B6841: multi_socket (multi.c:2833)
==14068== by 0x48B7053: curl_multi_socket_action (multi.c:2956)
==14068==
==14068== 93 bytes in 3 blocks are indirectly lost in loss record 3 of 48
==14068== at 0x483B7F3: malloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9DB8: curl_dbg_malloc (memdebug.c:174)
==14068== by 0x48A9FDE: curl_dbg_strdup (memdebug.c:229)
==14068== by 0x48E55F6: seturl (urlapi.c:920)
==14068== by 0x48E584C: parseurl (urlapi.c:958)
==14068== by 0x48E6A4F: curl_url_set (urlapi.c:1332)
==14068== by 0x488D142: parseurlandfillconn (url.c:1849)
==14068== by 0x48908FF: create_conn (url.c:3390)
==14068== by 0x4891A37: Curl_connect (url.c:3893)
==14068== by 0x48B4135: multi_runsingle (multi.c:1643)
==14068== by 0x48B6841: multi_socket (multi.c:2833)
==14068== by 0x48B7053: curl_multi_socket_action (multi.c:2956)
==14068==
==14068== 290 bytes in 10 blocks are indirectly lost in loss record 4 of 48
==14068== at 0x483B7F3: malloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9DB8: curl_dbg_malloc (memdebug.c:174)
==14068== by 0x48A9FDE: curl_dbg_strdup (memdebug.c:229)
==14068== by 0x48C5712: Curl_setstropt (setopt.c:62)
==14068== by 0x48C972A: Curl_vsetopt (setopt.c:1283)
==14068== by 0x48CEE54: curl_easy_setopt (setopt.c:2794)
==14068== by 0x10A0F0: new_conn (crawler.c:329)
==14068== by 0x10A785: crawler_init (crawler.c:458)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068==
==14068== 320 bytes in 10 blocks are indirectly lost in loss record 5 of 48
==14068== at 0x483DD99: calloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9EE0: curl_dbg_calloc (memdebug.c:205)
==14068== by 0x486A389: Curl_resolver_init (asyn-thread.c:115)
==14068== by 0x488A794: Curl_open (url.c:597)
==14068== by 0x487BCF4: curl_easy_init (easy.c:301)
==14068== by 0x10A04B: new_conn (crawler.c:319)
==14068== by 0x10A785: crawler_init (crawler.c:458)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068==
==14068== 369 bytes in 3 blocks are indirectly lost in loss record 6 of 48
==14068== at 0x483B7F3: malloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9DB8: curl_dbg_malloc (memdebug.c:174)
==14068== by 0x48A9FDE: curl_dbg_strdup (memdebug.c:229)
==14068== by 0x48E538A: seturl (urlapi.c:864)
==14068== by 0x48E584C: parseurl (urlapi.c:958)
==14068== by 0x48E6A4F: curl_url_set (urlapi.c:1332)
==14068== by 0x488D142: parseurlandfillconn (url.c:1849)
==14068== by 0x48908FF: create_conn (url.c:3390)
==14068== by 0x4891A37: Curl_connect (url.c:3893)
==14068== by 0x48B4135: multi_runsingle (multi.c:1643)
==14068== by 0x48B6841: multi_socket (multi.c:2833)
==14068== by 0x48B7053: curl_multi_socket_action (multi.c:2956)
==14068==
==14068== 369 bytes in 3 blocks are indirectly lost in loss record 7 of 48
==14068== at 0x483B7F3: malloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9DB8: curl_dbg_malloc (memdebug.c:174)
==14068== by 0x48A9FDE: curl_dbg_strdup (memdebug.c:229)
==14068== by 0x48E6502: curl_url_get (urlapi.c:1174)
==14068== by 0x488D570: parseurlandfillconn (url.c:1931)
==14068== by 0x48908FF: create_conn (url.c:3390)
==14068== by 0x4891A37: Curl_connect (url.c:3893)
==14068== by 0x48B4135: multi_runsingle (multi.c:1643)
==14068== by 0x48B6841: multi_socket (multi.c:2833)
==14068== by 0x48B7053: curl_multi_socket_action (multi.c:2956)
==14068== by 0x109BA0: event_cb (crawler.c:200)
==14068== by 0x10A89C: crawler_init (crawler.c:474)
==14068==
==14068== 510 bytes in 10 blocks are indirectly lost in loss record 8 of 48
==14068== at 0x483B7F3: malloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9DB8: curl_dbg_malloc (memdebug.c:174)
==14068== by 0x48A9FDE: curl_dbg_strdup (memdebug.c:229)
==14068== by 0x48C5712: Curl_setstropt (setopt.c:62)
==14068== by 0x488A566: Curl_init_userdefined (url.c:523)
==14068== by 0x488A89A: Curl_open (url.c:618)
==14068== by 0x487BCF4: curl_easy_init (easy.c:301)
==14068== by 0x10A04B: new_conn (crawler.c:319)
==14068== by 0x10A785: crawler_init (crawler.c:458)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068==
==14068== 510 bytes in 10 blocks are indirectly lost in loss record 9 of 48
==14068== at 0x483B7F3: malloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9DB8: curl_dbg_malloc (memdebug.c:174)
==14068== by 0x48A9FDE: curl_dbg_strdup (memdebug.c:229)
==14068== by 0x48C5712: Curl_setstropt (setopt.c:62)
==14068== by 0x488A590: Curl_init_userdefined (url.c:527)
==14068== by 0x488A89A: Curl_open (url.c:618)
==14068== by 0x487BCF4: curl_easy_init (easy.c:301)
==14068== by 0x10A04B: new_conn (crawler.c:319)
==14068== by 0x10A785: crawler_init (crawler.c:458)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068==
==14068== 540 bytes in 18 blocks are indirectly lost in loss record 10 of 48
==14068== at 0x483B7F3: malloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9DB8: curl_dbg_malloc (memdebug.c:174)
==14068== by 0x48A9FDE: curl_dbg_strdup (memdebug.c:229)
==14068== by 0x48C5712: Curl_setstropt (setopt.c:62)
==14068== by 0x48C972A: Curl_vsetopt (setopt.c:1283)
==14068== by 0x48CEE54: curl_easy_setopt (setopt.c:2794)
==14068== by 0x10A0F0: new_conn (crawler.c:329)
==14068== by 0x10A76F: crawler_init (crawler.c:457)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068==
==14068== 544 bytes in 2 blocks are indirectly lost in loss record 11 of 48
==14068== at 0x483B7F3: malloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9DB8: curl_dbg_malloc (memdebug.c:174)
==14068== by 0x488A84C: Curl_open (url.c:612)
==14068== by 0x487BCF4: curl_easy_init (easy.c:301)
==14068== by 0x10A04B: new_conn (crawler.c:319)
==14068== by 0x10A76F: crawler_init (crawler.c:457)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068==
==14068== 576 bytes in 18 blocks are indirectly lost in loss record 12 of 48
==14068== at 0x483DD99: calloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9EE0: curl_dbg_calloc (memdebug.c:205)
==14068== by 0x486A389: Curl_resolver_init (asyn-thread.c:115)
==14068== by 0x488A794: Curl_open (url.c:597)
==14068== by 0x487BCF4: curl_easy_init (easy.c:301)
==14068== by 0x10A04B: new_conn (crawler.c:319)
==14068== by 0x10A76F: crawler_init (crawler.c:457)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068==
==14068== 816 bytes in 3 blocks are indirectly lost in loss record 13 of 48
==14068== at 0x483B7F3: malloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9DB8: curl_dbg_malloc (memdebug.c:174)
==14068== by 0x488A84C: Curl_open (url.c:612)
==14068== by 0x487BCF4: curl_easy_init (easy.c:301)
==14068== by 0x10A04B: new_conn (crawler.c:319)
==14068== by 0x10A785: crawler_init (crawler.c:458)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068==
==14068== 816 bytes in 3 blocks are indirectly lost in loss record 14 of 48
==14068== at 0x483DFAF: realloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48AA0DF: curl_dbg_realloc (memdebug.c:293)
==14068== by 0x48B0601: alloc_addbyter (mprintf.c:1049)
==14068== by 0x48AFB0F: dprintf_formatf (mprintf.c:839)
==14068== by 0x48B0752: curl_maprintf (mprintf.c:1078)
==14068== by 0x48E6476: curl_url_get (urlapi.c:1145)
==14068== by 0x488D197: parseurlandfillconn (url.c:1861)
==14068== by 0x48908FF: create_conn (url.c:3390)
==14068== by 0x4891A37: Curl_connect (url.c:3893)
==14068== by 0x48B4135: multi_runsingle (multi.c:1643)
==14068== by 0x48B6841: multi_socket (multi.c:2833)
==14068== by 0x48B7053: curl_multi_socket_action (multi.c:2956)
==14068==
==14068== 899 bytes in 29 blocks are indirectly lost in loss record 15 of 48
==14068== at 0x483B7F3: malloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9DB8: curl_dbg_malloc (memdebug.c:174)
==14068== by 0x48A9FDE: curl_dbg_strdup (memdebug.c:229)
==14068== by 0x48C5712: Curl_setstropt (setopt.c:62)
==14068== by 0x48C972A: Curl_vsetopt (setopt.c:1283)
==14068== by 0x48CEE54: curl_easy_setopt (setopt.c:2794)
==14068== by 0x10A0F0: new_conn (crawler.c:329)
==14068== by 0x10A759: crawler_init (crawler.c:456)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068==
==14068== 918 bytes in 18 blocks are indirectly lost in loss record 16 of 48
==14068== at 0x483B7F3: malloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9DB8: curl_dbg_malloc (memdebug.c:174)
==14068== by 0x48A9FDE: curl_dbg_strdup (memdebug.c:229)
==14068== by 0x48C5712: Curl_setstropt (setopt.c:62)
==14068== by 0x488A566: Curl_init_userdefined (url.c:523)
==14068== by 0x488A89A: Curl_open (url.c:618)
==14068== by 0x487BCF4: curl_easy_init (easy.c:301)
==14068== by 0x10A04B: new_conn (crawler.c:319)
==14068== by 0x10A76F: crawler_init (crawler.c:457)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068==
==14068== 918 bytes in 18 blocks are indirectly lost in loss record 17 of 48
==14068== at 0x483B7F3: malloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9DB8: curl_dbg_malloc (memdebug.c:174)
==14068== by 0x48A9FDE: curl_dbg_strdup (memdebug.c:229)
==14068== by 0x48C5712: Curl_setstropt (setopt.c:62)
==14068== by 0x488A590: Curl_init_userdefined (url.c:527)
==14068== by 0x488A89A: Curl_open (url.c:618)
==14068== by 0x487BCF4: curl_easy_init (easy.c:301)
==14068== by 0x10A04B: new_conn (crawler.c:319)
==14068== by 0x10A76F: crawler_init (crawler.c:457)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068==
==14068== 928 bytes in 29 blocks are indirectly lost in loss record 18 of 48
==14068== at 0x483DD99: calloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9EE0: curl_dbg_calloc (memdebug.c:205)
==14068== by 0x486A389: Curl_resolver_init (asyn-thread.c:115)
==14068== by 0x488A794: Curl_open (url.c:597)
==14068== by 0x487BCF4: curl_easy_init (easy.c:301)
==14068== by 0x10A04B: new_conn (crawler.c:319)
==14068== by 0x10A759: crawler_init (crawler.c:456)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068==
==14068== 972 bytes in 54 blocks are indirectly lost in loss record 19 of 48
==14068== at 0x483B7F3: malloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9DB8: curl_dbg_malloc (memdebug.c:174)
==14068== by 0x48A9FDE: curl_dbg_strdup (memdebug.c:229)
==14068== by 0x48E5E92: curl_url_get (urlapi.c:1076)
==14068== by 0x488D493: parseurlandfillconn (url.c:1916)
==14068== by 0x48908FF: create_conn (url.c:3390)
==14068== by 0x4891A37: Curl_connect (url.c:3893)
==14068== by 0x48B4135: multi_runsingle (multi.c:1643)
==14068== by 0x48B6841: multi_socket (multi.c:2833)
==14068== by 0x48B7053: curl_multi_socket_action (multi.c:2956)
==14068== by 0x109BA0: event_cb (crawler.c:200)
==14068== by 0x10A89C: crawler_init (crawler.c:474)
==14068==
==14068== 1,059 bytes in 57 blocks are indirectly lost in loss record 20 of
48
==14068== at 0x483B7F3: malloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9DB8: curl_dbg_malloc (memdebug.c:174)
==14068== by 0x48A9FDE: curl_dbg_strdup (memdebug.c:229)
==14068== by 0x48E6502: curl_url_get (urlapi.c:1174)
==14068== by 0x488D493: parseurlandfillconn (url.c:1916)
==14068== by 0x48908FF: create_conn (url.c:3390)
==14068== by 0x4891A37: Curl_connect (url.c:3893)
==14068== by 0x48B4135: multi_runsingle (multi.c:1643)
==14068== by 0x48B6841: multi_socket (multi.c:2833)
==14068== by 0x48B7053: curl_multi_socket_action (multi.c:2956)
==14068== by 0x109BA0: event_cb (crawler.c:200)
==14068== by 0x10A89C: crawler_init (crawler.c:474)
==14068==
==14068== 1,066 bytes in 26 blocks are indirectly lost in loss record 21 of
48
==14068== at 0x483B7F3: malloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9DB8: curl_dbg_malloc (memdebug.c:174)
==14068== by 0x48992E4: Curl_copy_header_value (http.c:266)
==14068== by 0x48A0D07: Curl_http_readwrite_headers (http.c:3909)
==14068== by 0x48E12D1: readwrite_data (transfer.c:659)
==14068== by 0x48E251B: Curl_readwrite (transfer.c:1248)
==14068== by 0x48B523F: multi_runsingle (multi.c:2095)
==14068== by 0x48B6841: multi_socket (multi.c:2833)
==14068== by 0x48B7053: curl_multi_socket_action (multi.c:2956)
==14068== by 0x109BA0: event_cb (crawler.c:200)
==14068== by 0x10A89C: crawler_init (crawler.c:474)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068==
==14068== 1,083 bytes in 57 blocks are indirectly lost in loss record 22 of
48
==14068== at 0x483B7F3: malloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9DB8: curl_dbg_malloc (memdebug.c:174)
==14068== by 0x48A9FDE: curl_dbg_strdup (memdebug.c:229)
==14068== by 0x48E6502: curl_url_get (urlapi.c:1174)
==14068== by 0x488D4CC: parseurlandfillconn (url.c:1920)
==14068== by 0x48908FF: create_conn (url.c:3390)
==14068== by 0x4891A37: Curl_connect (url.c:3893)
==14068== by 0x48B4135: multi_runsingle (multi.c:1643)
==14068== by 0x48B6841: multi_socket (multi.c:2833)
==14068== by 0x48B7053: curl_multi_socket_action (multi.c:2956)
==14068== by 0x109BA0: event_cb (crawler.c:200)
==14068== by 0x10A89C: crawler_init (crawler.c:474)
==14068==
==14068== 1,134 bytes in 54 blocks are indirectly lost in loss record 23 of
48
==14068== at 0x483B7F3: malloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9DB8: curl_dbg_malloc (memdebug.c:174)
==14068== by 0x48A9FDE: curl_dbg_strdup (memdebug.c:229)
==14068== by 0x48E5788: seturl (urlapi.c:941)
==14068== by 0x48E584C: parseurl (urlapi.c:958)
==14068== by 0x48E6AE1: curl_url_set (urlapi.c:1346)
==14068== by 0x488D142: parseurlandfillconn (url.c:1849)
==14068== by 0x48908FF: create_conn (url.c:3390)
==14068== by 0x4891A37: Curl_connect (url.c:3893)
==14068== by 0x48B4135: multi_runsingle (multi.c:1643)
==14068== by 0x48B6841: multi_socket (multi.c:2833)
==14068== by 0x48B7053: curl_multi_socket_action (multi.c:2956)
==14068==
==14068== 1,197 bytes in 57 blocks are indirectly lost in loss record 24 of
48
==14068== at 0x483B7F3: malloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9DB8: curl_dbg_malloc (memdebug.c:174)
==14068== by 0x48A9FDE: curl_dbg_strdup (memdebug.c:229)
==14068== by 0x48E6502: curl_url_get (urlapi.c:1174)
==14068== by 0x488D224: parseurlandfillconn (url.c:1870)
==14068== by 0x48908FF: create_conn (url.c:3390)
==14068== by 0x4891A37: Curl_connect (url.c:3893)
==14068== by 0x48B4135: multi_runsingle (multi.c:1643)
==14068== by 0x48B6841: multi_socket (multi.c:2833)
==14068== by 0x48B7053: curl_multi_socket_action (multi.c:2956)
==14068== by 0x109BA0: event_cb (crawler.c:200)
==14068== by 0x10A89C: crawler_init (crawler.c:474)
==14068==
==14068== 1,479 bytes in 29 blocks are indirectly lost in loss record 25 of
48
==14068== at 0x483B7F3: malloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9DB8: curl_dbg_malloc (memdebug.c:174)
==14068== by 0x48A9FDE: curl_dbg_strdup (memdebug.c:229)
==14068== by 0x48C5712: Curl_setstropt (setopt.c:62)
==14068== by 0x488A566: Curl_init_userdefined (url.c:523)
==14068== by 0x488A89A: Curl_open (url.c:618)
==14068== by 0x487BCF4: curl_easy_init (easy.c:301)
==14068== by 0x10A04B: new_conn (crawler.c:319)
==14068== by 0x10A759: crawler_init (crawler.c:456)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068==
==14068== 1,479 bytes in 29 blocks are indirectly lost in loss record 26 of
48
==14068== at 0x483B7F3: malloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9DB8: curl_dbg_malloc (memdebug.c:174)
==14068== by 0x48A9FDE: curl_dbg_strdup (memdebug.c:229)
==14068== by 0x48C5712: Curl_setstropt (setopt.c:62)
==14068== by 0x488A590: Curl_init_userdefined (url.c:527)
==14068== by 0x488A89A: Curl_open (url.c:618)
==14068== by 0x487BCF4: curl_easy_init (easy.c:301)
==14068== by 0x10A04B: new_conn (crawler.c:319)
==14068== by 0x10A759: crawler_init (crawler.c:456)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068==
==14068== 1,636 bytes in 54 blocks are indirectly lost in loss record 27 of
48
==14068== at 0x483B7F3: malloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9DB8: curl_dbg_malloc (memdebug.c:174)
==14068== by 0x48A9FDE: curl_dbg_strdup (memdebug.c:229)
==14068== by 0x48E55F6: seturl (urlapi.c:920)
==14068== by 0x48E584C: parseurl (urlapi.c:958)
==14068== by 0x48E6AE1: curl_url_set (urlapi.c:1346)
==14068== by 0x488D142: parseurlandfillconn (url.c:1849)
==14068== by 0x48908FF: create_conn (url.c:3390)
==14068== by 0x4891A37: Curl_connect (url.c:3893)
==14068== by 0x48B4135: multi_runsingle (multi.c:1643)
==14068== by 0x48B6841: multi_socket (multi.c:2833)
==14068== by 0x48B7053: curl_multi_socket_action (multi.c:2956)
==14068==
==14068== 1,729 bytes in 57 blocks are indirectly lost in loss record 28 of
48
==14068== at 0x483B7F3: malloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9DB8: curl_dbg_malloc (memdebug.c:174)
==14068== by 0x48A9FDE: curl_dbg_strdup (memdebug.c:229)
==14068== by 0x489C41A: Curl_http (http.c:2071)
==14068== by 0x48B389E: multi_do (multi.c:1380)
==14068== by 0x48B4914: multi_runsingle (multi.c:1854)
==14068== by 0x48B6841: multi_socket (multi.c:2833)
==14068== by 0x48B7053: curl_multi_socket_action (multi.c:2956)
==14068== by 0x109BA0: event_cb (crawler.c:200)
==14068== by 0x10A89C: crawler_init (crawler.c:474)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068==
==14068== 1,729 bytes in 57 blocks are indirectly lost in loss record 29 of
48
==14068== at 0x483B7F3: malloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9DB8: curl_dbg_malloc (memdebug.c:174)
==14068== by 0x48A9FDE: curl_dbg_strdup (memdebug.c:229)
==14068== by 0x48E6502: curl_url_get (urlapi.c:1174)
==14068== by 0x488D441: parseurlandfillconn (url.c:1910)
==14068== by 0x48908FF: create_conn (url.c:3390)
==14068== by 0x4891A37: Curl_connect (url.c:3893)
==14068== by 0x48B4135: multi_runsingle (multi.c:1643)
==14068== by 0x48B6841: multi_socket (multi.c:2833)
==14068== by 0x48B7053: curl_multi_socket_action (multi.c:2956)
==14068== by 0x109BA0: event_cb (crawler.c:200)
==14068== by 0x10A89C: crawler_init (crawler.c:474)
==14068==
==14068== 2,592 bytes in 54 blocks are indirectly lost in loss record 30 of
48
==14068== at 0x483B7F3: malloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9DB8: curl_dbg_malloc (memdebug.c:174)
==14068== by 0x48B055F: alloc_addbyter (mprintf.c:1035)
==14068== by 0x48AFB0F: dprintf_formatf (mprintf.c:839)
==14068== by 0x48B0752: curl_maprintf (mprintf.c:1078)
==14068== by 0x48E6476: curl_url_get (urlapi.c:1145)
==14068== by 0x488D197: parseurlandfillconn (url.c:1861)
==14068== by 0x48908FF: create_conn (url.c:3390)
==14068== by 0x4891A37: Curl_connect (url.c:3893)
==14068== by 0x48B4135: multi_runsingle (multi.c:1643)
==14068== by 0x48B6841: multi_socket (multi.c:2833)
==14068== by 0x48B7053: curl_multi_socket_action (multi.c:2956)
==14068==
==14068== 2,960 bytes in 10 blocks are indirectly lost in loss record 31 of
48
==14068== at 0x483DD99: calloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x10A022: new_conn (crawler.c:315)
==14068== by 0x10A785: crawler_init (crawler.c:458)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068==
==14068== 5,328 bytes in 18 blocks are indirectly lost in loss record 32 of
48
==14068== at 0x483DD99: calloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x10A022: new_conn (crawler.c:315)
==14068== by 0x10A76F: crawler_init (crawler.c:457)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068==
==14068== 6,840 bytes in 57 blocks are indirectly lost in loss record 33 of
48
==14068== at 0x483DD99: calloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9EE0: curl_dbg_calloc (memdebug.c:205)
==14068== by 0x48E589F: curl_url (urlapi.c:970)
==14068== by 0x488CFE6: parseurlandfillconn (url.c:1828)
==14068== by 0x48908FF: create_conn (url.c:3390)
==14068== by 0x4891A37: Curl_connect (url.c:3893)
==14068== by 0x48B4135: multi_runsingle (multi.c:1643)
==14068== by 0x48B6841: multi_socket (multi.c:2833)
==14068== by 0x48B7053: curl_multi_socket_action (multi.c:2956)
==14068== by 0x109BA0: event_cb (crawler.c:200)
==14068== by 0x10A89C: crawler_init (crawler.c:474)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068==
==14068== 7,888 bytes in 29 blocks are indirectly lost in loss record 34 of
48
==14068== at 0x483B7F3: malloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9DB8: curl_dbg_malloc (memdebug.c:174)
==14068== by 0x488A84C: Curl_open (url.c:612)
==14068== by 0x487BCF4: curl_easy_init (easy.c:301)
==14068== by 0x10A04B: new_conn (crawler.c:319)
==14068== by 0x10A759: crawler_init (crawler.c:456)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068==
==14068== 8,288 bytes in 28 blocks are indirectly lost in loss record 35 of
48
==14068== at 0x483DD99: calloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x10A022: new_conn (crawler.c:315)
==14068== by 0x10A759: crawler_init (crawler.c:456)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068==
==14068== 16,198 bytes in 23 blocks are indirectly lost in loss record 36
of 48
==14068== at 0x483DFAF: realloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48AA0DF: curl_dbg_realloc (memdebug.c:293)
==14068== by 0x489F640: header_append (http.c:3220)
==14068== by 0x489FA3B: Curl_http_readwrite_headers (http.c:3334)
==14068== by 0x48E12D1: readwrite_data (transfer.c:659)
==14068== by 0x48E251B: Curl_readwrite (transfer.c:1248)
==14068== by 0x48B523F: multi_runsingle (multi.c:2095)
==14068== by 0x48B6841: multi_socket (multi.c:2833)
==14068== by 0x48B7053: curl_multi_socket_action (multi.c:2956)
==14068== by 0x109BA0: event_cb (crawler.c:200)
==14068== by 0x10A89C: crawler_init (crawler.c:474)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068==
==14068== 18,737 bytes in 3 blocks are indirectly lost in loss record 37 of
48
==14068== at 0x483B723: malloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x483E017: realloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x109F1B: write_cb (crawler.c:289)
==14068== by 0x48C507B: chop_write (sendf.c:606)
==14068== by 0x48C52CE: Curl_client_write (sendf.c:690)
==14068== by 0x48E1AD3: readwrite_data (transfer.c:888)
==14068== by 0x48E251B: Curl_readwrite (transfer.c:1248)
==14068== by 0x48B523F: multi_runsingle (multi.c:2095)
==14068== by 0x48B6841: multi_socket (multi.c:2833)
==14068== by 0x48B7053: curl_multi_socket_action (multi.c:2956)
==14068== by 0x109BA0: event_cb (crawler.c:200)
==14068== by 0x10A89C: crawler_init (crawler.c:474)
==14068==
==14068== 41,952 bytes in 57 blocks are indirectly lost in loss record 38
of 48
==14068== at 0x483DD99: calloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9EE0: curl_dbg_calloc (memdebug.c:205)
==14068== by 0x48F81D0: Curl_ssl_initsessions (vtls.c:608)
==14068== by 0x48E2BAF: Curl_pretransfer (transfer.c:1455)
==14068== by 0x48B4048: multi_runsingle (multi.c:1619)
==14068== by 0x48B6841: multi_socket (multi.c:2833)
==14068== by 0x48B7053: curl_multi_socket_action (multi.c:2956)
==14068== by 0x109BA0: event_cb (crawler.c:200)
==14068== by 0x10A89C: crawler_init (crawler.c:474)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068==
==14068== 60,800 bytes in 10 blocks are indirectly lost in loss record 39
of 48
==14068== at 0x483DD99: calloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9EE0: curl_dbg_calloc (memdebug.c:205)
==14068== by 0x488A739: Curl_open (url.c:588)
==14068== by 0x487BCF4: curl_easy_init (easy.c:301)
==14068== by 0x10A04B: new_conn (crawler.c:319)
==14068== by 0x10A785: crawler_init (crawler.c:458)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068==
==14068== 109,440 bytes in 18 blocks are indirectly lost in loss record 40
of 48
==14068== at 0x483DD99: calloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9EE0: curl_dbg_calloc (memdebug.c:205)
==14068== by 0x488A739: Curl_open (url.c:588)
==14068== by 0x487BCF4: curl_easy_init (easy.c:301)
==14068== by 0x10A04B: new_conn (crawler.c:319)
==14068== by 0x10A76F: crawler_init (crawler.c:457)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068==
==14068== 134,024 bytes in 2 blocks are possibly lost in loss record 41 of
48
==14068== at 0x483DFAF: realloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x109F1B: write_cb (crawler.c:289)
==14068== by 0x48C507B: chop_write (sendf.c:606)
==14068== by 0x48C52CE: Curl_client_write (sendf.c:690)
==14068== by 0x48E1AD3: readwrite_data (transfer.c:888)
==14068== by 0x48E251B: Curl_readwrite (transfer.c:1248)
==14068== by 0x48B523F: multi_runsingle (multi.c:2095)
==14068== by 0x48B6841: multi_socket (multi.c:2833)
==14068== by 0x48B7053: curl_multi_socket_action (multi.c:2956)
==14068== by 0x109BA0: event_cb (crawler.c:200)
==14068== by 0x10A89C: crawler_init (crawler.c:474)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068==
==14068== 164,010 bytes in 10 blocks are indirectly lost in loss record 42
of 48
==14068== at 0x483B7F3: malloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9DB8: curl_dbg_malloc (memdebug.c:174)
==14068== by 0x488A7F1: Curl_open (url.c:606)
==14068== by 0x487BCF4: curl_easy_init (easy.c:301)
==14068== by 0x10A04B: new_conn (crawler.c:319)
==14068== by 0x10A785: crawler_init (crawler.c:458)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068==
==14068== 176,320 bytes in 29 blocks are indirectly lost in loss record 43
of 48
==14068== at 0x483DD99: calloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9EE0: curl_dbg_calloc (memdebug.c:205)
==14068== by 0x488A739: Curl_open (url.c:588)
==14068== by 0x487BCF4: curl_easy_init (easy.c:301)
==14068== by 0x10A04B: new_conn (crawler.c:319)
==14068== by 0x10A759: crawler_init (crawler.c:456)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068==
==14068== 293,125 bytes in 7 blocks are indirectly lost in loss record 44
of 48
==14068== at 0x483DFAF: realloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x109F1B: write_cb (crawler.c:289)
==14068== by 0x48C507B: chop_write (sendf.c:606)
==14068== by 0x48C52CE: Curl_client_write (sendf.c:690)
==14068== by 0x48A1DD5: Curl_httpchunk_read (http_chunks.c:201)
==14068== by 0x48E1723: readwrite_data (transfer.c:794)
==14068== by 0x48E251B: Curl_readwrite (transfer.c:1248)
==14068== by 0x48B523F: multi_runsingle (multi.c:2095)
==14068== by 0x48B6841: multi_socket (multi.c:2833)
==14068== by 0x48B7053: curl_multi_socket_action (multi.c:2956)
==14068== by 0x109BA0: event_cb (crawler.c:200)
==14068== by 0x10A89C: crawler_init (crawler.c:474)
==14068==
==14068== 295,218 bytes in 18 blocks are indirectly lost in loss record 45
of 48
==14068== at 0x483B7F3: malloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9DB8: curl_dbg_malloc (memdebug.c:174)
==14068== by 0x488A7F1: Curl_open (url.c:606)
==14068== by 0x487BCF4: curl_easy_init (easy.c:301)
==14068== by 0x10A04B: new_conn (crawler.c:319)
==14068== by 0x10A76F: crawler_init (crawler.c:457)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068==
==14068== 475,629 bytes in 29 blocks are indirectly lost in loss record 46
of 48
==14068== at 0x483B7F3: malloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x48A9DB8: curl_dbg_malloc (memdebug.c:174)
==14068== by 0x488A7F1: Curl_open (url.c:606)
==14068== by 0x487BCF4: curl_easy_init (easy.c:301)
==14068== by 0x10A04B: new_conn (crawler.c:319)
==14068== by 0x10A759: crawler_init (crawler.c:456)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068==
==14068== 533,401 bytes in 11 blocks are indirectly lost in loss record 47
of 48
==14068== at 0x483DFAF: realloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x109F1B: write_cb (crawler.c:289)
==14068== by 0x48C507B: chop_write (sendf.c:606)
==14068== by 0x48C52CE: Curl_client_write (sendf.c:690)
==14068== by 0x48E1AD3: readwrite_data (transfer.c:888)
==14068== by 0x48E251B: Curl_readwrite (transfer.c:1248)
==14068== by 0x48B523F: multi_runsingle (multi.c:2095)
==14068== by 0x48B6841: multi_socket (multi.c:2833)
==14068== by 0x48B7053: curl_multi_socket_action (multi.c:2956)
==14068== by 0x109BA0: event_cb (crawler.c:200)
==14068== by 0x10A89C: crawler_init (crawler.c:474)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068==
==14068== 2,243,151 (296 direct, 2,242,855 indirect) bytes in 1 blocks are
definitely lost in loss record 48 of 48
==14068== at 0x483DD99: calloc (in
/usr/lib/x86_64-linux-gnu/valgrind/vgpreload_memcheck-amd64-linux.so)
==14068== by 0x10A022: new_conn (crawler.c:315)
==14068== by 0x10A759: crawler_init (crawler.c:456)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068==
==14068== LEAK SUMMARY:
==14068== definitely lost: 296 bytes in 1 blocks
==14068== indirectly lost: 2,242,855 bytes in 1,135 blocks
==14068== possibly lost: 134,024 bytes in 2 blocks
==14068== still reachable: 0 bytes in 0 blocks
==14068== suppressed: 0 bytes in 0 blocks
==14068==
==14068== ERROR SUMMARY: 2043 errors from 5 contexts (suppressed: 0 from 0)
==14068==
==14068== 1 errors in context 1 of 5:
==14068== Syscall param epoll_ctl(event) points to uninitialised byte(s)
==14068== at 0x4A66ACE: epoll_ctl (syscall-template.S:78)
==14068== by 0x10A684: crawler_init (crawler.c:436)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068== Address 0x1ffefe10ac is on thread 1's stack
==14068== in frame #1, created by crawler_init (crawler.c:405)
==14068== Uninitialised value was created by a stack allocation
==14068== at 0x10A4FF: crawler_init (crawler.c:405)
==14068==
==14068==
==14068== 102 errors in context 2 of 5:
==14068== Syscall param epoll_ctl(event) points to uninitialised byte(s)
==14068== at 0x4A66ACE: epoll_ctl (syscall-template.S:78)
==14068== by 0x109E02: setsock (crawler.c:266)
==14068== by 0x10A499: sock_cb (crawler.c:381)
==14068== by 0x48B60B1: singlesocket (multi.c:2593)
==14068== by 0x48B6878: multi_socket (multi.c:2839)
==14068== by 0x48B7053: curl_multi_socket_action (multi.c:2956)
==14068== by 0x109BA0: event_cb (crawler.c:200)
==14068== by 0x10A89C: crawler_init (crawler.c:474)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068== Address 0x1ffefe0db4 is on thread 1's stack
==14068== in frame #1, created by setsock (crawler.c:246)
==14068== Uninitialised value was created by a stack allocation
==14068== at 0x109D08: setsock (crawler.c:246)
==14068==
==14068==
==14068== 1938 errors in context 3 of 5:
==14068== Syscall param epoll_ctl(event) points to uninitialised byte(s)
==14068== at 0x4A66ACE: epoll_ctl (syscall-template.S:78)
==14068== by 0x109E02: setsock (crawler.c:266)
==14068== by 0x109EA2: addsock (crawler.c:279)
==14068== by 0x10A47A: sock_cb (crawler.c:379)
==14068== by 0x48B60B1: singlesocket (multi.c:2593)
==14068== by 0x48B6878: multi_socket (multi.c:2839)
==14068== by 0x48B7053: curl_multi_socket_action (multi.c:2956)
==14068== by 0x109CCE: timer_cb (crawler.c:238)
==14068== by 0x10A843: crawler_init (crawler.c:472)
==14068== by 0x10A9B1: main (crawler.c:501)
==14068== Address 0x1ffefe0d94 is on thread 1's stack
==14068== in frame #1, created by setsock (crawler.c:246)
==14068== Uninitialised value was created by a stack allocation
==14068== at 0x109D08: setsock (crawler.c:246)
==14068==
==14068== ERROR SUMMARY: 2043 errors from 5 contexts (suppressed: 0 from 0)

Sorry for such a long email. This was the shortest I could make the code to
reproduce.

James Read

>
> --
>
> / daniel.haxx.se | Commercial curl support up to 24x7 is available!
> | Private help, bug fixes, support, ports, new features
> | https://www.wolfssl.com/contact/
>

-------------------------------------------------------------------
Unsubscribe: https://cool.haxx.se/list/listinfo/curl-library
Etiquette: https://curl.haxx.se/mail/etiquette.html
Received on 2020-05-26