cURL / Mailing Lists / curl-users / Single Mail

curl-users

Re: curlopts_writedata not being passed to writefunction properly.

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Fri, 10 Jan 2014 23:38:40 +0100 (CET)

On Fri, 10 Jan 2014, Joshua Kordani wrote:

> http://paste.lisp.org/display/140855

Please use the curl-library list for libcurl questions.

Problem 1 with your code:

    printf("Address of struct: %p\n", myPortInfo);

This doesn't print the address of the struct. Use &myPortInfo there instead.

Problem 2 with your code:

    my_curl_easy_setopt(curl, CURLOPT_WRITEDATA, myPortInfo);

This doesn't pass in the address of the struct as an argument, but you pass
the full struct. That won't have the effect you want.

-- 
  / daniel.haxx.se
-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-users
FAQ:        http://curl.haxx.se/docs/faq.html
Etiquette:  http://curl.haxx.se/mail/etiquette.html
Received on 2014-01-10