[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 06:56:35 UTC 2009


The following commit has been merged in the debian/unstable branch:
commit dd0ee4b5775cb1337666ceebc425ef9be6b0013c
Author: darin <darin at 268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Sat Nov 2 00:28:35 2002 +0000

    	- fixed 3062598 -- meta refresh of 0.1s fails
    
    	KHTML was using an integer for the delay.
    
            * khtml/khtml_part.h: Make scheduleRedirection take a double.
            * khtml/khtmlpart_p.h: Make m_delayRedirect be a double.
            * khtml/khtml_part.cpp:
            (KHTMLPart::slotData): Use a double when parsing meta refresh.
            (KHTMLPart::checkCompleted): Cast to int when passing to timer start.
            (KHTMLPart::scheduleRedirection): Cast to int when passing to timer
    	start; also check for absurd values and do nothing.
            (KHTMLPart::slotParentCompleted): Cast to int when passing to timer start.
    
            * khtml/xml/dom_docimpl.cpp: (DocumentImpl::processHttpEquiv):
    	Use a double when parsing meta refresh.
    
            * kwq/KWQKDebug.h: Add overloads for unsigned int and double to keep us
    	compiling now that we use a double in one place.
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@2534 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebCore/ChangeLog-2002-12-03 b/WebCore/ChangeLog-2002-12-03
index 5bdfea9..f94fbce 100644
--- a/WebCore/ChangeLog-2002-12-03
+++ b/WebCore/ChangeLog-2002-12-03
@@ -1,5 +1,26 @@
 2002-11-01  Darin Adler  <darin at apple.com>
 
+	- fixed 3062598 -- meta refresh of 0.1s fails
+
+	KHTML was using an integer for the delay.
+
+        * khtml/khtml_part.h: Make scheduleRedirection take a double.
+        * khtml/khtmlpart_p.h: Make m_delayRedirect be a double.
+        * khtml/khtml_part.cpp:
+        (KHTMLPart::slotData): Use a double when parsing meta refresh.
+        (KHTMLPart::checkCompleted): Cast to int when passing to timer start.
+        (KHTMLPart::scheduleRedirection): Cast to int when passing to timer
+	start; also check for absurd values and do nothing.
+        (KHTMLPart::slotParentCompleted): Cast to int when passing to timer start.
+
+        * khtml/xml/dom_docimpl.cpp: (DocumentImpl::processHttpEquiv):
+	Use a double when parsing meta refresh.
+
+        * kwq/KWQKDebug.h: Add overloads for unsigned int and double to keep us
+	compiling now that we use a double in one place.
+
+2002-11-01  Darin Adler  <darin at apple.com>
+
 	- fixed 3090249 -- random crash on page load
 	- fixed 3090286 -- assert _job in KWQResourceLoader cancel
 
diff --git a/WebCore/ChangeLog-2003-10-25 b/WebCore/ChangeLog-2003-10-25
index 5bdfea9..f94fbce 100644
--- a/WebCore/ChangeLog-2003-10-25
+++ b/WebCore/ChangeLog-2003-10-25
@@ -1,5 +1,26 @@
 2002-11-01  Darin Adler  <darin at apple.com>
 
+	- fixed 3062598 -- meta refresh of 0.1s fails
+
+	KHTML was using an integer for the delay.
+
+        * khtml/khtml_part.h: Make scheduleRedirection take a double.
+        * khtml/khtmlpart_p.h: Make m_delayRedirect be a double.
+        * khtml/khtml_part.cpp:
+        (KHTMLPart::slotData): Use a double when parsing meta refresh.
+        (KHTMLPart::checkCompleted): Cast to int when passing to timer start.
+        (KHTMLPart::scheduleRedirection): Cast to int when passing to timer
+	start; also check for absurd values and do nothing.
+        (KHTMLPart::slotParentCompleted): Cast to int when passing to timer start.
+
+        * khtml/xml/dom_docimpl.cpp: (DocumentImpl::processHttpEquiv):
+	Use a double when parsing meta refresh.
+
+        * kwq/KWQKDebug.h: Add overloads for unsigned int and double to keep us
+	compiling now that we use a double in one place.
+
+2002-11-01  Darin Adler  <darin at apple.com>
+
 	- fixed 3090249 -- random crash on page load
 	- fixed 3090286 -- assert _job in KWQResourceLoader cancel
 
diff --git a/WebCore/ChangeLog-2005-08-23 b/WebCore/ChangeLog-2005-08-23
index 5bdfea9..f94fbce 100644
--- a/WebCore/ChangeLog-2005-08-23
+++ b/WebCore/ChangeLog-2005-08-23
@@ -1,5 +1,26 @@
 2002-11-01  Darin Adler  <darin at apple.com>
 
+	- fixed 3062598 -- meta refresh of 0.1s fails
+
+	KHTML was using an integer for the delay.
+
+        * khtml/khtml_part.h: Make scheduleRedirection take a double.
+        * khtml/khtmlpart_p.h: Make m_delayRedirect be a double.
+        * khtml/khtml_part.cpp:
+        (KHTMLPart::slotData): Use a double when parsing meta refresh.
+        (KHTMLPart::checkCompleted): Cast to int when passing to timer start.
+        (KHTMLPart::scheduleRedirection): Cast to int when passing to timer
+	start; also check for absurd values and do nothing.
+        (KHTMLPart::slotParentCompleted): Cast to int when passing to timer start.
+
+        * khtml/xml/dom_docimpl.cpp: (DocumentImpl::processHttpEquiv):
+	Use a double when parsing meta refresh.
+
+        * kwq/KWQKDebug.h: Add overloads for unsigned int and double to keep us
+	compiling now that we use a double in one place.
+
+2002-11-01  Darin Adler  <darin at apple.com>
+
 	- fixed 3090249 -- random crash on page load
 	- fixed 3090286 -- assert _job in KWQResourceLoader cancel
 
diff --git a/WebCore/khtml/khtml_part.cpp b/WebCore/khtml/khtml_part.cpp
index 46aa051..41e2233 100644
--- a/WebCore/khtml/khtml_part.cpp
+++ b/WebCore/khtml/khtml_part.cpp
@@ -1070,20 +1070,20 @@ void KHTMLPart::slotData( KIO::Job* kio_job, const QByteArray &data )
     if( !qData.isEmpty() && d->m_metaRefreshEnabled )
     {
       kdDebug(6050) << "HTTP Refresh Request: " << qData << endl;
-      int delay;
+      double delay;
       int pos = qData.find( ';' );
       if ( pos == -1 )
         pos = qData.find( ',' );
 
       if( pos == -1 )
       {
-        delay = qData.stripWhiteSpace().toInt();
-        scheduleRedirection( qData.toInt(), m_url.url());
+        delay = qData.stripWhiteSpace().toDouble();
+        scheduleRedirection( delay, m_url.url());
       }
       else
       {
         int end_pos = qData.length();
-        delay = qData.left(pos).stripWhiteSpace().toInt();
+        delay = qData.left(pos).stripWhiteSpace().toDouble();
         while ( qData[++pos] == ' ' );
         if ( qData.find( "url", pos, false ) == pos )
         {
@@ -1639,7 +1639,7 @@ void KHTMLPart::checkCompleted()
     // Do not start redirection for frames here! That action is
     // deferred until the parent emits a completed signal.
     if ( parentPart() == 0 )
-      d->m_redirectionTimer.start( 1000 * d->m_delayRedirect, true );
+      d->m_redirectionTimer.start( (int)(1000 * d->m_delayRedirect), true );
 
     emit completed( true );
   }
@@ -1743,9 +1743,11 @@ KURL KHTMLPart::completeURL( const QString &url )
   return KURL( d->m_doc->completeURL( url ) );
 }
 
-void KHTMLPart::scheduleRedirection( int delay, const QString &url, bool doLockHistory )
+void KHTMLPart::scheduleRedirection( double delay, const QString &url, bool doLockHistory )
 {
     kdDebug(6050) << "KHTMLPart::scheduleRedirection delay=" << delay << " url=" << url << endl;
+    if (delay < 0 || delay > INT_MAX / 1000)
+      return;
     if( d->m_redirectURL.isEmpty() || delay < d->m_delayRedirect )
     {
        d->m_delayRedirect = delay;
@@ -1753,7 +1755,7 @@ void KHTMLPart::scheduleRedirection( int delay, const QString &url, bool doLockH
        d->m_redirectLockHistory = doLockHistory;
        if ( d->m_bComplete ) {
          d->m_redirectionTimer.stop();
-         d->m_redirectionTimer.start( 1000 * d->m_delayRedirect, true );
+         d->m_redirectionTimer.start( (int)(1000 * d->m_delayRedirect), true );
        }
     }
 }
@@ -3206,7 +3208,7 @@ void KHTMLPart::slotParentCompleted()
   if ( !d->m_redirectURL.isEmpty() && !d->m_redirectionTimer.isActive() )
   {
     // kdDebug(6050) << this << ": Child redirection -> " << d->m_redirectURL << endl;
-    d->m_redirectionTimer.start( 1000 * d->m_delayRedirect, true );
+    d->m_redirectionTimer.start( (int)(1000 * d->m_delayRedirect), true );
   }
 }
 
diff --git a/WebCore/khtml/khtml_part.h b/WebCore/khtml/khtml_part.h
index 87b9375..e35c8d2 100644
--- a/WebCore/khtml/khtml_part.h
+++ b/WebCore/khtml/khtml_part.h
@@ -372,7 +372,7 @@ public:
   /**
    * Schedules a redirection after @p delay seconds.
    */
-  void scheduleRedirection( int delay, const QString &url, bool lockHistory = true );
+  void scheduleRedirection( double delay, const QString &url, bool lockHistory = true );
 
   /**
    * Clears the widget and prepares it for new content.
diff --git a/WebCore/khtml/khtmlpart_p.h b/WebCore/khtml/khtmlpart_p.h
index 721d1ee..243c2ae 100644
--- a/WebCore/khtml/khtmlpart_p.h
+++ b/WebCore/khtml/khtmlpart_p.h
@@ -268,7 +268,7 @@ public:
   KIO::CacheControl m_cachePolicy;
   QTimer m_redirectionTimer;
   QTime m_parsetime;
-  int m_delayRedirect;
+  double m_delayRedirect;
   QString m_redirectURL;
 
   KAction *m_paViewDocument;
diff --git a/WebCore/khtml/xml/dom_docimpl.cpp b/WebCore/khtml/xml/dom_docimpl.cpp
index fefe7f7..39a0c9e 100644
--- a/WebCore/khtml/xml/dom_docimpl.cpp
+++ b/WebCore/khtml/xml/dom_docimpl.cpp
@@ -1428,11 +1428,11 @@ void DocumentImpl::processHttpEquiv(const DOMString &equiv, const DOMString &con
 	    delay = content.implementation()->toInt(&ok);
             if(ok) v->part()->scheduleRedirection(delay, v->part()->url().url() );
         } else {
-            int delay = 0;
+            double delay = 0;
             bool ok = false;
 
 	    DOMStringImpl* s = content.implementation()->substring(0, pos);
-	    delay = s->toInt(&ok);
+	    delay = QConstString(s->s, s->l).string().toDouble(&ok);
 	    delete s;
 
             pos++;
diff --git a/WebCore/kwq/KWQKDebug.h b/WebCore/kwq/KWQKDebug.h
index 3ba997d..05a1759 100644
--- a/WebCore/kwq/KWQKDebug.h
+++ b/WebCore/kwq/KWQKDebug.h
@@ -38,6 +38,8 @@ public:
     kdbgstream(unsigned int area = 0, unsigned int level = 0, bool print = true) { }
     
     kdbgstream &operator<<(int) { return *this; }
+    kdbgstream &operator<<(unsigned int) { return *this; }
+    kdbgstream &operator<<(double) { return *this; }
     kdbgstream &operator<<(const char *) { return *this; }
     kdbgstream &operator<<(const void *) { return *this; }
     kdbgstream &operator<<(const QString &) { return *this; }

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list