diff options
author | Pavel P <pavlov.pavel@gmail.com> | 2020-04-25 17:24:12 +0600 |
---|---|---|
committer | Hans Kristian Rosbach <hk-github@circlestorm.org> | 2020-06-20 09:11:11 +0200 |
commit | 59e860cb44840eee43ca84422a5ee469d240def6 (patch) | |
tree | a0b58960a74ddae66fca90176bda63a9a43ead60 /gzlib.c | |
parent | c4aab203deb2879fa5664cfbc8a1cc37a3cdcad2 (diff) |
Fixed casting warnings
Diffstat (limited to 'gzlib.c')
-rw-r--r-- | gzlib.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -136,7 +136,7 @@ static gzFile gz_open(const void *path, int fd, const char *mode) { /* save the path name for error messages */ #ifdef WIDECHAR if (fd == -2) { - len = wcstombs(NULL, path, 0); + len = wcstombs(NULL, (const wchar_t *)path, 0); if (len == (size_t)-1) len = 0; } else @@ -150,7 +150,7 @@ static gzFile gz_open(const void *path, int fd, const char *mode) { #ifdef WIDECHAR if (fd == -2) if (len) { - wcstombs(state->path, path, len + 1); + wcstombs(state->path, (const wchar_t *)path, len + 1); } else { *(state->path) = 0; } @@ -182,7 +182,7 @@ static gzFile gz_open(const void *path, int fd, const char *mode) { /* open the file with the appropriate flags (or just use fd) */ state->fd = fd > -1 ? fd : ( #if defined(_WIN32) - fd == -2 ? _wopen(path, oflag, 0666) : + fd == -2 ? _wopen((const wchar_t *)path, oflag, 0666) : #elif __CYGWIN__ fd == -2 ? open(state->path, oflag, 0666) : #endif |