diff options
-rw-r--r-- | src/utils/mac/SkOptionsTableView.mm | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/utils/mac/SkOptionsTableView.mm b/src/utils/mac/SkOptionsTableView.mm index 2ee025efc8..41c7d4d791 100644 --- a/src/utils/mac/SkOptionsTableView.mm +++ b/src/utils/mac/SkOptionsTableView.mm @@ -91,7 +91,8 @@ int index = 0, count = 0; SkOSMenu::FindListItemCount(*item->getEvent(), &count); NSMutableArray* optionstrs = [[NSMutableArray alloc] initWithCapacity:count]; - SkString options[count]; + SkAutoTDeleteArray<SkString> ada(new SkString[count]); + SkString* options = ada.get(); SkOSMenu::FindListItems(*item->getEvent(), options); for (int i = 0; i < count; ++i) [optionstrs addObject:[NSString stringWithUTF8String:options[i].c_str()]]; |