From 3be8f5c6a532dc7a448dcb5516725613270daff5 Mon Sep 17 00:00:00 2001 From: "jackson.dengky" Date: Fri, 7 Mar 2025 16:38:16 +0800 Subject: [PATCH] bugfix(xlog) : Fixed compilation error if XLOG_NO_CRYPT macro was defined / enabled This reverts commit 038649641728c6d92a1c559f285ac82936301ef7. --- mars/xlog/crypt/log_crypt.cc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/mars/xlog/crypt/log_crypt.cc b/mars/xlog/crypt/log_crypt.cc index 31c4474d9..06ee06808 100644 --- a/mars/xlog/crypt/log_crypt.cc +++ b/mars/xlog/crypt/log_crypt.cc @@ -41,6 +41,7 @@ namespace xlog { const static int TEA_BLOCK_LEN = 8; +#ifndef XLOG_NO_CRYPT static void __TeaEncrypt(uint32_t* v, uint32_t* k) { uint32_t v0 = v[0], v1 = v[1], sum = 0, i; const static uint32_t delta = 0x9e3779b9; @@ -53,6 +54,7 @@ static void __TeaEncrypt(uint32_t* v, uint32_t* k) { v[0] = v0; v[1] = v1; } +#endif static uint16_t __GetSeq(bool _is_async) { if (!_is_async) {