cURL / Mailing Lists / curl-library / Single Mail


curl_easy_setopt expects a curl_write_callback argument

From: Jeroen Ooms <>
Date: Thu, 20 Nov 2014 14:26:44 -0800

I wrote a simple streaming function for R [1] that uses
CURLOPT_WRITEFUNCTION to buffer data, similar to the getinmemory.c
example. The app works fine on all platforms, but when I compile on
windows (R uses mingw-w64 with gcc 4.6.3) it gives the following

  curl.c: In function 'rcurl_open':
  curl.c:152:3: warning: call to
'_curl_easy_setopt_err_write_callback' declared with attribute
warning: curl_easy_setopt expects a curl_write_callback argument for
this option [enabled by default]

What am I doing wrong? The callback function has the standard
arguments and returns size_t. The maintainers of the R package
repositories are allergic to compiler warnings, so I'd really like to
get rid of it.

List admin:
Received on 2014-11-20