aboutsummaryrefslogtreecommitdiff
path: root/lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.cpp
diff options
context:
space:
mode:
authorFlorian Mayer <fmayer@google.com>2022-12-20 15:20:59 -0800
committerFlorian Mayer <fmayer@google.com>2023-01-11 16:53:12 -0800
commit2426cc773a9d4d11a8ef94fc411bfe9acd7eacad (patch)
tree6832c6654acba72ad754e1413bc21fafb39190c5 /lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.cpp
parente09f6f41cae839163a877c803044d4e77318e9a4 (diff)
downloadllvm-2426cc773a9d4d11a8ef94fc411bfe9acd7eacad.zip
llvm-2426cc773a9d4d11a8ef94fc411bfe9acd7eacad.tar.gz
llvm-2426cc773a9d4d11a8ef94fc411bfe9acd7eacad.tar.bz2
Dynamically allocate scudo allocation buffer.
This is so we can increase the buffer size for finding elusive bugs. Tested by hand with this program ``` int main(int argc, char** argv) { if (argc < 2) return 1; int n = atoi(argv[1]); char* x = reinterpret_cast<char*>(malloc(1)); *((volatile char*)x) = 1; free(x); for (; n > 0; --n) { char* y = reinterpret_cast<char*>(malloc(1024)); *((volatile char*)y) = 1; free(y); } *x = 2; return 0; } ``` SCUDO_OPTIONS=allocation_ring_buffer_size=30000 ./uaf 1000000 -> no allocation trace SCUDO_OPTIONS=allocation_ring_buffer_size=30000000 ./uaf 1000000 -> allocation trace Reviewed By: hctim, eugenis Differential Revision: https://reviews.llvm.org/D140932
Diffstat (limited to 'lldb/source/Plugins/ScriptInterpreter/Python/PythonDataObjects.cpp')
0 files changed, 0 insertions, 0 deletions