diff --git a/mars/xlog/crypt/decode_log_file_c_impl/CMakeLists.txt b/mars/xlog/crypt/decode_log_file_c_impl/CMakeLists.txt index 932802e8c..8dec228e3 100644 --- a/mars/xlog/crypt/decode_log_file_c_impl/CMakeLists.txt +++ b/mars/xlog/crypt/decode_log_file_c_impl/CMakeLists.txt @@ -14,4 +14,4 @@ include_directories(${CMAKE_CURRENT_SOURCE_DIR}/../../../) add_executable(decode_log_file decode_log_file.c micro-ecc-master/uECC.c) -target_link_libraries(decode_log_file libzstd_static) \ No newline at end of file +target_link_libraries(decode_log_file libzstd_static z) \ No newline at end of file diff --git a/mars/xlog/crypt/decode_log_file_c_impl/decode_log_file.c b/mars/xlog/crypt/decode_log_file_c_impl/decode_log_file.c index 059807fae..547f9cb1a 100644 --- a/mars/xlog/crypt/decode_log_file_c_impl/decode_log_file.c +++ b/mars/xlog/crypt/decode_log_file_c_impl/decode_log_file.c @@ -196,6 +196,7 @@ bool zstdDecompress(const char* compressedBytes, size_t compressedBytesSize, cha ZSTD_inBuffer input = {compressedBytes, compressedBytesSize, 0}; ZSTD_outBuffer output = {NULL, compressedBytesSize, 0}; bool done = false; + size_t lastPos = output.pos; while (!done) { if (output.pos >= uncompLength) { diff --git a/mars/xlog/src/appender.cc b/mars/xlog/src/appender.cc index 652f5949f..3da89cd9d 100644 --- a/mars/xlog/src/appender.cc +++ b/mars/xlog/src/appender.cc @@ -318,7 +318,7 @@ void XloggerAppender::Open(const XLogConfig& _config) { config_.cachedir_, config_.logdir_, config_.nameprefix_)); - thread_timeout_cache_->start_after(3 * 60 * 1000); + thread_moveold_->start_after(3 * 60 * 1000); #ifdef __APPLE__ setAttrProtectionNone(config_.cachedir_.c_str()); #endif