diff options
author | Marri Devender Rao <devenrao@in.ibm.com> | 2018-11-12 07:45:54 -0600 |
---|---|---|
committer | Brad Bishop <bradleyb@fuzziesquirrel.com> | 2019-01-22 21:57:01 +0000 |
commit | 0deb287cc1cd0acccc38e9333a87842134e87be3 (patch) | |
tree | 39657b4f568909f08ef25add7906fd9bf42bddc5 /dump_manager.cpp | |
parent | e57ee7623b4e4a5e6987879548ce4f201eabe685 (diff) | |
download | phosphor-debug-collector-0deb287cc1cd0acccc38e9333a87842134e87be3.tar.gz phosphor-debug-collector-0deb287cc1cd0acccc38e9333a87842134e87be3.zip |
Refactor to pass errors to watch through config YAML
Add errors to watch for through error YAML file
Add support for checkstop error type
Tested:
Generating dumps for elog, core, checkstop type errors.
Change-Id: Idd00ace2e3d0c472a74ec142e6d150e55e843a6f
Signed-off-by: Marri Devender Rao <devenrao@in.ibm.com>
Diffstat (limited to 'dump_manager.cpp')
-rw-r--r-- | dump_manager.cpp | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/dump_manager.cpp b/dump_manager.cpp index d9326e0..21fca8a 100644 --- a/dump_manager.cpp +++ b/dump_manager.cpp @@ -40,12 +40,6 @@ uint32_t Manager::createDump() uint32_t Manager::captureDump(Type type, const std::vector<std::string>& fullPaths) { - // Type to dreport type string map - static const std::map<Type, std::string> typeMap = { - {Type::ApplicationCored, "core"}, - {Type::UserRequested, "user"}, - {Type::InternalFailure, "elog"}}; - // Get Dump size. auto size = getAllowedSize(); @@ -58,7 +52,7 @@ uint32_t Manager::captureDump(Type type, dumpPath /= id; // get dreport type map entry - auto tempType = typeMap.find(type); + auto tempType = TypeMap.find(type); execl("/usr/bin/dreport", "dreport", "-d", dumpPath.c_str(), "-i", id.c_str(), "-s", std::to_string(size).c_str(), "-q", "-v", "-p", |