Coverage Report

Created: 2018-09-25 14:53

/src/mozilla-central/dom/media/gmp/GMPCrashHelperHolder.cpp
Line
Count
Source (jump to first uncovered line)
1
/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2
/* vim: set ts=8 sts=2 et sw=2 tw=80: */
3
/* This Source Code Form is subject to the terms of the Mozilla Public
4
 * License, v. 2.0. If a copy of the MPL was not distributed with this file,
5
 * You can obtain one at http://mozilla.org/MPL/2.0/. */
6
7
#include "GMPCrashHelperHolder.h"
8
#include "GMPService.h"
9
#include "mozilla/RefPtr.h"
10
#include "nsPIDOMWindow.h"
11
#include "mozilla/ipc/ProtocolUtils.h"
12
13
namespace mozilla {
14
15
void
16
GMPCrashHelperHolder::SetCrashHelper(GMPCrashHelper* aHelper)
17
0
{
18
0
  mCrashHelper = aHelper;
19
0
}
20
21
GMPCrashHelper*
22
GMPCrashHelperHolder::GetCrashHelper()
23
0
{
24
0
  return mCrashHelper;
25
0
}
26
27
void
28
GMPCrashHelperHolder::MaybeDisconnect(bool aAbnormalShutdown)
29
0
{
30
0
  if (!aAbnormalShutdown) {
31
0
    RefPtr<gmp::GeckoMediaPluginService> service(gmp::GeckoMediaPluginService::GetGeckoMediaPluginService());
32
0
    service->DisconnectCrashHelper(GetCrashHelper());
33
0
  }
34
0
}
35
36
} // namespace mozilla