add compress

This commit is contained in:
Yihao Deng 2024-04-17 08:59:38 +00:00
parent f8dcf806d2
commit 2547f29de9
1 changed files with 2 additions and 1 deletions

View File

@ -1600,6 +1600,7 @@ int32_t valueDecode(void* value, int32_t vlen, int64_t* ttl, char** dest) {
if (streamStateValueIsStale(p)) { if (streamStateValueIsStale(p)) {
goto _EXCEPT; goto _EXCEPT;
} }
p = taosDecodeFixedI64(p, &key.unixTimestamp); p = taosDecodeFixedI64(p, &key.unixTimestamp);
p = taosDecodeFixedI32(p, &key.len); p = taosDecodeFixedI32(p, &key.len);
if (key.len == 0) { if (key.len == 0) {
@ -1633,13 +1634,13 @@ int32_t valueDecode(void* value, int32_t vlen, int64_t* ttl, char** dest) {
goto _EXCEPT; goto _EXCEPT;
} }
key.len = rawLen; key.len = rawLen;
taosMemoryFree(pCompressData);
if (dest) { if (dest) {
*dest = buf; *dest = buf;
} else { } else {
taosMemoryFree(buf); taosMemoryFree(buf);
} }
taosMemoryFree(pCompressData);
} else { } else {
if (dest != NULL) { if (dest != NULL) {
p = taosDecodeBinary(p, (void**)dest, key.len); p = taosDecodeBinary(p, (void**)dest, key.len);