tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

commit 4cbb5261939174baed3f7b03f126f9d32b866476
parent d1a949bf3d7bc8c901d14f298c6f03e4abafe7a3
Author: Josh Aas <jaas@kflag.net>
Date:   Fri, 24 Oct 2025 14:04:57 +0000

Bug 1996170 - IPC: remove unused mac utils. r=ipc-reviewers,mccr8

Differential Revision: https://phabricator.services.mozilla.com/D269923

Diffstat:
Mipc/chromium/moz.build | 1-
Dipc/chromium/src/base/mac_util.h | 17-----------------
Dipc/chromium/src/base/mac_util.mm | 33---------------------------------
3 files changed, 0 insertions(+), 51 deletions(-)

diff --git a/ipc/chromium/moz.build b/ipc/chromium/moz.build @@ -104,7 +104,6 @@ if CONFIG["TARGET_KERNEL"] == "Darwin": if CONFIG["TARGET_OS"] == "OSX": UNIFIED_SOURCES += [ "src/base/chrome_application_mac.mm", - "src/base/mac_util.mm", "src/base/process_util_mac.mm", ] diff --git a/ipc/chromium/src/base/mac_util.h b/ipc/chromium/src/base/mac_util.h @@ -1,17 +0,0 @@ -/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ -/* vim: set ts=8 sts=2 et sw=2 tw=80: */ -// Copyright (c) 2008 The Chromium Authors. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -#ifndef BASE_MAC_UTIL_H_ -#define BASE_MAC_UTIL_H_ - -namespace mac_util { - -// Returns true if the application is running from a bundle -bool AmIBundled(); - -} // namespace mac_util - -#endif // BASE_MAC_UTIL_H_ diff --git a/ipc/chromium/src/base/mac_util.mm b/ipc/chromium/src/base/mac_util.mm @@ -1,33 +0,0 @@ -// Copyright (c) 2008 The Chromium Authors. All rights reserved. -// Use of this source code is governed by a BSD-style license that can be -// found in the LICENSE file. - -#include "base/mac_util.h" - -#include <Carbon/Carbon.h> -#import <Cocoa/Cocoa.h> - -#include "base/file_path.h" -#include "base/logging.h" -#include "base/scoped_cftyperef.h" -#include "base/sys_string_conversions.h" - -namespace mac_util { - -// Adapted from http://developer.apple.com/carbon/tipsandtricks.html#AmIBundled -bool AmIBundled() { - ProcessSerialNumber psn = {0, kCurrentProcess}; - - FSRef fsref; - if (GetProcessBundleLocation(&psn, &fsref) != noErr) return false; - - FSCatalogInfo info; - if (FSGetCatalogInfo(&fsref, kFSCatInfoNodeFlags, &info, NULL, NULL, NULL) != - noErr) { - return false; - } - - return info.nodeFlags & kFSNodeIsDirectoryMask; -} - -} // namespace mac_util