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: libcurl 7.81.0 via homebrew on macOS clean up issues
- Contemporary messages sorted: [ by date ] [ by thread ] [ by subject ] [ by author ] [ by messages with attachments ]
From: Gavin Henry via curl-library <curl-library_at_lists.haxx.se>
Date: Mon, 17 Jan 2022 22:20:14 +0000
> > https://github.com/SentryPeer/SentryPeer/blob/main/tests/unit_tests/test_http_api.c#L94
>
> Line 60 sets your write callback with CURLOPT_WRITEFUNCTION but you don't set
> CURLOPT_WRITEDATA for the handle, so your callback will get the default
> callback argument (a FILE * that is stdout).
>
> Then in the callback you seem to expect that 'userp' points to a json_t struct
> or something and from that point things will not be good.
Many thanks Daniel. I'll read the docs more around CURLOPT_WRITEDATA.
Date: Mon, 17 Jan 2022 22:20:14 +0000
> > https://github.com/SentryPeer/SentryPeer/blob/main/tests/unit_tests/test_http_api.c#L94
>
> Line 60 sets your write callback with CURLOPT_WRITEFUNCTION but you don't set
> CURLOPT_WRITEDATA for the handle, so your callback will get the default
> callback argument (a FILE * that is stdout).
>
> Then in the callback you seem to expect that 'userp' points to a json_t struct
> or something and from that point things will not be good.
Many thanks Daniel. I'll read the docs more around CURLOPT_WRITEDATA.
-- Kind Regards, Gavin Henry. https://sentrypeer.org -- Unsubscribe: https://lists.haxx.se/listinfo/curl-library Etiquette: https://curl.haxx.se/mail/etiquette.htmlReceived on 2022-01-17