OSDN Git Service

Refactor Config from a struct to a class.
authorChristopher Ferris <cferris@google.com>
Thu, 6 Apr 2017 02:13:03 +0000 (19:13 -0700)
committerChristopher Ferris <cferris@google.com>
Thu, 6 Apr 2017 22:30:42 +0000 (15:30 -0700)
commit2b2b25b87827102671cdd4b25c01aa22a9971a63
treed318825c7548379a307beee5b78580e51ce97a52
parente06c69d07324f3da67aa063202e698dedd831365
Refactor Config from a struct to a class.

This should make it easier to add new options, and to add options that
are complex. For example, I want to modify the behavior of
record_allocs_file so that it also enables record_allocs to a default
state.

Test: All unit tests pass.
Test: Enable the backtrace option and restart.
Change-Id: Idf5cdeed06ade3bc2c8ae39d228734bf65209b4f
15 files changed:
libc/malloc_debug/BacktraceData.cpp
libc/malloc_debug/BacktraceData.h
libc/malloc_debug/Config.cpp
libc/malloc_debug/Config.h
libc/malloc_debug/DebugData.cpp
libc/malloc_debug/FreeTrackData.cpp
libc/malloc_debug/FreeTrackData.h
libc/malloc_debug/GuardData.cpp
libc/malloc_debug/GuardData.h
libc/malloc_debug/RecordData.cpp
libc/malloc_debug/RecordData.h
libc/malloc_debug/TrackData.cpp
libc/malloc_debug/TrackData.h
libc/malloc_debug/malloc_debug.cpp
libc/malloc_debug/tests/malloc_debug_config_tests.cpp