curl-library
Re: Newb:Save image to a file:C++
From: Ric <chubychoco_at_yahoo.com>
Date: Sat, 28 Feb 2009 17:15:14 +0000 (UTC)
Date: Sat, 28 Feb 2009 17:15:14 +0000 (UTC)
Jeff Pohlmeyer <yetanothergeek <at> gmail.com> writes:
>
> On Sat, Feb 28, 2009 at 10:54 AM, Erico <chubychoco <at> yahoo.com> wrote:
>
> > fp = fopen("google.png", "w");
>
> Are you by any chance using Windows?
> If so, maybe opening the file in "binary" mode:
>
> fp = fopen("google.png", "wb");
>
> - Jeff
>
>
Yes, I'm using Windows, sorry I forgot mentioning that.
Using the binary mode solved the problem.
Thank you Jeff.
Received on 2009-02-28