libidav/resource.c

changeset 74
da079dc0724c
parent 70
88092b88ec00
child 75
56962faf2b42
--- a/libidav/resource.c	Thu Jan 29 11:43:41 2015 +0100
+++ b/libidav/resource.c	Sun Feb 08 16:36:32 2015 +0100
@@ -90,7 +90,6 @@
     
     char *path = util_concat_path(parent_path, name); 
     res->path = dav_session_strdup(sn, path);
-    free(path);
     
     res->href = href;
     
@@ -101,6 +100,7 @@
     if(href) {
         dav_session_cache_path(sn, sstr(path), sstr(href));
     }
+    free(path);
     
     return res;
 }
@@ -488,6 +488,7 @@
         }
     }
     
+    curl_easy_setopt(handle, CURLOPT_HTTPHEADER, NULL);
     curl_easy_setopt(handle, CURLOPT_SSL_VERIFYPEER, 0);
     curl_easy_setopt(handle, CURLOPT_CUSTOMREQUEST, NULL);
     curl_easy_setopt(handle, CURLOPT_PUT, 0L);

mercurial