aboutsummaryrefslogtreecommitdiffstats
path: root/library/cpp/yson/detail.h
diff options
context:
space:
mode:
authorermolovd <ermolovd@yandex-team.com>2022-09-12 18:03:23 +0300
committerermolovd <ermolovd@yandex-team.com>2022-09-12 18:03:23 +0300
commit2c619590073f5a8e9cc36236dd860e9dc0db9466 (patch)
treea4f537e2367167d7508cc666f929f865d3059ff8 /library/cpp/yson/detail.h
parentd10e754f29b3fb9da979424166b08e8472a1637b (diff)
downloadydb-2c619590073f5a8e9cc36236dd860e9dc0db9466.tar.gz
fix out of boundary read
Diffstat (limited to 'library/cpp/yson/detail.h')
-rw-r--r--library/cpp/yson/detail.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/library/cpp/yson/detail.h b/library/cpp/yson/detail.h
index 27f5e8ffff..96b35f965c 100644
--- a/library/cpp/yson/detail.h
+++ b/library/cpp/yson/detail.h
@@ -214,7 +214,7 @@ namespace NYson {
}
bool ReadVarint32Fallback(ui32* value) {
- if (BeginByte() + MaxVarint32Bytes <= EndByte() ||
+ if (BeginByte() + MaxVarintBytes <= EndByte() ||
// Optimization: If the Varint ends at exactly the end of the buffer,
// we can detect that and still use the fast path.
(BeginByte() < EndByte() && !(EndByte()[-1] & 0x80)))