cURL
Haxx ad
libcurl

curl's project page on SourceForge.net

Sponsors:
Haxx

cURL > Mailing List > Monthly Index > Single Mail

curl-tracker Archives

[curl:bugs] Re: #1284 curl_easy_perform Memory Leak

From: taoyuan237 <taoyuan237_at_users.sf.net>
Date: Thu, 26 Sep 2013 16:00:57 +0000

For example
struct MemoryStruct {
  char *memory;
  size_t size;
};
struct MemoryStruct chunk;
curl_easy_setopt(CURL_handle, CURLOPT_URL, szurl);
curl_easy_setopt(CURL_handle, CURLOPT_WRITEFUNCTION, &WriteMemoryCallback);
curl_easy_setopt(CURL_handle, CURLOPT_WRITEDATA, (void*)&chunk);
curl_easy_perform(CURL_handle);
//WriteMemoryCallback The functions in docs\examples\getinmemory.c
Sometime After the execution of the statement chunk.memory is no content
or After exit Visual Leak Detector report Memory Leak
The problem is not each occurrence

---
** [bugs:#1284] curl_easy_perform Memory Leak**
**Status:** pending-needsinfo
**Labels:** memory leak 
**Created:** Thu Sep 26, 2013 09:24 AM UTC by taoyuan237
**Last Updated:** Thu Sep 26, 2013 02:28 PM UTC
**Owner:** Daniel Stenberg
I use code like this docs\examples\getinmemory.c curllib happened Memory Leak
---------- Block 76 at 0x00136488: 9654 bytes ----------
  Call Stack:
    z:\curl-7.32.0\curl-7.32.0\lib\sendf.c (449): libcurld.dll!Curl_client_write + 0x21 bytes
    z:\curl-7.32.0\curl-7.32.0\lib\transfer.c (705): libcurld.dll!readwrite_data + 0x16 bytes
    z:\curl-7.32.0\curl-7.32.0\lib\transfer.c (1022): libcurld.dll!Curl_readwrite + 0x19 bytes
    z:\curl-7.32.0\curl-7.32.0\lib\multi.c (1478): libcurld.dll!multi_runsingle + 0x10 bytes
    z:\curl-7.32.0\curl-7.32.0\lib\multi.c (1751): libcurld.dll!curl_multi_perform + 0x15 bytes
    z:\curl-7.32.0\curl-7.32.0\lib\easy.c (554): libcurld.dll!curl_easy_perform + 0x11 bytes
    f:\dd\vctools\crt_bld\self_x86\crt\src\threadex.c (314): MSVCR100D.dll!_callthreadstartex + 0xF bytes
    f:\dd\vctools\crt_bld\self_x86\crt\src\threadex.c (297): MSVCR100D.dll!_threadstartex
    0x7671336A (File and line number not available): kernel32.dll!BaseThreadInitThunk + 0x12 bytes
    0x77079F72 (File and line number not available): ntdll.dll!RtlInitializeExceptionChain + 0x63 bytes
    0x77079F45 (File and line number not available): ntdll.dll!RtlInitializeExceptionChain + 0x36 bytes
  Data:
    3C 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     <....... ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
---------- Block 85 at 0x03E244C0: 17006 bytes ----------
  Call Stack:
    z:\curl-7.32.0\curl-7.32.0\lib\sendf.c (449): libcurld.dll!Curl_client_write + 0x21 bytes
    z:\curl-7.32.0\curl-7.32.0\lib\transfer.c (705): libcurld.dll!readwrite_data + 0x16 bytes
    z:\curl-7.32.0\curl-7.32.0\lib\transfer.c (1022): libcurld.dll!Curl_readwrite + 0x19 bytes
    z:\curl-7.32.0\curl-7.32.0\lib\multi.c (1478): libcurld.dll!multi_runsingle + 0x10 bytes
    z:\curl-7.32.0\curl-7.32.0\lib\multi.c (1751): libcurld.dll!curl_multi_perform + 0x15 bytes
    z:\curl-7.32.0\curl-7.32.0\lib\easy.c (554): libcurld.dll!curl_easy_perform + 0x11 bytes
    f:\dd\vctools\crt_bld\self_x86\crt\src\threadex.c (314): MSVCR100D.dll!_callthreadstartex + 0xF bytes
    f:\dd\vctools\crt_bld\self_x86\crt\src\threadex.c (297): MSVCR100D.dll!_threadstartex
    0x7671336A (File and line number not available): kernel32.dll!BaseThreadInitThunk + 0x12 bytes
    0x77079F72 (File and line number not available): ntdll.dll!RtlInitializeExceptionChain + 0x63 bytes
    0x77079F45 (File and line number not available): ntdll.dll!RtlInitializeExceptionChain + 0x36 bytes
  Data:
    3C 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     <....... ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
    00 00 00 00    00 00 00 00    00 00 00 00    00 00 00 00     ........ ........
---
Sent from sourceforge.net because curl-tracker@cool.haxx.se is subscribed to https://sourceforge.net/p/curl/bugs/
To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/curl/admin/bugs/options.  Or, if this is a mailing list, you can unsubscribe from the mailing list.
Received on 2013-09-26

These mail archives are generated by hypermail.

donate! Page updated May 06, 2013.
web site info

File upload with ASP.NET