Revert "Update to 7.44.0"
[platform/upstream/curl.git] / docs / examples / postinmemory.c
index 3afac4b..cd2bd13 100644 (file)
@@ -101,7 +101,8 @@ int main(void)
     /* always cleanup */
     curl_easy_cleanup(curl);
 
-    free(chunk.memory);
+    if(chunk.memory)
+      free(chunk.memory);
 
     /* we're done with libcurl, so clean it up */
     curl_global_cleanup();