diff options
author | Victor Costan <pwnall@chromium.org> | 2022-01-10 18:01:30 +0000 |
---|---|---|
committer | Victor Costan <pwnall@chromium.org> | 2022-01-10 18:01:30 +0000 |
commit | 1b51a3a96821e5fd5175288724c95c1bde57b2f0 (patch) | |
tree | 739307d47566ee5ca38c31e92194bdeddfd0c5cd /util/coding.cc | |
parent | a797000713ddf9ba44e261df7c98cf12caf53722 (diff) | |
parent | 3ab94e7da853e1c507e7ce5bcf48a6b887625f62 (diff) | |
download | leveldb-1b51a3a96821e5fd5175288724c95c1bde57b2f0.tar.gz leveldb-1b51a3a96821e5fd5175288724c95c1bde57b2f0.zip |
Merge pull request #506 from lingbin:fix_issue_505
PiperOrigin-RevId: 420787858
Diffstat (limited to 'util/coding.cc')
-rw-r--r-- | util/coding.cc | 10 |
1 files changed, 0 insertions, 10 deletions
diff --git a/util/coding.cc b/util/coding.cc index df3fa10..a8f8af8 100644 --- a/util/coding.cc +++ b/util/coding.cc @@ -142,16 +142,6 @@ bool GetVarint64(Slice* input, uint64_t* value) { } } -const char* GetLengthPrefixedSlice(const char* p, const char* limit, - Slice* result) { - uint32_t len; - p = GetVarint32Ptr(p, limit, &len); - if (p == nullptr) return nullptr; - if (p + len > limit) return nullptr; - *result = Slice(p, len); - return p + len; -} - bool GetLengthPrefixedSlice(Slice* input, Slice* result) { uint32_t len; if (GetVarint32(input, &len) && input->size() >= len) { |