-- see zlib.h -- */
(file, size)
| 312 | |
| 313 | /* -- see zlib.h -- */ |
| 314 | int ZEXPORT gzbuffer(file, size) |
| 315 | gzFile file; |
| 316 | unsigned size; |
| 317 | { |
| 318 | gz_statep state; |
| 319 | |
| 320 | /* get internal structure and check integrity */ |
| 321 | if (file == NULL) |
| 322 | return -1; |
| 323 | state = (gz_statep)file; |
| 324 | if (state->mode != GZ_READ && state->mode != GZ_WRITE) |
| 325 | return -1; |
| 326 | |
| 327 | /* make sure we haven't already allocated memory */ |
| 328 | if (state->size != 0) |
| 329 | return -1; |
| 330 | |
| 331 | /* check and set requested size */ |
| 332 | if (size < 2) |
| 333 | size = 2; /* need two bytes to check magic header */ |
| 334 | state->want = size; |
| 335 | return 0; |
| 336 | } |
| 337 | |
| 338 | /* -- see zlib.h -- */ |
| 339 | int ZEXPORT gzrewind(file) |
nothing calls this directly
no outgoing calls
no test coverage detected