From 60c83971fb19dea49beab3a02c8913f75f62ad09 Mon Sep 17 00:00:00 2001 From: wolfbeast Date: Fri, 8 Nov 2019 10:49:03 +0100 Subject: Issue #1263 - Part 1: Remove DiskSpaceWatcher --- hal/Hal.cpp | 16 ---------------- hal/Hal.h | 14 -------------- hal/fallback/FallbackDiskSpaceWatcher.cpp | 19 ------------------- hal/moz.build | 1 - hal/sandbox/SandboxHal.cpp | 12 ------------ 5 files changed, 62 deletions(-) delete mode 100644 hal/fallback/FallbackDiskSpaceWatcher.cpp (limited to 'hal') diff --git a/hal/Hal.cpp b/hal/Hal.cpp index f88efd6cc..67930c355 100644 --- a/hal/Hal.cpp +++ b/hal/Hal.cpp @@ -855,22 +855,6 @@ void FactoryReset(mozilla::dom::FactoryResetReason& aReason) PROXY_IF_SANDBOXED(FactoryReset(aReason)); } -void -StartDiskSpaceWatcher() -{ - AssertMainProcess(); - AssertMainThread(); - PROXY_IF_SANDBOXED(StartDiskSpaceWatcher()); -} - -void -StopDiskSpaceWatcher() -{ - AssertMainProcess(); - AssertMainThread(); - PROXY_IF_SANDBOXED(StopDiskSpaceWatcher()); -} - uint32_t GetTotalSystemMemory() { diff --git a/hal/Hal.h b/hal/Hal.h index 14247ee2e..5411b387a 100644 --- a/hal/Hal.h +++ b/hal/Hal.h @@ -476,20 +476,6 @@ void StartForceQuitWatchdog(hal::ShutdownMode aMode, int32_t aTimeoutSecs); */ void FactoryReset(mozilla::dom::FactoryResetReason& aReason); -/** - * Start monitoring disk space for low space situations. - * - * This API is currently only allowed to be used from the main process. - */ -void StartDiskSpaceWatcher(); - -/** - * Stop monitoring disk space for low space situations. - * - * This API is currently only allowed to be used from the main process. - */ -void StopDiskSpaceWatcher(); - /** * Get total system memory of device being run on in bytes. * diff --git a/hal/fallback/FallbackDiskSpaceWatcher.cpp b/hal/fallback/FallbackDiskSpaceWatcher.cpp deleted file mode 100644 index 99d144397..000000000 --- a/hal/fallback/FallbackDiskSpaceWatcher.cpp +++ /dev/null @@ -1,19 +0,0 @@ -/* 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 http://mozilla.org/MPL/2.0/. */ - -namespace mozilla { -namespace hal_impl { - -void -StartDiskSpaceWatcher() -{ -} - -void -StopDiskSpaceWatcher() -{ -} - -} // namespace hal_impl -} // namespace mozilla diff --git a/hal/moz.build b/hal/moz.build index 3e1bae404..8d2950ac0 100644 --- a/hal/moz.build +++ b/hal/moz.build @@ -107,7 +107,6 @@ else: ] UNIFIED_SOURCES += [ - 'fallback/FallbackDiskSpaceWatcher.cpp', 'fallback/FallbackFactoryReset.cpp', 'fallback/FallbackProcessPriority.cpp', 'fallback/FallbackScreenPower.cpp', diff --git a/hal/sandbox/SandboxHal.cpp b/hal/sandbox/SandboxHal.cpp index 5501d459b..aeaeb724e 100644 --- a/hal/sandbox/SandboxHal.cpp +++ b/hal/sandbox/SandboxHal.cpp @@ -352,18 +352,6 @@ FactoryReset(FactoryResetReason& aReason) } } -void -StartDiskSpaceWatcher() -{ - NS_RUNTIMEABORT("StartDiskSpaceWatcher() can't be called from sandboxed contexts."); -} - -void -StopDiskSpaceWatcher() -{ - NS_RUNTIMEABORT("StopDiskSpaceWatcher() can't be called from sandboxed contexts."); -} - bool IsHeadphoneEventFromInputDev() { NS_RUNTIMEABORT("IsHeadphoneEventFromInputDev() cannot be called from sandboxed contexts."); -- cgit v1.2.3