diff options
author | Andreas Gampe <agampe@google.com> | 2015-02-24 15:50:19 -0800 |
---|---|---|
committer | Andreas Gampe <agampe@google.com> | 2015-02-24 22:30:47 -0800 |
commit | a6dfdae1cffc78f9791348b2e1dc8f4c6c3f7128 (patch) | |
tree | 2b07c1cc94212963ec38a2c0a784a26fe1522194 /runtime/utils.h | |
parent | 96ac49a260223dc00291116daa63d7489c52bb0f (diff) | |
download | art-a6dfdae1cffc78f9791348b2e1dc8f4c6c3f7128.tar.gz art-a6dfdae1cffc78f9791348b2e1dc8f4c6c3f7128.tar.bz2 art-a6dfdae1cffc78f9791348b2e1dc8f4c6c3f7128.zip |
ART: Print maps directly to log
Do not read proc maps into a string before printing them later back
to the log. In low-memory situations this can cause a bad_alloc.
External bug: http://b.android.com/153990
Bug: 19494774
Change-Id: Ie63d8788afe8c9da65b30b2f89c50d3dbb820755
Diffstat (limited to 'runtime/utils.h')
-rw-r--r-- | runtime/utils.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/runtime/utils.h b/runtime/utils.h index 3191e7d305..698d686afd 100644 --- a/runtime/utils.h +++ b/runtime/utils.h @@ -410,6 +410,7 @@ std::string JniLongName(mirror::ArtMethod* m) SHARED_LOCKS_REQUIRED(Locks::mutator_lock_); bool ReadFileToString(const std::string& file_name, std::string* result); +bool PrintFileToLog(const std::string& file_name, LogSeverity level); // Returns the current date in ISO yyyy-mm-dd hh:mm:ss format. std::string GetIsoDate(); |