| Index: base/mac/mac_util.mm
|
| diff --git a/base/mac/mac_util.mm b/base/mac/mac_util.mm
|
| index 930a280ee3cb08fb491bfa64e45371bd3abcca1a..9615f9d2eeb1ae88ef29d025bb0f56289d6e0716 100644
|
| --- a/base/mac/mac_util.mm
|
| +++ b/base/mac/mac_util.mm
|
| @@ -296,11 +296,21 @@ bool WasLaunchedAsLoginOrResumeItem() {
|
| ProcessInfoRec info = {};
|
| info.processInfoLength = sizeof(info);
|
|
|
| +// GetProcessInformation has been deprecated since macOS 10.9, but there is no
|
| +// replacement that provides the information we need. See
|
| +// https://crbug.com/650854.
|
| +#pragma clang diagnostic push
|
| +#pragma clang diagnostic ignored "-Wdeprecated-declarations"
|
| if (GetProcessInformation(&psn, &info) == noErr) {
|
| +#pragma clang diagnostic pop
|
| ProcessInfoRec parent_info = {};
|
| parent_info.processInfoLength = sizeof(parent_info);
|
| - if (GetProcessInformation(&info.processLauncher, &parent_info) == noErr)
|
| +#pragma clang diagnostic push
|
| +#pragma clang diagnostic ignored "-Wdeprecated-declarations"
|
| + if (GetProcessInformation(&info.processLauncher, &parent_info) == noErr) {
|
| +#pragma clang diagnostic pop
|
| return parent_info.processSignature == 'lgnw';
|
| + }
|
| }
|
| return false;
|
| }
|
|
|