Ignore invalid parameter error in crash service process

This commit is contained in:
Cheng Zhao 2016-05-23 08:59:34 +09:00
parent 4c531e909b
commit 13b4c8bb06
2 changed files with 8 additions and 5 deletions

View file

@ -20,6 +20,11 @@ const char kApplicationName[] = "application-name";
const wchar_t kPipeNameFormat[] = L"\\\\.\\pipe\\$1 Crash Service"; const wchar_t kPipeNameFormat[] = L"\\\\.\\pipe\\$1 Crash Service";
const wchar_t kStandardLogFile[] = L"operation_log.txt"; const wchar_t kStandardLogFile[] = L"operation_log.txt";
void InvalidParameterHandler(const wchar_t*, const wchar_t*, const wchar_t*,
unsigned int, uintptr_t) {
// noop.
}
bool GetCrashServiceDirectory(const std::wstring& application_name, bool GetCrashServiceDirectory(const std::wstring& application_name,
base::FilePath* dir) { base::FilePath* dir) {
base::FilePath temp_dir; base::FilePath temp_dir;
@ -37,6 +42,9 @@ bool GetCrashServiceDirectory(const std::wstring& application_name,
} // namespace. } // namespace.
int Main(const wchar_t* cmd) { int Main(const wchar_t* cmd) {
// Ignore invalid parameter errors.
_set_invalid_parameter_handler(InvalidParameterHandler);
// Initialize all Chromium things. // Initialize all Chromium things.
base::AtExitManager exit_manager; base::AtExitManager exit_manager;
base::CommandLine::Init(0, NULL); base::CommandLine::Init(0, NULL);

View file

@ -23,11 +23,6 @@ describe('crash-reporter module', function () {
w.destroy() w.destroy()
}) })
// It is not working on 64bit Windows.
if (process.platform === 'win32' && process.arch === 'x64') {
return
}
if (process.mas) { if (process.mas) {
return return
} }