7003fba5f2
Some testing environments can have a test that is sending many
thousands of messages to the log. When this type of process crashes
all of these log messages are captured and can cause OOM errors
while creating the tombstone.
Added a test to verify the log messages are truncated. Leaving this
test disabled for now since it is inherently flaky due to having to
assume that 500 messages are in the log.
Added a test for a newline in a log message since it's somewhat
related to this change.
NOTE: The total number of messages is capped at 500, but if a message
contains multiple newlines, the total messages will exceed 500.
Counting messages this way seems to be in the spirit of the cap,
that a process logging a large message with multiple newlines does
not completely fill the tombstone log data.
Bug: 269182937
Bug: 282661754
Test: All unit tests pass.
Test: The disabled max_log_messages test passes.
Change-Id: If18e62b29f899c2c4670101b402e37762bffbec6
Merged-In: If18e62b29f899c2c4670101b402e37762bffbec6
(cherry picked from commit
|
||
---|---|---|
.. | ||
client | ||
common/include | ||
crasher | ||
handler | ||
include/debuggerd | ||
libdebuggerd | ||
proto | ||
rust/tombstoned_client | ||
seccomp_policy | ||
test_permissive_mte | ||
tombstoned | ||
.clang-format | ||
Android.bp | ||
crash_dump.cpp | ||
crash_test.cpp | ||
crash_test.h | ||
debuggerd.cpp | ||
debuggerd_benchmark.cpp | ||
debuggerd_test.cpp | ||
MODULE_LICENSE_APACHE2 | ||
OWNERS | ||
pbtombstone.cpp | ||
protocol.h | ||
TEST_MAPPING | ||
tombstone_handler.cpp | ||
tombstone_handler.h | ||
util.cpp | ||
util.h |