Add ICU message format support
[chromium-blink-merge.git] / chromecast / crash / linux / dummy_minidump_generator.cc
bloba0cea9fef971f85c19f2e32d87afada760c37d8f
1 // Copyright 2015 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #include "chromecast/crash/linux/dummy_minidump_generator.h"
7 #include "base/files/file_util.h"
8 #include "base/logging.h"
9 #include "base/threading/thread_restrictions.h"
11 namespace chromecast {
13 DummyMinidumpGenerator::DummyMinidumpGenerator(
14 const std::string& existing_minidump_path)
15 : existing_minidump_path_(existing_minidump_path) {
18 bool DummyMinidumpGenerator::Generate(const std::string& minidump_path) {
19 base::ThreadRestrictions::AssertIOAllowed();
21 // Return false if the file does not exist.
22 if (!base::PathExists(base::FilePath(existing_minidump_path_))) {
23 LOG(ERROR) << existing_minidump_path_ << " does not exist.";
24 return false;
27 LOG(INFO) << "Moving minidump from " << existing_minidump_path_ << " to "
28 << minidump_path << " for further uploading.";
29 return base::Move(base::FilePath(existing_minidump_path_),
30 base::FilePath(minidump_path));
33 } // namespace chromecast