Skip to content

Commit

Permalink
fix: hincrby bug (#396)
Browse files Browse the repository at this point in the history
  • Loading branch information
dingxiaoshuai123 authored Jul 31, 2024
1 parent 2e74982 commit ee3d1f5
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/storage/src/redis_hashes.cc
Original file line number Diff line number Diff line change
Expand Up @@ -279,7 +279,8 @@ Status Redis::HIncrby(const Slice& key, const Slice& field, int64_t value, int64
batch->Put(kMetaCF, base_meta_key.Encode(), meta_value);
HashesDataKey hashes_data_key(key, version, field);
Int64ToStr(value_buf, 32, value);
batch->Put(kHashesDataCF, hashes_data_key.Encode(), value_buf);
BaseDataValue internal_value(value_buf);
batch->Put(kHashesDataCF, hashes_data_key.Encode(), internal_value.Encode());
*ret = value;
} else {
version = parsed_hashes_meta_value.Version();
Expand Down

0 comments on commit ee3d1f5

Please sign in to comment.