cURL / Mailing Lists / curl-library / Single Mail

curl-library

Patch for getinmemory.c

From: James Bursa <james_at_zamez.org>
Date: Tue, 14 Sep 2010 15:44:56 -0500

I've attached a patch that proposes changes to getinmemory.c:

1. Remove the comment warning that it's "not been verified to work". It
   works with no problems in my testing.

2. Remove 2 unnecessary includes.

3. Remove the myrealloc(). Initialize chunk.memory with malloc()
   instead of NULL. The comments for these two parts contradicted each
   other.

4. Handle out of memory from realloc() instead of continuing.

5. Print a brief status message at the end.

I think these changes make it easier to understand for new users.

James

-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-library
Etiquette: http://curl.haxx.se/mail/etiquette.html

Received on 2010-09-14