| 875 | } |
| 876 | |
| 877 | bool flush() |
| 878 | { |
| 879 | if(zfile.next_out && zfile.avail_out < BUFSIZE) |
| 880 | { |
| 881 | if(file->write(buf, BUFSIZE - zfile.avail_out) != int(BUFSIZE - zfile.avail_out)) |
| 882 | return false; |
| 883 | } |
| 884 | zfile.next_out = buf; |
| 885 | zfile.avail_out = BUFSIZE; |
| 886 | return true; |
| 887 | } |
| 888 | |
| 889 | int write(const void *buf, int len) |
| 890 | { |