Skip to content
Permalink
Browse files
Fix branch test build after r222431.
https://bugs.webkit.org/show_bug.cgi?id=177411

* TestWebKitAPI/Tests/WebKit2Cocoa/JavaScriptDuringNavigation.mm:
(-[JSNavigationDelegate webView:decidePolicyForNavigationAction:decisionHandler:]):
(-[JSNavigationDelegate webView:decidePolicyForNavigationResponse:decisionHandler:]):
Just do string comparison to avoid this error on some OSes:
error: instance method '-isEqualTo:' not found (return type defaults to 'id')



Canonical link: https://commits.webkit.org/191388.158@safari-604-branch
git-svn-id: https://svn.webkit.org/repository/webkit/branches/safari-604-branch@222453 268f45cc-cd09-0410-ab3c-d52691b4dbfc
  • Loading branch information
achristensen07 committed Sep 25, 2017
1 parent b31fcc1 commit 1660f2cd7f6a9c3722c38a8d1ee17b889f3639d9
Showing with 14 additions and 2 deletions.
  1. +12 −0 Tools/ChangeLog
  2. +2 −2 Tools/TestWebKitAPI/Tests/WebKit2Cocoa/JavaScriptDuringNavigation.mm
@@ -1,3 +1,15 @@
2017-09-25 Alex Christensen <achristensen@webkit.org>

Fix branch test build after r222431.
https://bugs.webkit.org/show_bug.cgi?id=177411

* TestWebKitAPI/Tests/WebKit2Cocoa/JavaScriptDuringNavigation.mm:
(-[JSNavigationDelegate webView:decidePolicyForNavigationAction:decisionHandler:]):
(-[JSNavigationDelegate webView:decidePolicyForNavigationResponse:decisionHandler:]):
Just do string comparison to avoid this error on some OSes:
error: instance method '-isEqualTo:' not found (return type defaults to 'id')


2017-09-23 Alex Christensen <achristensen@webkit.org>

REGRESSION(r214201): WebProcess hangs during policy decisions
@@ -50,7 +50,7 @@ - (void)webView:(WKWebView *)webView didFinishNavigation:(null_unspecified WKNav

- (void)webView:(WKWebView *)webView decidePolicyForNavigationAction:(WKNavigationAction *)navigationAction decisionHandler:(void (^)(WKNavigationActionPolicy))decisionHandler
{
if ([navigationAction.request.URL isEqualTo:secondURL.get()]) {
if ([navigationAction.request.URL.absoluteString isEqualToString:[secondURL absoluteString]]) {
[webView evaluateJavaScript:@"alert(document.location);" completionHandler:^(id, NSError *) {
decisionHandler(WKNavigationActionPolicyAllow);
}];
@@ -60,7 +60,7 @@ - (void)webView:(WKWebView *)webView decidePolicyForNavigationAction:(WKNavigati

- (void)webView:(WKWebView *)webView decidePolicyForNavigationResponse:(WKNavigationResponse *)navigationResponse decisionHandler:(void (^)(WKNavigationResponsePolicy))decisionHandler
{
if ([navigationResponse.response.URL isEqualTo:secondURL.get()]) {
if ([navigationResponse.response.URL.absoluteString isEqualToString:[secondURL absoluteString]]) {
[webView evaluateJavaScript:@"alert(document.location);" completionHandler:^(id, NSError *) {
decisionHandler(WKNavigationResponsePolicyAllow);
}];

0 comments on commit 1660f2c

Please sign in to comment.