From 5330455e77802f1d013b4f1f23886e6e236a35fb Mon Sep 17 00:00:00 2001
From: Rye Mutt <rye@alchemyviewer.org>
Date: Sun, 17 Oct 2021 05:05:42 -0400
Subject: [PATCH] Fix more deprecation

---
 indra/newview/llappviewermacosx-objc.h  |  1 -
 indra/newview/llappviewermacosx-objc.mm | 41 -------------------------
 2 files changed, 42 deletions(-)

diff --git a/indra/newview/llappviewermacosx-objc.h b/indra/newview/llappviewermacosx-objc.h
index 9ac36b6c4d3..1e8e832afac 100644
--- a/indra/newview/llappviewermacosx-objc.h
+++ b/indra/newview/llappviewermacosx-objc.h
@@ -32,6 +32,5 @@
 
 //Why?  Because BOOL
 void setCrashUserMetadataWrapper(const std::string& userid, const std::string& username);
-void launchApplication(const std::string* app_name, const std::vector<std::string>* args);
 
 #endif // LL_LLAPPVIEWERMACOSX_OBJC_H
diff --git a/indra/newview/llappviewermacosx-objc.mm b/indra/newview/llappviewermacosx-objc.mm
index 57ab7841dcb..b284eae81a8 100644
--- a/indra/newview/llappviewermacosx-objc.mm
+++ b/indra/newview/llappviewermacosx-objc.mm
@@ -46,44 +46,3 @@ void setCrashUserMetadataWrapper(const std::string& userid, const std::string& u
     [SentrySDK setUser:user];
 #endif
 }
-
-void launchApplication(const std::string* app_name, const std::vector<std::string>* args)
-{
-    @autoreleasepool
-    {
-        if (app_name->empty()) return;
-        
-        NSMutableString* app_name_ns = [NSMutableString stringWithString:[[NSBundle mainBundle] resourcePath]];    //Path to resource dir
-        [app_name_ns appendFormat:@"/%@", [NSString stringWithCString:app_name->c_str()
-                                                             encoding:[NSString defaultCStringEncoding]]];
-        
-        NSMutableArray *args_ns = [[NSMutableArray alloc] init];
-        
-        for (int i=0; i < args->size(); ++i)
-        {
-            NSLog(@"Adding string %s", (*args)[i].c_str());
-            [args_ns addObject:
-             [NSString stringWithCString:(*args)[i].c_str()
-                                encoding:[NSString defaultCStringEncoding]]];
-        }
-        
-        NSTask *task = [[NSTask alloc] init];
-        NSBundle *bundle = [NSBundle bundleWithPath:[[NSWorkspace sharedWorkspace] fullPathForApplication:app_name_ns]];
-	@try {
-        	[task setLaunchPath:[bundle executablePath]];
-	}
-	@catch (NSException *theException) {
-		NSLog(@"Caught a %@ exception, bailing.", theException);
-		return;
-	}
-        [task setArguments:args_ns];
-        [task launch];
-        
-        //    NSWorkspace *workspace = [NSWorkspace sharedWorkspace];
-        //    NSURL *url = [NSURL fileURLWithPath:[workspace fullPathForApplication:app_name_ns]];
-        //
-        //    NSError *error = nil;
-        //    [workspace launchApplicationAtURL:url options:0 configuration:[NSDictionary dictionaryWithObject:args_ns forKey:NSWorkspaceLaunchConfigurationArguments] error:&error];
-        //TODO Handle error
-    }
-}
-- 
GitLab