Revision 440621aab8e2669d5f74985780ed1c2bec2dfbf3 authored by Sagar Vemuri on 11 July 2018, 19:24:07 UTC, committed by Facebook Github Bot on 11 July 2018, 19:28:13 UTC
Summary:
Copy data between buffers inside FilePrefetchBuffer only when chunk length is greater than 0. Otherwise AlignedBuffer was accessing memory out of its range causing crashes.

Removing the tracking of buffer length outside of `AlignedBuffer`, i.e. in `FilePrefetchBuffer` and `ReadaheadRandomAccessFile`, will follow in a separate PR, as it is not the root cause of the crash reported in #4051. (`FilePrefetchBuffer` itself has been this way from its inception, and `ReadaheadRandomAccessFile` was updated to add the buffer length at some point).

Comprehensive tests for `FilePrefetchBuffer` also to follow in a separate PR.
Pull Request resolved: https://github.com/facebook/rocksdb/pull/4100

Differential Revision: D8792590

Pulled By: sagar0

fbshipit-source-id: 3578f45761cf6884243e767f749db4016ccc93e1
1 parent 926f3a7
History
File Mode Size
advisor
dump
rdb
CMakeLists.txt -rw-r--r-- 544 bytes
Dockerfile -rw-r--r-- 81 bytes
auto_sanity_test.sh -rwxr-xr-x 2.7 KB
benchmark.sh -rwxr-xr-x 16.4 KB
benchmark_leveldb.sh -rwxr-xr-x 5.1 KB
blob_dump.cc -rw-r--r-- 3.3 KB
check_format_compatible.sh -rwxr-xr-x 4.5 KB
db_bench.cc -rw-r--r-- 813 bytes
db_bench_tool.cc -rw-r--r-- 197.4 KB
db_bench_tool_test.cc -rw-r--r-- 9.5 KB
db_crashtest.py -rw-r--r-- 13.1 KB
db_repl_stress.cc -rw-r--r-- 4.5 KB
db_sanity_test.cc -rw-r--r-- 8.4 KB
db_stress.cc -rw-r--r-- 114.6 KB
dbench_monitor -rwxr-xr-x 2.6 KB
generate_random_db.sh -rwxr-xr-x 734 bytes
ldb.cc -rw-r--r-- 572 bytes
ldb_cmd.cc -rw-r--r-- 96.4 KB
ldb_cmd_impl.h -rw-r--r-- 14.1 KB
ldb_cmd_test.cc -rw-r--r-- 1.8 KB
ldb_test.py -rw-r--r-- 24.4 KB
ldb_tool.cc -rw-r--r-- 4.6 KB
pflag -rwxr-xr-x 4.0 KB
reduce_levels_test.cc -rw-r--r-- 5.2 KB
regression_test.sh -rwxr-xr-x 15.8 KB
report_lite_binary_size.sh -rwxr-xr-x 1.2 KB
rocksdb_dump_test.sh -rwxr-xr-x 364 bytes
run_flash_bench.sh -rwxr-xr-x 13.5 KB
run_leveldb.sh -rwxr-xr-x 6.2 KB
sample-dump.dmp -rw-r--r-- 100 bytes
sst_dump.cc -rw-r--r-- 581 bytes
sst_dump_test.cc -rw-r--r-- 6.4 KB
sst_dump_tool.cc -rw-r--r-- 23.7 KB
sst_dump_tool_imp.h -rw-r--r-- 2.8 KB
verify_random_db.sh -rwxr-xr-x 1.0 KB
write_stress.cc -rw-r--r-- 10.9 KB
write_stress_runner.py -rw-r--r-- 2.3 KB

back to top