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

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


The following commit has been merged in the debian/unstable branch:
commit 8ace94de39a25d7ba81ec912eabecb1a62c2244b
Author: kocienda <kocienda at 268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Mon Jul 28 20:37:55 2003 +0000

            Reviewed by John
    
            Fix for this bug:
    
            <rdar://problem/3336933>: REGRESSION (Panther): Mozilla build downloaded
            with wrong extension, bad file size (gzip)
    
    	Use new delegate methods that allow for the correct reporting
    	of progress in cases where Foundation-level content decoding
    	has been performed on data received
    
            * WebCoreSupport.subproj/WebSubresourceClient.m:
            (-[WebSubresourceClient connection:didReceiveData:lengthReceived:]):
            * WebView.subproj/WebBaseResourceHandleDelegate.m:
            (-[WebBaseResourceHandleDelegate connection:didReceiveData:]):
            (-[WebBaseResourceHandleDelegate connection:didReceiveData:lengthReceived:]):
            * WebView.subproj/WebMainResourceClient.m:
            (-[WebMainResourceClient connection:didReceiveData:lengthReceived:]):
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@4719 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebKit/ChangeLog b/WebKit/ChangeLog
index a6ee45f..f325a5f 100644
--- a/WebKit/ChangeLog
+++ b/WebKit/ChangeLog
@@ -1,3 +1,24 @@
+2003-07-28  Ken Kocienda  <kocienda at apple.com>
+
+        Reviewed by John
+
+        Fix for this bug:
+
+        <rdar://problem/3336933>: REGRESSION (Panther): Mozilla build downloaded
+        with wrong extension, bad file size (gzip)
+
+	Use new delegate methods that allow for the correct reporting
+	of progress in cases where Foundation-level content decoding 	
+	has been performed on data received
+
+        * WebCoreSupport.subproj/WebSubresourceClient.m:
+        (-[WebSubresourceClient connection:didReceiveData:lengthReceived:]):
+        * WebView.subproj/WebBaseResourceHandleDelegate.m:
+        (-[WebBaseResourceHandleDelegate connection:didReceiveData:]):
+        (-[WebBaseResourceHandleDelegate connection:didReceiveData:lengthReceived:]):
+        * WebView.subproj/WebMainResourceClient.m:
+        (-[WebMainResourceClient connection:didReceiveData:lengthReceived:]):
+
 2003-07-28  Darin Adler  <darin at apple.com>
 
         Reviewed by Richard.
diff --git a/WebKit/WebCoreSupport.subproj/WebSubresourceClient.m b/WebKit/WebCoreSupport.subproj/WebSubresourceClient.m
index 31150ab..3261665 100644
--- a/WebKit/WebCoreSupport.subproj/WebSubresourceClient.m
+++ b/WebKit/WebCoreSupport.subproj/WebSubresourceClient.m
@@ -101,13 +101,13 @@
     [self release];
 }
 
-- (void)connection:(NSURLConnection *)con didReceiveData:(NSData *)data
+- (void)connection:(NSURLConnection *)con didReceiveData:(NSData *)data lengthReceived:(long long)lengthReceived
 {
     // retain/release self in this delegate method since the additional processing can do
     // anything including possibly releasing self; one example of this is 3266216
     [self retain];
     [loader addData:data];
-    [super connection:con didReceiveData:data];
+    [super connection:con didReceiveData:data lengthReceived:lengthReceived];
     [self release];
 }
 
diff --git a/WebKit/WebCoreSupport.subproj/WebSubresourceLoader.m b/WebKit/WebCoreSupport.subproj/WebSubresourceLoader.m
index 31150ab..3261665 100644
--- a/WebKit/WebCoreSupport.subproj/WebSubresourceLoader.m
+++ b/WebKit/WebCoreSupport.subproj/WebSubresourceLoader.m
@@ -101,13 +101,13 @@
     [self release];
 }
 
-- (void)connection:(NSURLConnection *)con didReceiveData:(NSData *)data
+- (void)connection:(NSURLConnection *)con didReceiveData:(NSData *)data lengthReceived:(long long)lengthReceived
 {
     // retain/release self in this delegate method since the additional processing can do
     // anything including possibly releasing self; one example of this is 3266216
     [self retain];
     [loader addData:data];
-    [super connection:con didReceiveData:data];
+    [super connection:con didReceiveData:data lengthReceived:lengthReceived];
     [self release];
 }
 
diff --git a/WebKit/WebKit.pbproj/project.pbxproj b/WebKit/WebKit.pbproj/project.pbxproj
index d657421..578d7df 100644
--- a/WebKit/WebKit.pbproj/project.pbxproj
+++ b/WebKit/WebKit.pbproj/project.pbxproj
@@ -75,6 +75,8 @@
 //083
 //084
 		0867D690FE84028FC02AAC07 = {
+			buildSettings = {
+			};
 			buildStyles = (
 				014CEA440018CDF011CA2923,
 				014CEA450018CDF011CA2923,
diff --git a/WebKit/WebView.subproj/WebBaseResourceHandleDelegate.h b/WebKit/WebView.subproj/WebBaseResourceHandleDelegate.h
index 46c31b6..c184a47 100644
--- a/WebKit/WebView.subproj/WebBaseResourceHandleDelegate.h
+++ b/WebKit/WebView.subproj/WebBaseResourceHandleDelegate.h
@@ -59,3 +59,9 @@
 - (NSURLResponse *)response;
 
 @end
+
+// Note: This interface can be removed once this method is declared
+// in Foundation (probably will be in Foundation-485).
+ at interface NSObject (WebBaseResourceHandleDelegateExtras)
+- (void)connection:(NSURLConnection *)con didReceiveData:(NSData *)data lengthReceived:(long long)lengthReceived;
+ at end
\ No newline at end of file
diff --git a/WebKit/WebView.subproj/WebBaseResourceHandleDelegate.m b/WebKit/WebView.subproj/WebBaseResourceHandleDelegate.m
index 247cea3..6ccfa91 100644
--- a/WebKit/WebView.subproj/WebBaseResourceHandleDelegate.m
+++ b/WebKit/WebView.subproj/WebBaseResourceHandleDelegate.m
@@ -310,6 +310,11 @@
 
 - (void)connection:(NSURLConnection *)con didReceiveData:(NSData *)data
 {
+    [self connection:con didReceiveData:data lengthReceived:[data length]];
+}
+
+- (void)connection:(NSURLConnection *)con didReceiveData:(NSData *)data lengthReceived:(long long)lengthReceived
+{
     // The following assertions are not quite valid here, since a subclass
     // might override didReceiveData: in a way that invalidates them. This
     // happens with the steps listed in 3266216
@@ -322,9 +327,9 @@
     [webView _incrementProgressForConnection:con data:data];
 
     if (implementations.delegateImplementsDidReceiveContentLength)
-        [resourceLoadDelegate webView:webView resource:identifier didReceiveContentLength:[data length] fromDataSource:dataSource];
+        [resourceLoadDelegate webView:webView resource:identifier didReceiveContentLength:lengthReceived fromDataSource:dataSource];
     else
-        [[WebDefaultResourceLoadDelegate sharedResourceLoadDelegate] webView:webView resource:identifier didReceiveContentLength:[data length] fromDataSource:dataSource];
+        [[WebDefaultResourceLoadDelegate sharedResourceLoadDelegate] webView:webView resource:identifier didReceiveContentLength:lengthReceived fromDataSource:dataSource];
     [self release];
 }
 
diff --git a/WebKit/WebView.subproj/WebLoader.h b/WebKit/WebView.subproj/WebLoader.h
index 46c31b6..c184a47 100644
--- a/WebKit/WebView.subproj/WebLoader.h
+++ b/WebKit/WebView.subproj/WebLoader.h
@@ -59,3 +59,9 @@
 - (NSURLResponse *)response;
 
 @end
+
+// Note: This interface can be removed once this method is declared
+// in Foundation (probably will be in Foundation-485).
+ at interface NSObject (WebBaseResourceHandleDelegateExtras)
+- (void)connection:(NSURLConnection *)con didReceiveData:(NSData *)data lengthReceived:(long long)lengthReceived;
+ at end
\ No newline at end of file
diff --git a/WebKit/WebView.subproj/WebLoader.m b/WebKit/WebView.subproj/WebLoader.m
index 247cea3..6ccfa91 100644
--- a/WebKit/WebView.subproj/WebLoader.m
+++ b/WebKit/WebView.subproj/WebLoader.m
@@ -310,6 +310,11 @@
 
 - (void)connection:(NSURLConnection *)con didReceiveData:(NSData *)data
 {
+    [self connection:con didReceiveData:data lengthReceived:[data length]];
+}
+
+- (void)connection:(NSURLConnection *)con didReceiveData:(NSData *)data lengthReceived:(long long)lengthReceived
+{
     // The following assertions are not quite valid here, since a subclass
     // might override didReceiveData: in a way that invalidates them. This
     // happens with the steps listed in 3266216
@@ -322,9 +327,9 @@
     [webView _incrementProgressForConnection:con data:data];
 
     if (implementations.delegateImplementsDidReceiveContentLength)
-        [resourceLoadDelegate webView:webView resource:identifier didReceiveContentLength:[data length] fromDataSource:dataSource];
+        [resourceLoadDelegate webView:webView resource:identifier didReceiveContentLength:lengthReceived fromDataSource:dataSource];
     else
-        [[WebDefaultResourceLoadDelegate sharedResourceLoadDelegate] webView:webView resource:identifier didReceiveContentLength:[data length] fromDataSource:dataSource];
+        [[WebDefaultResourceLoadDelegate sharedResourceLoadDelegate] webView:webView resource:identifier didReceiveContentLength:lengthReceived fromDataSource:dataSource];
     [self release];
 }
 
diff --git a/WebKit/WebView.subproj/WebMainResourceClient.m b/WebKit/WebView.subproj/WebMainResourceClient.m
index 5a7eb3e..821b033 100644
--- a/WebKit/WebView.subproj/WebMainResourceClient.m
+++ b/WebKit/WebView.subproj/WebMainResourceClient.m
@@ -253,7 +253,7 @@
     [self release];
 }
 
-- (void)connection:(NSURLConnection *)con didReceiveData:(NSData *)data
+- (void)connection:(NSURLConnection *)con didReceiveData:(NSData *)data lengthReceived:(long long)lengthReceived
 {
     ASSERT(data);
     ASSERT([data length] != 0);
@@ -271,7 +271,7 @@
                                        fromDataSource:dataSource
                                              complete:NO];
 
-    [super connection:con didReceiveData:data];
+    [super connection:con didReceiveData:data lengthReceived:lengthReceived];
     _bytesReceived += [data length];
 
     LOG(Loading, "%d of %d", _bytesReceived, _contentLength);
diff --git a/WebKit/WebView.subproj/WebMainResourceLoader.m b/WebKit/WebView.subproj/WebMainResourceLoader.m
index 5a7eb3e..821b033 100644
--- a/WebKit/WebView.subproj/WebMainResourceLoader.m
+++ b/WebKit/WebView.subproj/WebMainResourceLoader.m
@@ -253,7 +253,7 @@
     [self release];
 }
 
-- (void)connection:(NSURLConnection *)con didReceiveData:(NSData *)data
+- (void)connection:(NSURLConnection *)con didReceiveData:(NSData *)data lengthReceived:(long long)lengthReceived
 {
     ASSERT(data);
     ASSERT([data length] != 0);
@@ -271,7 +271,7 @@
                                        fromDataSource:dataSource
                                              complete:NO];
 
-    [super connection:con didReceiveData:data];
+    [super connection:con didReceiveData:data lengthReceived:lengthReceived];
     _bytesReceived += [data length];
 
     LOG(Loading, "%d of %d", _bytesReceived, _contentLength);

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list