summaryrefslogtreecommitdiff
path: root/contrib/minizip/ioapi.c
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/minizip/ioapi.c')
-rw-r--r--contrib/minizip/ioapi.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/contrib/minizip/ioapi.c b/contrib/minizip/ioapi.c
index 7f5c191..1571914 100644
--- a/contrib/minizip/ioapi.c
+++ b/contrib/minizip/ioapi.c
@@ -94,6 +94,7 @@ static int ZCALLBACK ferror_file_func OF((voidpf opaque, voidpf stream));
94 94
95static voidpf ZCALLBACK fopen_file_func (voidpf opaque, const char* filename, int mode) 95static voidpf ZCALLBACK fopen_file_func (voidpf opaque, const char* filename, int mode)
96{ 96{
97 (void)opaque;
97 FILE* file = NULL; 98 FILE* file = NULL;
98 const char* mode_fopen = NULL; 99 const char* mode_fopen = NULL;
99 if ((mode & ZLIB_FILEFUNC_MODE_READWRITEFILTER)==ZLIB_FILEFUNC_MODE_READ) 100 if ((mode & ZLIB_FILEFUNC_MODE_READWRITEFILTER)==ZLIB_FILEFUNC_MODE_READ)
@@ -112,6 +113,7 @@ static voidpf ZCALLBACK fopen_file_func (voidpf opaque, const char* filename, in
112 113
113static voidpf ZCALLBACK fopen64_file_func (voidpf opaque, const void* filename, int mode) 114static voidpf ZCALLBACK fopen64_file_func (voidpf opaque, const void* filename, int mode)
114{ 115{
116 (void)opaque;
115 FILE* file = NULL; 117 FILE* file = NULL;
116 const char* mode_fopen = NULL; 118 const char* mode_fopen = NULL;
117 if ((mode & ZLIB_FILEFUNC_MODE_READWRITEFILTER)==ZLIB_FILEFUNC_MODE_READ) 119 if ((mode & ZLIB_FILEFUNC_MODE_READWRITEFILTER)==ZLIB_FILEFUNC_MODE_READ)
@@ -131,6 +133,7 @@ static voidpf ZCALLBACK fopen64_file_func (voidpf opaque, const void* filename,
131 133
132static uLong ZCALLBACK fread_file_func (voidpf opaque, voidpf stream, void* buf, uLong size) 134static uLong ZCALLBACK fread_file_func (voidpf opaque, voidpf stream, void* buf, uLong size)
133{ 135{
136 (void)opaque;
134 uLong ret; 137 uLong ret;
135 ret = (uLong)fread(buf, 1, (size_t)size, (FILE *)stream); 138 ret = (uLong)fread(buf, 1, (size_t)size, (FILE *)stream);
136 return ret; 139 return ret;
@@ -138,6 +141,7 @@ static uLong ZCALLBACK fread_file_func (voidpf opaque, voidpf stream, void* buf,
138 141
139static uLong ZCALLBACK fwrite_file_func (voidpf opaque, voidpf stream, const void* buf, uLong size) 142static uLong ZCALLBACK fwrite_file_func (voidpf opaque, voidpf stream, const void* buf, uLong size)
140{ 143{
144 (void)opaque;
141 uLong ret; 145 uLong ret;
142 ret = (uLong)fwrite(buf, 1, (size_t)size, (FILE *)stream); 146 ret = (uLong)fwrite(buf, 1, (size_t)size, (FILE *)stream);
143 return ret; 147 return ret;
@@ -145,6 +149,7 @@ static uLong ZCALLBACK fwrite_file_func (voidpf opaque, voidpf stream, const voi
145 149
146static long ZCALLBACK ftell_file_func (voidpf opaque, voidpf stream) 150static long ZCALLBACK ftell_file_func (voidpf opaque, voidpf stream)
147{ 151{
152 (void)opaque;
148 long ret; 153 long ret;
149 ret = ftell((FILE *)stream); 154 ret = ftell((FILE *)stream);
150 return ret; 155 return ret;
@@ -153,6 +158,7 @@ static long ZCALLBACK ftell_file_func (voidpf opaque, voidpf stream)
153 158
154static ZPOS64_T ZCALLBACK ftell64_file_func (voidpf opaque, voidpf stream) 159static ZPOS64_T ZCALLBACK ftell64_file_func (voidpf opaque, voidpf stream)
155{ 160{
161 (void)opaque;
156 ZPOS64_T ret; 162 ZPOS64_T ret;
157 ret = FTELLO_FUNC((FILE *)stream); 163 ret = FTELLO_FUNC((FILE *)stream);
158 return ret; 164 return ret;
@@ -160,6 +166,7 @@ static ZPOS64_T ZCALLBACK ftell64_file_func (voidpf opaque, voidpf stream)
160 166
161static long ZCALLBACK fseek_file_func (voidpf opaque, voidpf stream, uLong offset, int origin) 167static long ZCALLBACK fseek_file_func (voidpf opaque, voidpf stream, uLong offset, int origin)
162{ 168{
169 (void)opaque;
163 int fseek_origin=0; 170 int fseek_origin=0;
164 long ret; 171 long ret;
165 switch (origin) 172 switch (origin)
@@ -183,6 +190,7 @@ static long ZCALLBACK fseek_file_func (voidpf opaque, voidpf stream, uLong offs
183 190
184static long ZCALLBACK fseek64_file_func (voidpf opaque, voidpf stream, ZPOS64_T offset, int origin) 191static long ZCALLBACK fseek64_file_func (voidpf opaque, voidpf stream, ZPOS64_T offset, int origin)
185{ 192{
193 (void)opaque;
186 int fseek_origin=0; 194 int fseek_origin=0;
187 long ret; 195 long ret;
188 switch (origin) 196 switch (origin)
@@ -209,6 +217,7 @@ static long ZCALLBACK fseek64_file_func (voidpf opaque, voidpf stream, ZPOS64_T
209 217
210static int ZCALLBACK fclose_file_func (voidpf opaque, voidpf stream) 218static int ZCALLBACK fclose_file_func (voidpf opaque, voidpf stream)
211{ 219{
220 (void)opaque;
212 int ret; 221 int ret;
213 ret = fclose((FILE *)stream); 222 ret = fclose((FILE *)stream);
214 return ret; 223 return ret;
@@ -216,6 +225,7 @@ static int ZCALLBACK fclose_file_func (voidpf opaque, voidpf stream)
216 225
217static int ZCALLBACK ferror_file_func (voidpf opaque, voidpf stream) 226static int ZCALLBACK ferror_file_func (voidpf opaque, voidpf stream)
218{ 227{
228 (void)opaque;
219 int ret; 229 int ret;
220 ret = ferror((FILE *)stream); 230 ret = ferror((FILE *)stream);
221 return ret; 231 return ret;