mirror of
https://github.com/curl/curl.git
synced 2026-07-30 19:28:03 +03:00
curl-compilers: enable -Wbad-function-cast on GCC
This warning used to be enabled only for clang as it's a bit stricter on GCC. Silence the remaining occurrences and enable it on GCC too. Closes https://github.com/curl/curl/pull/2747
This commit is contained in:
parent
d5c0351055
commit
60776a0515
5 changed files with 12 additions and 5 deletions
|
|
@ -118,10 +118,12 @@ int tool_seek_cb(void *userdata, curl_off_t offset, int whence)
|
|||
|
||||
int tool_ftruncate64(int fd, curl_off_t where)
|
||||
{
|
||||
intptr_t handle = _get_osfhandle(fd);
|
||||
|
||||
if(_lseeki64(fd, where, SEEK_SET) < 0)
|
||||
return -1;
|
||||
|
||||
if(!SetEndOfFile((HANDLE)_get_osfhandle(fd)))
|
||||
if(!SetEndOfFile((HANDLE)handle))
|
||||
return -1;
|
||||
|
||||
return 0;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue