diff options
author | dartraiden <wowemuh@gmail.com> | 2023-12-10 18:22:53 +0300 |
---|---|---|
committer | dartraiden <wowemuh@gmail.com> | 2023-12-10 18:25:13 +0300 |
commit | 2ae0fc7299825cc561197d3f23c90e52ae8db58b (patch) | |
tree | 95fa8e7eb16cdff25b74d2d0ec033e667d4fd2c5 /libs/libcurl/src/formdata.c | |
parent | 76646f7a6d85fd5cdef2a610e0711bf4a9d8fdf3 (diff) |
libcurl: update to 8.5.0
Diffstat (limited to 'libs/libcurl/src/formdata.c')
-rw-r--r-- | libs/libcurl/src/formdata.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/libs/libcurl/src/formdata.c b/libs/libcurl/src/formdata.c index 337cd3b2c5..88901c6bdd 100644 --- a/libs/libcurl/src/formdata.c +++ b/libs/libcurl/src/formdata.c @@ -603,9 +603,9 @@ CURLFORMcode FormAdd(struct curl_httppost **httppost, app passed in a bad combo, so we better check for that first. */
if(form->name) {
/* copy name (without strdup; possibly not null-terminated) */
- form->name = Curl_memdup(form->name, form->namelength?
- form->namelength:
- strlen(form->name) + 1);
+ form->name = Curl_strndup(form->name, form->namelength?
+ form->namelength:
+ strlen(form->name));
}
if(!form->name) {
return_value = CURL_FORMADD_MEMORY;
@@ -792,7 +792,7 @@ static CURLcode setname(curl_mimepart *part, const char *name, size_t len) /* wrap call to fseeko so it matches the calling convention of callback */
static int fseeko_wrapper(void *stream, curl_off_t offset, int whence)
{
-#if defined(HAVE_FSEEKO)
+#if defined(HAVE_FSEEKO) && defined(HAVE_DECL_FSEEKO)
return fseeko(stream, (off_t)offset, whence);
#elif defined(HAVE__FSEEKI64)
return _fseeki64(stream, (__int64)offset, whence);
|