browser/app/winlauncher/ErrorHandler.cpp
author Sylvestre Ledru <sledru@mozilla.com>
Fri, 30 Nov 2018 11:46:48 +0100
changeset 448947 6f3709b3878117466168c40affa7bca0b60cf75b
parent 447352 5660a1cd0e25d0a179cc6ed1dbac9158994d3990
child 453976 006df494925adbd6ad79a3281b78dcb506939b8b
permissions -rw-r--r--
Bug 1511181 - Reformat everything to the Google coding style r=ehsan a=clang-format # ignore-this-changeset

/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/* vim: set ts=8 sts=2 et sw=2 tw=80: */
/* This Source Code Form is subject to the terms of the Mozilla Public
 * License, v. 2.0. If a copy of the MPL was not distributed with this
 * file, You can obtain one at https://mozilla.org/MPL/2.0/. */

#include "ErrorHandler.h"

namespace mozilla {

void HandleLauncherError(const LauncherError& aError) {
  // This is a placeholder error handler. We'll add telemetry and a fallback
  // error log in future revisions.
  WindowsError::UniqueString msg = aError.mError.AsString();
  if (!msg) {
    return;
  }

  ::MessageBoxW(nullptr, msg.get(), L"Firefox", MB_OK | MB_ICONERROR);
}

}  // namespace mozilla