CloudPolis / webdav-client-cpp

:cloud: C++ WebDAV Client provides easy and convenient to work with WebDAV-servers.
http://cloudpolis.github.io/webdav-client-cpp/
Other
120 stars 52 forks source link

Fix memory leaks #54

Open vitSkalicky opened 2 months ago

vitSkalicky commented 2 months ago

curl_easy_escape() and curl_unescape() allocate new memory for the char. std::string constructor copies the data from char, and the char* needs to be freed afterwards, which it was not and therefore it was leaking.

Also, Is there a reason for using curl_unescape() instead of curl_easy_unescape()?