mirror of
https://github.com/MariaDB/server.git
synced 2025-01-16 20:12:31 +01:00
MDEV-9000: storage/xtradb/fil/fil0pagecompress.cc fails to compile on i686-linux
Incorrect parameter type was used. Fixed by casting data types to correct ones.
This commit is contained in:
parent
8a09280dc1
commit
f2ab9abbd6
2 changed files with 14 additions and 6 deletions
|
@ -277,7 +277,11 @@ fil_compress_page(
|
||||||
{
|
{
|
||||||
snappy_status cstatus;
|
snappy_status cstatus;
|
||||||
|
|
||||||
cstatus = snappy_compress((const char *)buf, len, (char *)(out_buf+header_len), &write_size);
|
cstatus = snappy_compress(
|
||||||
|
(const char *)buf,
|
||||||
|
(size_t)len,
|
||||||
|
(char *)(out_buf+header_len),
|
||||||
|
(size_t*)&write_size);
|
||||||
|
|
||||||
if (cstatus != SNAPPY_OK || write_size > UNIV_PAGE_SIZE-header_len) {
|
if (cstatus != SNAPPY_OK || write_size > UNIV_PAGE_SIZE-header_len) {
|
||||||
if (space->printed_compression_failure == false) {
|
if (space->printed_compression_failure == false) {
|
||||||
|
@ -645,9 +649,9 @@ fil_decompress_page(
|
||||||
|
|
||||||
cstatus = snappy_uncompress(
|
cstatus = snappy_uncompress(
|
||||||
(const char *)(buf+header_len),
|
(const char *)(buf+header_len),
|
||||||
actual_size,
|
(size_t)actual_size,
|
||||||
(char *)in_buf,
|
(char *)in_buf,
|
||||||
&olen);
|
(size_t*)&olen);
|
||||||
|
|
||||||
if (cstatus != SNAPPY_OK || (olen == 0 || olen > UNIV_PAGE_SIZE)) {
|
if (cstatus != SNAPPY_OK || (olen == 0 || olen > UNIV_PAGE_SIZE)) {
|
||||||
ib_logf(IB_LOG_LEVEL_ERROR,
|
ib_logf(IB_LOG_LEVEL_ERROR,
|
||||||
|
|
|
@ -277,7 +277,11 @@ fil_compress_page(
|
||||||
{
|
{
|
||||||
snappy_status cstatus;
|
snappy_status cstatus;
|
||||||
|
|
||||||
cstatus = snappy_compress((const char *)buf, len, (char *)(out_buf+header_len), &write_size);
|
cstatus = snappy_compress(
|
||||||
|
(const char *)buf,
|
||||||
|
(size_t)len,
|
||||||
|
(char *)(out_buf+header_len),
|
||||||
|
(size_t*)&write_size);
|
||||||
|
|
||||||
if (cstatus != SNAPPY_OK || write_size > UNIV_PAGE_SIZE-header_len) {
|
if (cstatus != SNAPPY_OK || write_size > UNIV_PAGE_SIZE-header_len) {
|
||||||
if (space->printed_compression_failure == false) {
|
if (space->printed_compression_failure == false) {
|
||||||
|
@ -644,9 +648,9 @@ fil_decompress_page(
|
||||||
|
|
||||||
cstatus = snappy_uncompress(
|
cstatus = snappy_uncompress(
|
||||||
(const char *)(buf+header_len),
|
(const char *)(buf+header_len),
|
||||||
actual_size,
|
(size_t)actual_size,
|
||||||
(char *)in_buf,
|
(char *)in_buf,
|
||||||
&olen);
|
(size_t*)&olen);
|
||||||
|
|
||||||
if (cstatus != SNAPPY_OK || (olen == 0 || olen > UNIV_PAGE_SIZE)) {
|
if (cstatus != SNAPPY_OK || (olen == 0 || olen > UNIV_PAGE_SIZE)) {
|
||||||
ib_logf(IB_LOG_LEVEL_ERROR,
|
ib_logf(IB_LOG_LEVEL_ERROR,
|
||||||
|
|
Loading…
Reference in a new issue