Commit 8ad7a67e authored by Marko Mäkelä's avatar Marko Mäkelä

Bug#16400920 INNODB TRIES TO PASS EMPTY BUFFER TO ZLIB, GETS Z_BUF_ERROR

page_zip_compress_node_ptrs(): Do not attempt to invoke deflate() with
c_stream->avail_in, because it will result in Z_BUF_ERROR (and
page_zip_compress() failure and unnecessary further splits of the node
pointer page). A node pointer record can have empty payload, provided
that all key fields are empty.

Approved by Jimmy Yang
parent f032a9ac
2013-02-27 The InnoDB Team
* page/page0zip.c:
Fix Bug#16400920 INNODB TRIES TO PASS EMPTY BUFFER TO ZLIB,
GETS Z_BUF_ERROR
2013-01-21 The InnoDB Team
* buf/buf0buf.cc, handler/ha_innodb.cc:
* buf/buf0buf.c, handler/ha_innodb.cc:
Fix Bug#16067973 DROP TABLE IS SLOW WHEN IT DECOMPRESSES
COMPRESSED-ONLY PAGES
......
/*****************************************************************************
Copyright (c) 2005, 2011, Oracle and/or its affiliates. All Rights Reserved.
Copyright (c) 2005, 2013, Oracle and/or its affiliates. All Rights Reserved.
This program is free software; you can redistribute it and/or modify it under
the terms of the GNU General Public License as published by the Free Software
......@@ -837,12 +837,13 @@ page_zip_compress_node_ptrs(
c_stream->next_in = (byte*) rec;
c_stream->avail_in = rec_offs_data_size(offsets)
- REC_NODE_PTR_SIZE;
ut_ad(c_stream->avail_in);
if (c_stream->avail_in) {
err = deflate(c_stream, Z_NO_FLUSH);
if (UNIV_UNLIKELY(err != Z_OK)) {
break;
}
}
ut_ad(!c_stream->avail_in);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment