From: Jay Freeman (saurik) Date: Sat, 13 Nov 2010 19:51:03 +0000 (-0800) Subject: Slightly more normalized if nesting on decidePolicyForNavigationAction:. X-Git-Url: https://git.saurik.com/cydia.git/commitdiff_plain/4304c998ad3ba110b222b71699443e66023acbc3 Slightly more normalized if nesting on decidePolicyForNavigationAction:. --- diff --git a/UICaboodle/BrowserView.mm b/UICaboodle/BrowserView.mm index 88dc7a4c..769aaed9 100644 --- a/UICaboodle/BrowserView.mm +++ b/UICaboodle/BrowserView.mm @@ -564,13 +564,15 @@ static void $UIWebViewWebViewDelegate$webViewClose$(UIWebViewWebViewDelegate *se NSLog(@"decidePolicyForNavigationAction:%@ request:%@ frame:%@", action, request, frame); #endif - if (!error_ && [frame parentFrame] == nil) { - if (request_ != nil) - [request_ autorelease]; - if (request == nil) - request_ = nil; - else - request_ = [request retain]; + if ([frame parentFrame] == nil) { + if (!error_) { + if (request_ != nil) + [request_ autorelease]; + if (request == nil) + request_ = nil; + else + request_ = [request retain]; + } } }