Using fdopen() is a more correct way to implement the CURLOPT_NEW_FILE_PREMS

file.c, but the debug interface was missing.  This adds the routines needed
to make the memory debuging work for fdopen().
This commit is contained in:
James Housley 2007-06-28 11:11:29 +00:00
parent d500c468fc
commit aed0cc6f2a
4 changed files with 16 additions and 3 deletions

View file

@ -231,8 +231,7 @@ static CURLcode file_upload(struct connectdata *conn)
failf(data, "Can't open %s for writing", file->path);
return CURLE_WRITE_ERROR;
}
close(fd);
fp = fopen(file->path, "wb");
fp = fdopen(fd, "wb");
}
if(!fp) {