[SCM] WebKit Debian packaging branch, debian/unstable, updated. debian/1.1.15-1-40151-g37bb677

cblu cblu at 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Sat Sep 26 07:03:23 UTC 2009


The following commit has been merged in the debian/unstable branch:
commit 4f7065eb1c82f8a3658150ddcc7186eaabcf2ee6
Author: cblu <cblu at 268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Tue Nov 19 01:30:10 2002 +0000

    	Real fix for: 3104183 - Assert loading www.louisvuitton.com
    
    	Since we don't consider plug-in content as a subresource, attaching plug-in streams to the datasource has no affect on the loading state of the datasource. Both stopLoading on WebFrame and _stopLoading datasource, would not stop plug-ins streams after the data source was done loading. Because of this, I've decided to not keep a list of plug-in streams attached to the data source and pulled my previous change. To fix this bug, WebBaseResourceHandleDelegate now retains the controller.
    
            * Plugins.subproj/WebNetscapePluginStream.m:
            (-[WebNetscapePluginStream start]):
            (-[WebNetscapePluginStream cancel]):
            (-[WebNetscapePluginStream handleDidFinishLoading:]):
            (-[WebNetscapePluginStream handle:didFailLoadingWithError:]):
            * WebView.subproj/WebBaseResourceHandleDelegate.h:
            * WebView.subproj/WebBaseResourceHandleDelegate.m:
            (-[WebBaseResourceHandleDelegate _releaseResources]):
            (-[WebBaseResourceHandleDelegate setDataSource:]):
            (-[WebBaseResourceHandleDelegate handle:willSendRequest:]):
            (-[WebBaseResourceHandleDelegate handleDidFinishLoading:]):
            (-[WebBaseResourceHandleDelegate handle:didFailLoadingWithError:]):
            (-[WebBaseResourceHandleDelegate _cancelWithError:]):
            * WebView.subproj/WebDataSourcePrivate.h:
            * WebView.subproj/WebDataSourcePrivate.m:
            (-[WebDataSourcePrivate dealloc]):
            (-[WebDataSource _stopLoading]):
            (-[WebDataSource _makeHandleDelegates:deferCallbacks:]):
            (-[WebDataSource _defersCallbacksChanged]):
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@2742 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebKit/ChangeLog b/WebKit/ChangeLog
index f0122a5..4bbd462 100644
--- a/WebKit/ChangeLog
+++ b/WebKit/ChangeLog
@@ -1,5 +1,31 @@
 2002-11-18  Chris Blumenberg  <cblu at apple.com>
 
+	Real fix for: 3104183 - Assert loading www.louisvuitton.com
+
+	Since we don't consider plug-in content as a subresource, attaching plug-in streams to the datasource has no affect on the loading state of the datasource. Both stopLoading on WebFrame and _stopLoading datasource, would not stop plug-ins streams after the data source was done loading. Because of this, I've decided to not keep a list of plug-in streams attached to the data source and pulled my previous change. To fix this bug, WebBaseResourceHandleDelegate now retains the controller.
+
+        * Plugins.subproj/WebNetscapePluginStream.m:
+        (-[WebNetscapePluginStream start]):
+        (-[WebNetscapePluginStream cancel]):
+        (-[WebNetscapePluginStream handleDidFinishLoading:]):
+        (-[WebNetscapePluginStream handle:didFailLoadingWithError:]):
+        * WebView.subproj/WebBaseResourceHandleDelegate.h:
+        * WebView.subproj/WebBaseResourceHandleDelegate.m:
+        (-[WebBaseResourceHandleDelegate _releaseResources]):
+        (-[WebBaseResourceHandleDelegate setDataSource:]):
+        (-[WebBaseResourceHandleDelegate handle:willSendRequest:]):
+        (-[WebBaseResourceHandleDelegate handleDidFinishLoading:]):
+        (-[WebBaseResourceHandleDelegate handle:didFailLoadingWithError:]):
+        (-[WebBaseResourceHandleDelegate _cancelWithError:]):
+        * WebView.subproj/WebDataSourcePrivate.h:
+        * WebView.subproj/WebDataSourcePrivate.m:
+        (-[WebDataSourcePrivate dealloc]):
+        (-[WebDataSource _stopLoading]):
+        (-[WebDataSource _makeHandleDelegates:deferCallbacks:]):
+        (-[WebDataSource _defersCallbacksChanged]):
+
+2002-11-18  Chris Blumenberg  <cblu at apple.com>
+
 	Fixed: 3104183 - Assert loading www.louisvuitton.com
 
 	We need to treat plug-in streams like subresources except they don't change the loading state of the data source.
diff --git a/WebKit/ChangeLog-2002-12-03 b/WebKit/ChangeLog-2002-12-03
index f0122a5..4bbd462 100644
--- a/WebKit/ChangeLog-2002-12-03
+++ b/WebKit/ChangeLog-2002-12-03
@@ -1,5 +1,31 @@
 2002-11-18  Chris Blumenberg  <cblu at apple.com>
 
+	Real fix for: 3104183 - Assert loading www.louisvuitton.com
+
+	Since we don't consider plug-in content as a subresource, attaching plug-in streams to the datasource has no affect on the loading state of the datasource. Both stopLoading on WebFrame and _stopLoading datasource, would not stop plug-ins streams after the data source was done loading. Because of this, I've decided to not keep a list of plug-in streams attached to the data source and pulled my previous change. To fix this bug, WebBaseResourceHandleDelegate now retains the controller.
+
+        * Plugins.subproj/WebNetscapePluginStream.m:
+        (-[WebNetscapePluginStream start]):
+        (-[WebNetscapePluginStream cancel]):
+        (-[WebNetscapePluginStream handleDidFinishLoading:]):
+        (-[WebNetscapePluginStream handle:didFailLoadingWithError:]):
+        * WebView.subproj/WebBaseResourceHandleDelegate.h:
+        * WebView.subproj/WebBaseResourceHandleDelegate.m:
+        (-[WebBaseResourceHandleDelegate _releaseResources]):
+        (-[WebBaseResourceHandleDelegate setDataSource:]):
+        (-[WebBaseResourceHandleDelegate handle:willSendRequest:]):
+        (-[WebBaseResourceHandleDelegate handleDidFinishLoading:]):
+        (-[WebBaseResourceHandleDelegate handle:didFailLoadingWithError:]):
+        (-[WebBaseResourceHandleDelegate _cancelWithError:]):
+        * WebView.subproj/WebDataSourcePrivate.h:
+        * WebView.subproj/WebDataSourcePrivate.m:
+        (-[WebDataSourcePrivate dealloc]):
+        (-[WebDataSource _stopLoading]):
+        (-[WebDataSource _makeHandleDelegates:deferCallbacks:]):
+        (-[WebDataSource _defersCallbacksChanged]):
+
+2002-11-18  Chris Blumenberg  <cblu at apple.com>
+
 	Fixed: 3104183 - Assert loading www.louisvuitton.com
 
 	We need to treat plug-in streams like subresources except they don't change the loading state of the data source.
diff --git a/WebKit/Plugins.subproj/WebNetscapePluginStream.m b/WebKit/Plugins.subproj/WebNetscapePluginStream.m
index 51bcc39..ad54ddb 100644
--- a/WebKit/Plugins.subproj/WebNetscapePluginStream.m
+++ b/WebKit/Plugins.subproj/WebNetscapePluginStream.m
@@ -47,9 +47,7 @@
 - (void)start
 {
     ASSERT(_startingRequest);
-    if([self loadWithRequest:_startingRequest]){
-        [[view dataSource] _addPluginStream:self];
-    }
+    [self loadWithRequest:_startingRequest];
     [_startingRequest release];
     _startingRequest = nil;
 }
@@ -63,7 +61,6 @@
 
 - (void)cancel
 {
-    [[view dataSource] _removePluginStream:self];
     [view release];
     view = nil;
 
@@ -94,12 +91,9 @@
 
 - (void)handleDidFinishLoading:(WebResourceHandle *)h
 {
-    WebController *controller = [view controller];
-
-    [controller _finishedLoadingResourceFromDataSource:[view dataSource]];
+    [[view controller] _finishedLoadingResourceFromDataSource:[view dataSource]];
     [self finishedLoadingWithData:resourceData];
 
-    [[view dataSource] _removePluginStream:self];
     [view release];
     view = nil;
     
@@ -108,13 +102,10 @@
 
 - (void)handle:(WebResourceHandle *)h didFailLoadingWithError:(WebError *)result
 {
-    WebController *controller = [view controller];
-
-    [controller _receivedError:result fromDataSource:[view dataSource]];
+    [[view controller] _receivedError:result fromDataSource:[view dataSource]];
 
     [self receivedError:NPRES_NETWORK_ERR];
 
-    [[view dataSource] _removePluginStream:self];
     [view release];
     view = nil;
     
diff --git a/WebKit/WebView.subproj/WebBaseResourceHandleDelegate.h b/WebKit/WebView.subproj/WebBaseResourceHandleDelegate.h
index 371b130..967b8d7 100644
--- a/WebKit/WebView.subproj/WebBaseResourceHandleDelegate.h
+++ b/WebKit/WebView.subproj/WebBaseResourceHandleDelegate.h
@@ -5,6 +5,7 @@
 
 #import <Foundation/Foundation.h>
 
+ at class WebController;
 @class WebDataSource;
 @class WebError;
 @class WebResourceHandle;
@@ -20,6 +21,7 @@
     WebDataSource *dataSource;
     WebResourceHandle *handle;
 @private
+    WebController *controller;
     WebResourceRequest *request;
     WebResourceResponse *response;
     id identifier;
diff --git a/WebKit/WebView.subproj/WebBaseResourceHandleDelegate.m b/WebKit/WebView.subproj/WebBaseResourceHandleDelegate.m
index 41bc7d3..a993862 100644
--- a/WebKit/WebView.subproj/WebBaseResourceHandleDelegate.m
+++ b/WebKit/WebView.subproj/WebBaseResourceHandleDelegate.m
@@ -35,6 +35,9 @@
     [handle release];
     handle = nil;
 
+    [controller release];
+    controller = nil;
+    
     [dataSource release];
     dataSource = nil;
     
@@ -84,12 +87,15 @@
     [d retain];
     [dataSource release];
     dataSource = d;
+
+    [controller release];
+    controller = [[dataSource controller] retain];
     
     [resourceLoadDelegate release];
-    resourceLoadDelegate = [[[dataSource controller] resourceLoadDelegate] retain];
+    resourceLoadDelegate = [[controller resourceLoadDelegate] retain];
 
     [downloadDelegate release];
-    downloadDelegate = [[[dataSource controller] downloadDelegate] retain];
+    downloadDelegate = [[controller downloadDelegate] retain];
 }
 
 - (WebDataSource *)dataSource
@@ -122,7 +128,7 @@
     ASSERT(handle == h);
     ASSERT(!reachedTerminalState);
     
-    [newRequest setUserAgent:[[dataSource controller] userAgentForURL:[newRequest URL]]];
+    [newRequest setUserAgent:[controller userAgentForURL:[newRequest URL]]];
 
     if (identifier == nil) {
         // The identifier is released after the last callback, rather than in dealloc
@@ -139,11 +145,11 @@
     request = [newRequest copy];
 
     if (currentURL) {
-        [[WebStandardPanels sharedStandardPanels] _didStopLoadingURL:currentURL inController:[dataSource controller]];
+        [[WebStandardPanels sharedStandardPanels] _didStopLoadingURL:currentURL inController:controller];
     }    
     [currentURL release];
     currentURL = [[request URL] retain];
-    [[WebStandardPanels sharedStandardPanels] _didStartLoadingURL:currentURL inController:[dataSource controller]];
+    [[WebStandardPanels sharedStandardPanels] _didStartLoadingURL:currentURL inController:controller];
 
     return request;
 }
@@ -184,7 +190,7 @@
     else
         [resourceLoadDelegate resource:identifier didFinishLoadingFromDataSource:dataSource];
 
-    [[WebStandardPanels sharedStandardPanels] _didStopLoadingURL:currentURL inController:[dataSource controller]];
+    [[WebStandardPanels sharedStandardPanels] _didStopLoadingURL:currentURL inController:controller];
 
     [self _releaseResources];
 }
@@ -199,7 +205,7 @@
     else
         [resourceLoadDelegate resource:identifier didFailLoadingWithError:result fromDataSource:dataSource];
 
-    [[WebStandardPanels sharedStandardPanels] _didStopLoadingURL:currentURL inController:[dataSource controller]];
+    [[WebStandardPanels sharedStandardPanels] _didStopLoadingURL:currentURL inController:controller];
 
     [self _releaseResources];
 }
@@ -210,7 +216,7 @@
 
     [handle cancel];
     
-    [[WebStandardPanels sharedStandardPanels] _didStopLoadingURL:currentURL inController:[dataSource controller]];
+    [[WebStandardPanels sharedStandardPanels] _didStopLoadingURL:currentURL inController:controller];
 
     if (error) {
         [resourceLoadDelegate resource:identifier didFailLoadingWithError:error fromDataSource:dataSource];
diff --git a/WebKit/WebView.subproj/WebDataSourcePrivate.h b/WebKit/WebView.subproj/WebDataSourcePrivate.h
index 1a77f5c..38d1527 100644
--- a/WebKit/WebView.subproj/WebDataSourcePrivate.h
+++ b/WebKit/WebView.subproj/WebDataSourcePrivate.h
@@ -38,9 +38,6 @@
     
     // Clients for other resources.
     NSMutableArray *subresourceClients;
-    
-    // Plugin streams are like subresources except that they don't affect the loading state of the datasource.
-    NSMutableArray *pluginStreams;
 
     // The time when the data source was told to start loading.
     double loadingStartedTime;
@@ -104,8 +101,6 @@
 - (void)_recursiveStopLoading;
 - (void)_addSubresourceClient:(WebSubresourceClient *)client;
 - (void)_removeSubresourceClient:(WebSubresourceClient *)client;
-- (void)_addPluginStream:(WebNetscapePluginStream *)stream;
-- (void)_removePluginStream:(WebNetscapePluginStream *)stream;
 - (void)_setPrimaryLoadComplete:(BOOL)flag;
 - (double)_loadingStartedTime;
 - (void)_setTitle:(NSString *)title;
diff --git a/WebKit/WebView.subproj/WebDataSourcePrivate.m b/WebKit/WebView.subproj/WebDataSourcePrivate.m
index 5b64c47..b688148 100644
--- a/WebKit/WebView.subproj/WebDataSourcePrivate.m
+++ b/WebKit/WebView.subproj/WebDataSourcePrivate.m
@@ -52,7 +52,6 @@
     [originalRequest release];
     [mainClient release];
     [subresourceClients release];
-    [pluginStreams release];
     [pageTitle release];
     [response release];
     [mainDocumentError release];
@@ -191,24 +190,6 @@
     [self _updateLoading];
 }
 
-// Plugin streams are like subresources except that they don't affect the loading state of the datasource.
-- (void)_addPluginStream:(WebNetscapePluginStream *)stream
-{
-    if (_private->pluginStreams == nil) {
-        _private->pluginStreams = [[NSMutableArray alloc] init];
-    }
-    if ([_private->controller _defersCallbacks]) {
-        [stream setDefersCallbacks:YES];
-    }
-    [_private->pluginStreams addObject:stream];
-}
-
-- (void)_removePluginStream:(WebNetscapePluginStream *)stream
-{
-    [_private->pluginStreams removeObject:stream];
-}
-
-
 - (BOOL)_isStopping
 {
     return _private->stopping;
@@ -227,10 +208,6 @@
     NSArray *clients = [_private->subresourceClients copy];
     [clients makeObjectsPerformSelector:@selector(cancel)];
     [clients release];
-
-    NSArray *streams = [_private->pluginStreams copy];
-    [streams makeObjectsPerformSelector:@selector(cancel)];
-    [streams release];
     
     if (_private->committed) {
 	[[self _bridge] closeURL];        
@@ -546,11 +523,7 @@
 
 - (void)_makeHandleDelegates:(NSArray *)handleDelegates deferCallbacks:(BOOL)deferCallbacks
 {
-    NSEnumerator *e = [handleDelegates objectEnumerator];
-    WebBaseResourceHandleDelegate *delegate;
-    while ((delegate = [e nextObject])) {
-        [delegate setDefersCallbacks:deferCallbacks];
-    }
+
 }
 
 - (void)_defersCallbacksChanged
@@ -564,8 +537,11 @@
     _private->defersCallbacks = defers;
     [_private->mainClient setDefersCallbacks:defers];
 
-    [self _makeHandleDelegates:_private->subresourceClients deferCallbacks:defers];
-    [self _makeHandleDelegates:_private->pluginStreams deferCallbacks:defers];
+    NSEnumerator *e = [_private->subresourceClients objectEnumerator];
+    WebSubresourceClient *client;
+    while ((client = [e nextObject])) {
+        [client setDefersCallbacks:defers];
+    }
 
     [[[self webFrame] children] makeObjectsPerformSelector:@selector(_defersCallbacksChanged)];
 }
diff --git a/WebKit/WebView.subproj/WebLoader.h b/WebKit/WebView.subproj/WebLoader.h
index 371b130..967b8d7 100644
--- a/WebKit/WebView.subproj/WebLoader.h
+++ b/WebKit/WebView.subproj/WebLoader.h
@@ -5,6 +5,7 @@
 
 #import <Foundation/Foundation.h>
 
+ at class WebController;
 @class WebDataSource;
 @class WebError;
 @class WebResourceHandle;
@@ -20,6 +21,7 @@
     WebDataSource *dataSource;
     WebResourceHandle *handle;
 @private
+    WebController *controller;
     WebResourceRequest *request;
     WebResourceResponse *response;
     id identifier;
diff --git a/WebKit/WebView.subproj/WebLoader.m b/WebKit/WebView.subproj/WebLoader.m
index 41bc7d3..a993862 100644
--- a/WebKit/WebView.subproj/WebLoader.m
+++ b/WebKit/WebView.subproj/WebLoader.m
@@ -35,6 +35,9 @@
     [handle release];
     handle = nil;
 
+    [controller release];
+    controller = nil;
+    
     [dataSource release];
     dataSource = nil;
     
@@ -84,12 +87,15 @@
     [d retain];
     [dataSource release];
     dataSource = d;
+
+    [controller release];
+    controller = [[dataSource controller] retain];
     
     [resourceLoadDelegate release];
-    resourceLoadDelegate = [[[dataSource controller] resourceLoadDelegate] retain];
+    resourceLoadDelegate = [[controller resourceLoadDelegate] retain];
 
     [downloadDelegate release];
-    downloadDelegate = [[[dataSource controller] downloadDelegate] retain];
+    downloadDelegate = [[controller downloadDelegate] retain];
 }
 
 - (WebDataSource *)dataSource
@@ -122,7 +128,7 @@
     ASSERT(handle == h);
     ASSERT(!reachedTerminalState);
     
-    [newRequest setUserAgent:[[dataSource controller] userAgentForURL:[newRequest URL]]];
+    [newRequest setUserAgent:[controller userAgentForURL:[newRequest URL]]];
 
     if (identifier == nil) {
         // The identifier is released after the last callback, rather than in dealloc
@@ -139,11 +145,11 @@
     request = [newRequest copy];
 
     if (currentURL) {
-        [[WebStandardPanels sharedStandardPanels] _didStopLoadingURL:currentURL inController:[dataSource controller]];
+        [[WebStandardPanels sharedStandardPanels] _didStopLoadingURL:currentURL inController:controller];
     }    
     [currentURL release];
     currentURL = [[request URL] retain];
-    [[WebStandardPanels sharedStandardPanels] _didStartLoadingURL:currentURL inController:[dataSource controller]];
+    [[WebStandardPanels sharedStandardPanels] _didStartLoadingURL:currentURL inController:controller];
 
     return request;
 }
@@ -184,7 +190,7 @@
     else
         [resourceLoadDelegate resource:identifier didFinishLoadingFromDataSource:dataSource];
 
-    [[WebStandardPanels sharedStandardPanels] _didStopLoadingURL:currentURL inController:[dataSource controller]];
+    [[WebStandardPanels sharedStandardPanels] _didStopLoadingURL:currentURL inController:controller];
 
     [self _releaseResources];
 }
@@ -199,7 +205,7 @@
     else
         [resourceLoadDelegate resource:identifier didFailLoadingWithError:result fromDataSource:dataSource];
 
-    [[WebStandardPanels sharedStandardPanels] _didStopLoadingURL:currentURL inController:[dataSource controller]];
+    [[WebStandardPanels sharedStandardPanels] _didStopLoadingURL:currentURL inController:controller];
 
     [self _releaseResources];
 }
@@ -210,7 +216,7 @@
 
     [handle cancel];
     
-    [[WebStandardPanels sharedStandardPanels] _didStopLoadingURL:currentURL inController:[dataSource controller]];
+    [[WebStandardPanels sharedStandardPanels] _didStopLoadingURL:currentURL inController:controller];
 
     if (error) {
         [resourceLoadDelegate resource:identifier didFailLoadingWithError:error fromDataSource:dataSource];

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list