https://github.com/facebook/rocksdb
Revision 004237e62790320d8e630456cbeb6f4a1f3579c2 authored by Andrew Kryczka on 07 December 2017, 19:07:44 UTC, committed by Andrew Kryczka on 07 December 2017, 19:47:51 UTC
Summary:
error message was

```
==3095==ERROR: AddressSanitizer: stack-use-after-scope on address 0x7ffd18216c40 at pc 0x0000005edda1 bp 0x7ffd18215550 sp 0x7ffd18214d00
...
Address 0x7ffd18216c40 is located in stack of thread T0 at offset 1952 in frame
     #0 internal_repo_rocksdb/db_compaction_test.cc:1520 rocksdb::DBCompactionTest_DeleteFileRangeFileEndpointsOverlapBug_Test::TestBody()
```

It was unsafe to have slices referring to the temporary string objects' buffers, as those strings were destroyed before the slices were used. Fixed it by assigning the strings returned by `Key()` to local variables.
Closes https://github.com/facebook/rocksdb/pull/3238

Differential Revision: D6507864

Pulled By: ajkr

fbshipit-source-id: dd07de1a0070c6748c1ab4f3d7bd31f9a81889d0
1 parent ea3a279
History
Tip revision: 004237e62790320d8e630456cbeb6f4a1f3579c2 authored by Andrew Kryczka on 07 December 2017, 19:07:44 UTC
fix ASAN for DeleteFilesInRange test case
Tip revision: 004237e
File Mode Size
buckifier
build_tools
cache
cmake
coverage
db
docs
env
examples
hdfs
include
java
memtable
monitoring
options
port
table
third-party
tools
util
utilities
.clang-format -rw-r--r-- 138 bytes
.gitignore -rw-r--r-- 705 bytes
.travis.yml -rw-r--r-- 2.7 KB
AUTHORS -rw-r--r-- 322 bytes
CMakeLists.txt -rw-r--r-- 31.2 KB
CONTRIBUTING.md -rw-r--r-- 607 bytes
COPYING -rw-r--r-- 17.7 KB
DEFAULT_OPTIONS_HISTORY.md -rw-r--r-- 1.5 KB
DUMP_FORMAT.md -rw-r--r-- 763 bytes
HISTORY.md -rw-r--r-- 51.8 KB
INSTALL.md -rw-r--r-- 5.8 KB
LANGUAGE-BINDINGS.md -rw-r--r-- 814 bytes
LICENSE.Apache -rw-r--r-- 11.1 KB
LICENSE.leveldb -rw-r--r-- 1.5 KB
Makefile -rw-r--r-- 61.6 KB
README.md -rw-r--r-- 1.4 KB
ROCKSDB_LITE.md -rw-r--r-- 1.0 KB
TARGETS -rw-r--r-- 26.0 KB
USERS.md -rw-r--r-- 5.1 KB
Vagrantfile -rw-r--r-- 877 bytes
WINDOWS_PORT.md -rw-r--r-- 12.5 KB
appveyor.yml -rw-r--r-- 428 bytes
issue_template.md -rw-r--r-- 243 bytes
src.mk -rw-r--r-- 26.7 KB
thirdparty.inc -rw-r--r-- 7.3 KB

README.md

back to top