Lines Matching defs:conn
129 ConnInfo *conn;
138 curl_easy_getinfo(easy, CURLINFO_PRIVATE, &conn);
140 MSG_OUT("DONE: %s => (%d) %s\n", eff_url, res, conn->error);
142 free(conn->url);
144 free(conn);
282 ConnInfo *conn = (ConnInfo*) data;
284 (void)conn;
293 ConnInfo *conn = (ConnInfo *)p;
294 MSG_OUT("Progress: %s (%g/%g)\n", conn->url, dlnow, dltotal);
303 ConnInfo *conn;
306 conn = g_malloc0(sizeof(ConnInfo));
308 conn->error[0]='\0';
310 conn->easy = curl_easy_init();
311 if (!conn->easy) {
315 conn->global = g;
316 conn->url = g_strdup(url);
317 curl_easy_setopt(conn->easy, CURLOPT_URL, conn->url);
318 curl_easy_setopt(conn->easy, CURLOPT_WRITEFUNCTION, write_cb);
319 curl_easy_setopt(conn->easy, CURLOPT_WRITEDATA, &conn);
320 curl_easy_setopt(conn->easy, CURLOPT_VERBOSE, (long)SHOW_VERBOSE);
321 curl_easy_setopt(conn->easy, CURLOPT_ERRORBUFFER, conn->error);
322 curl_easy_setopt(conn->easy, CURLOPT_PRIVATE, conn);
323 curl_easy_setopt(conn->easy, CURLOPT_NOPROGRESS, SHOW_PROGRESS?0L:1L);
324 curl_easy_setopt(conn->easy, CURLOPT_PROGRESSFUNCTION, prog_cb);
325 curl_easy_setopt(conn->easy, CURLOPT_PROGRESSDATA, conn);
326 curl_easy_setopt(conn->easy, CURLOPT_FOLLOWLOCATION, 1L);
327 curl_easy_setopt(conn->easy, CURLOPT_CONNECTTIMEOUT, 30L);
328 curl_easy_setopt(conn->easy, CURLOPT_LOW_SPEED_LIMIT, 1L);
329 curl_easy_setopt(conn->easy, CURLOPT_LOW_SPEED_TIME, 30L);
331 MSG_OUT("Adding easy %p to multi %p (%s)\n", conn->easy, g->multi, url);
332 rc =curl_multi_add_handle(g->multi, conn->easy);