____________________________________________________________ Write init record to the backup file
| 766 | // Write init record to the backup file |
| 767 | // |
| 768 | void MVOL_init_write(const char* file_name) |
| 769 | { |
| 770 | BurpGlobals* tdgbl = BurpGlobals::getSpecific(); |
| 771 | |
| 772 | mvol_init_write(tdgbl, file_name, &tdgbl->blk_io_cnt, &tdgbl->blk_io_ptr); |
| 773 | |
| 774 | tdgbl->gbl_io_cnt = ZC_BUFSIZE; |
| 775 | tdgbl->gbl_io_ptr = tdgbl->gbl_compress_buffer; |
| 776 | |
| 777 | #ifdef HAVE_ZLIB_H |
| 778 | if (tdgbl->gbl_sw_zip) |
| 779 | { |
| 780 | z_stream& strm = tdgbl->gbl_stream; |
| 781 | |
| 782 | strm.zalloc = Firebird::ZLib::allocFunc; |
| 783 | strm.zfree = Firebird::ZLib::freeFunc; |
| 784 | strm.opaque = Z_NULL; |
| 785 | checkCompression(); |
| 786 | int ret = zlib().deflateInit(&strm, Z_DEFAULT_COMPRESSION); |
| 787 | if (ret != Z_OK) |
| 788 | BURP_error(384, true, SafeArg() << ret); |
| 789 | strm.next_out = Z_NULL; |
| 790 | } |
| 791 | #endif |
| 792 | } |
| 793 | |
| 794 | void mvol_init_write(BurpGlobals* tdgbl, const char* file_name, int* cnt, UCHAR** ptr) |
| 795 | { |
nothing calls this directly
no test coverage detected