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

darin darin at 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Sat Sep 26 07:54:56 UTC 2009


The following commit has been merged in the debian/unstable branch:
commit 0f52ba624fe7493336e59e1053072db464c378c8
Author: darin <darin at 268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Tue Sep 2 21:59:00 2003 +0000

            Reviewed by John.
    
            - fixed 3403388 -- decoder mishandles pages which fill the decoding buffer (mainly ISO-2022-JP)
    
            * kwq/KWQTextCodec.mm: (KWQTextDecoder::convertUsingTEC): Keep decoding, passing in no additional bytes,
            until we get noErr, don't ever stop after a kTECOutputBufferFullStatus error.
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@4925 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebCore/ChangeLog-2003-10-25 b/WebCore/ChangeLog-2003-10-25
index 44874a7..b5dd642 100644
--- a/WebCore/ChangeLog-2003-10-25
+++ b/WebCore/ChangeLog-2003-10-25
@@ -1,3 +1,12 @@
+2003-09-02  Darin Adler  <darin at apple.com>
+
+        Reviewed by John.
+
+        - fixed 3403388 -- decoder mishandles pages which fill the decoding buffer (mainly ISO-2022-JP)
+
+        * kwq/KWQTextCodec.mm: (KWQTextDecoder::convertUsingTEC): Keep decoding, passing in no additional bytes,
+        until we get noErr, don't ever stop after a kTECOutputBufferFullStatus error.
+
 2003-09-02  David Hyatt  <hyatt at apple.com>
 
 	Fix for 3404452, paint errors on mezzoblue.com's links list.  There was a simple
diff --git a/WebCore/ChangeLog-2005-08-23 b/WebCore/ChangeLog-2005-08-23
index 44874a7..b5dd642 100644
--- a/WebCore/ChangeLog-2005-08-23
+++ b/WebCore/ChangeLog-2005-08-23
@@ -1,3 +1,12 @@
+2003-09-02  Darin Adler  <darin at apple.com>
+
+        Reviewed by John.
+
+        - fixed 3403388 -- decoder mishandles pages which fill the decoding buffer (mainly ISO-2022-JP)
+
+        * kwq/KWQTextCodec.mm: (KWQTextDecoder::convertUsingTEC): Keep decoding, passing in no additional bytes,
+        until we get noErr, don't ever stop after a kTECOutputBufferFullStatus error.
+
 2003-09-02  David Hyatt  <hyatt at apple.com>
 
 	Fix for 3404452, paint errors on mezzoblue.com's links list.  There was a simple
diff --git a/WebCore/kwq/KWQTextCodec.mm b/WebCore/kwq/KWQTextCodec.mm
index 7288d50..4692662 100644
--- a/WebCore/kwq/KWQTextCodec.mm
+++ b/WebCore/kwq/KWQTextCodec.mm
@@ -403,11 +403,12 @@ QString KWQTextDecoder::convertUsingTEC(const unsigned char *chs, int len, bool
 
     const unsigned char *sourcePointer = chs;
     int sourceLength = len;
+    bool bufferWasFull = false;
     UniChar buffer[4096];
 
-    while (sourceLength) {
-        int bytesRead;
-        int bytesWritten;
+    while (sourceLength || bufferWasFull) {
+        int bytesRead = 0;
+        int bytesWritten = 0;
         OSStatus status = convertOneChunkUsingTEC(sourcePointer, sourceLength, bytesRead, buffer, sizeof(buffer), bytesWritten);
         ASSERT(bytesRead <= sourceLength);
         sourcePointer += bytesRead;
@@ -446,6 +447,8 @@ QString KWQTextDecoder::convertUsingTEC(const unsigned char *chs, int len, bool
         }
 
         appendOmittingNullsAndBOMs(result, buffer, bytesWritten);
+
+        bufferWasFull = status == kTECOutputBufferFullStatus;
     }
     
     if (flush) {

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list