Lines Matching defs:conn
124 ConnInfo *conn;
133 curl_easy_getinfo(easy, CURLINFO_PRIVATE, &conn);
135 MSG_OUT("DONE: %s => (%d) %s\n", eff_url, res, conn->error);
137 free(conn->url);
139 free(conn);
278 ConnInfo *conn = (ConnInfo*) data;
280 (void)conn;
288 ConnInfo *conn = (ConnInfo *)p;
289 MSG_OUT("Progress: %s (%g/%g)\n", conn->url, dlnow, dltotal);
296 ConnInfo *conn;
299 conn = g_malloc0(sizeof(ConnInfo));
300 conn->error[0]='\0';
301 conn->easy = curl_easy_init();
302 if(!conn->easy) {
306 conn->global = g;
307 conn->url = g_strdup(url);
308 curl_easy_setopt(conn->easy, CURLOPT_URL, conn->url);
309 curl_easy_setopt(conn->easy, CURLOPT_WRITEFUNCTION, write_cb);
310 curl_easy_setopt(conn->easy, CURLOPT_WRITEDATA, &conn);
311 curl_easy_setopt(conn->easy, CURLOPT_VERBOSE, (long)SHOW_VERBOSE);
312 curl_easy_setopt(conn->easy, CURLOPT_ERRORBUFFER, conn->error);
313 curl_easy_setopt(conn->easy, CURLOPT_PRIVATE, conn);
314 curl_easy_setopt(conn->easy, CURLOPT_NOPROGRESS, SHOW_PROGRESS?0L:1L);
315 curl_easy_setopt(conn->easy, CURLOPT_PROGRESSFUNCTION, prog_cb);
316 curl_easy_setopt(conn->easy, CURLOPT_PROGRESSDATA, conn);
317 curl_easy_setopt(conn->easy, CURLOPT_FOLLOWLOCATION, 1L);
318 curl_easy_setopt(conn->easy, CURLOPT_CONNECTTIMEOUT, 30L);
319 curl_easy_setopt(conn->easy, CURLOPT_LOW_SPEED_LIMIT, 1L);
320 curl_easy_setopt(conn->easy, CURLOPT_LOW_SPEED_TIME, 30L);
322 MSG_OUT("Adding easy %p to multi %p (%s)\n", conn->easy, g->multi, url);
323 rc = curl_multi_add_handle(g->multi, conn->easy);