projects
/
platform
/
upstream
/
curl.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
4e4b6de
)
Avoid creating garbage on an OOM error
author
Dan Fandrich
<dan@coneharvesters.com>
Tue, 18 Nov 2008 19:58:44 +0000
(19:58 +0000)
committer
Dan Fandrich
<dan@coneharvesters.com>
Tue, 18 Nov 2008 19:58:44 +0000
(19:58 +0000)
lib/formdata.c
patch
|
blob
|
history
diff --git
a/lib/formdata.c
b/lib/formdata.c
index
483c9f8
..
08ccf4d
100644
(file)
--- a/
lib/formdata.c
+++ b/
lib/formdata.c
@@
-1211,8
+1211,11
@@
CURLcode Curl_getFormData(struct FormData **finalform,
char *filebasename= NULL;
if(!file->showfilename) {
filebasename = strippath(file->contents);
- if(!filebasename)
+ if(!filebasename) {
+ Curl_formclean(&firstform);
+ free(boundary);
return CURLE_OUT_OF_MEMORY;
+ }
}
result = AddFormDataf(&form, &size,