From 5ab2749acc2f115f5ec5c7f744c2c697fb85f5cf Mon Sep 17 00:00:00 2001 From: "trop[bot]" <37223003+trop[bot]@users.noreply.github.com> Date: Mon, 5 Jul 2021 12:53:04 -0400 Subject: [PATCH] fix: do not leak NSUUID (#30009) * fix: do not leak NSUUID * Fix build error Co-authored-by: Cheng Zhao --- shell/browser/notifications/mac/cocoa_notification.mm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/shell/browser/notifications/mac/cocoa_notification.mm b/shell/browser/notifications/mac/cocoa_notification.mm index 78d6e41976ab6..b8fcf4b04e985 100644 --- a/shell/browser/notifications/mac/cocoa_notification.mm +++ b/shell/browser/notifications/mac/cocoa_notification.mm @@ -33,7 +33,7 @@ NSString* identifier = [NSString stringWithFormat:@"%@:notification:%@", [[NSBundle mainBundle] bundleIdentifier], - [[[NSUUID alloc] init] UUIDString]]; + [[NSUUID UUID] UUIDString]]; [notification_ setTitle:base::SysUTF16ToNSString(options.title)]; [notification_ setSubtitle:base::SysUTF16ToNSString(options.subtitle)];