I have been trying to make a little function that prints out the result of a libcurl thingy without alot of luck. Here is my little function (the function's prototype has to be exactly like that to work with the library, I just don't think my actual code in the function is right at all)

Code:
size_t write_data(void *buffer, size_t size, size_t nmemb, void *userp)
{
   int i;

   for (i = 0; i < size; i++)
     printf("%c",buffer[i]);
}
Here is the error I'm getting. ( line 30 is the "printf("%c",buffer[i]);" one)

"test.c: In function `write_data':
test.c:30: warning: dereferencing `void *' pointer
test.c:30: error: invalid use of void expression"

Thanks