Skip to content

Commit

Permalink
Fixes leak of url in FlutterObservatoryPublisher (flutter#14822)
Browse files Browse the repository at this point in the history
  • Loading branch information
zhongwuzw authored and fluttergithubbot committed Jan 10, 2020
1 parent b98e299 commit 7ef88f8
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ - (void)stopService {
- (void)publishServiceProtocolPort:(NSString*)uri {
// uri comes in as something like 'http://127.0.0.1:XXXXX/' where XXXXX is the port
// number.
url.reset([[[NSURL alloc] initWithString:uri] retain]);
url.reset([[NSURL alloc] initWithString:uri]);

DNSServiceFlags flags = kDNSServiceFlagsDefault;
#if TARGET_IPHONE_SIMULATOR
Expand Down Expand Up @@ -157,7 +157,7 @@ - (void)stopService {
- (void)publishServiceProtocolPort:(NSString*)uri {
// uri comes in as something like 'http://127.0.0.1:XXXXX/' where XXXXX is the port
// number.
url.reset([[[NSURL alloc] initWithString:uri] retain]);
url.reset([[NSURL alloc] initWithString:uri]);

NSNetService* netServiceTmp = [[NSNetService alloc] initWithDomain:@"local."
type:@"_dartobservatory._tcp."
Expand Down

0 comments on commit 7ef88f8

Please sign in to comment.