diff --git a/lldb/source/Host/macosx/Host.mm b/lldb/source/Host/macosx/Host.mm index 6c3d2617380c..c70769d8292e 100644 --- a/lldb/source/Host/macosx/Host.mm +++ b/lldb/source/Host/macosx/Host.mm @@ -1117,11 +1117,7 @@ LaunchProcessXPC(const char *exe_path, ProcessLaunchInfo &launch_info, lldb::pid const char *xpc_service = nil; bool send_auth = false; AuthorizationExternalForm extForm; - if ((requested_uid == UINT32_MAX) || (requested_uid == HostInfo::GetEffectiveUserID())) - { - xpc_service = "com.apple.lldb.launcherXPCService"; - } - else if (requested_uid == 0) + if (requested_uid == 0) { if (AuthorizationMakeExternalForm(authorizationRef, &extForm) == errAuthorizationSuccess) { @@ -1137,12 +1133,12 @@ LaunchProcessXPC(const char *exe_path, ProcessLaunchInfo &launch_info, lldb::pid } return error; } - xpc_service = "com.apple.lldb.launcherRootXPCService"; + xpc_service = LaunchUsingXPCRightName; } else { error.SetError(4, eErrorTypeGeneric); - error.SetErrorStringWithFormat("Launching via XPC is only currently available for either the login user or root."); + error.SetErrorStringWithFormat("Launching via XPC is only currently available for root."); if (log) { error.PutToLog(log, "%s", error.AsCString());