Skip to content

Commit

Permalink
Merge pull request #655 from MaddTheSane/patch-2
Browse files Browse the repository at this point in the history
Fix a memory leak in GBLoadROMTableViewController.m
  • Loading branch information
LIJI32 authored Sep 13, 2024
2 parents ece40bc + 8c8e59c commit 8cb94e7
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions iOS/GBLoadROMTableViewController.m
Original file line number Diff line number Diff line change
Expand Up @@ -101,9 +101,9 @@ - (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath
NSString *zipUTI = (__bridge_transfer NSString *)UTTypeCreatePreferredIdentifierForTag(kUTTagClassFilenameExtension, (__bridge CFStringRef)@"zip", NULL);

NSMutableSet *extensions = [NSMutableSet set];
[extensions addObjectsFromArray:(__bridge NSArray *)UTTypeCopyAllTagsWithClass((__bridge CFStringRef)gbUTI, kUTTagClassFilenameExtension)];
[extensions addObjectsFromArray:(__bridge NSArray *)UTTypeCopyAllTagsWithClass((__bridge CFStringRef)gbcUTI, kUTTagClassFilenameExtension)];
[extensions addObjectsFromArray:(__bridge NSArray *)UTTypeCopyAllTagsWithClass((__bridge CFStringRef)isxUTI, kUTTagClassFilenameExtension)];
[extensions addObjectsFromArray:(__bridge_transfer NSArray *)UTTypeCopyAllTagsWithClass((__bridge CFStringRef)gbUTI, kUTTagClassFilenameExtension)];
[extensions addObjectsFromArray:(__bridge_transfer NSArray *)UTTypeCopyAllTagsWithClass((__bridge CFStringRef)gbcUTI, kUTTagClassFilenameExtension)];
[extensions addObjectsFromArray:(__bridge_transfer NSArray *)UTTypeCopyAllTagsWithClass((__bridge CFStringRef)isxUTI, kUTTagClassFilenameExtension)];

if (extensions.count != 3) {
if (![[NSUserDefaults standardUserDefaults] boolForKey:@"GBShownUTIWarning"]) {
Expand Down

0 comments on commit 8cb94e7

Please sign in to comment.