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

mjs mjs at 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Sat Sep 26 08:08:41 UTC 2009


The following commit has been merged in the debian/unstable branch:
commit 09aaaed0a25d8fa11f07af35e54497be3b4ab42a
Author: mjs <mjs at 268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Mon Nov 3 06:32:05 2003 +0000

            Reviewed by Darin.
    
    	- don't resolve Null href or src attributes, since the distinction
    	between empty and absent attribute is important.
    
            * khtml/dom/html_base.cpp:
            (HTMLIFrameElement::src):
            * khtml/dom/html_form.cpp:
            (HTMLInputElement::src):
            * khtml/dom/html_head.cpp:
            (HTMLBaseElement::href):
            (HTMLLinkElement::href):
            (HTMLScriptElement::src):
            * khtml/dom/html_image.cpp:
            (HTMLAreaElement::href):
            (HTMLImageElement::src):
            * khtml/dom/html_inline.cpp:
            (HTMLAnchorElement::href):
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@5360 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebCore/ChangeLog-2005-08-23 b/WebCore/ChangeLog-2005-08-23
index 3e04aad..56b6eca 100644
--- a/WebCore/ChangeLog-2005-08-23
+++ b/WebCore/ChangeLog-2005-08-23
@@ -1,3 +1,24 @@
+2003-11-02  Maciej Stachowiak  <mjs at apple.com>
+
+        Reviewed by Darin.
+
+	- don't resolve Null href or src attributes, since the distinction
+	between empty and absent attribute is important.
+
+        * khtml/dom/html_base.cpp:
+        (HTMLIFrameElement::src):
+        * khtml/dom/html_form.cpp:
+        (HTMLInputElement::src):
+        * khtml/dom/html_head.cpp:
+        (HTMLBaseElement::href):
+        (HTMLLinkElement::href):
+        (HTMLScriptElement::src):
+        * khtml/dom/html_image.cpp:
+        (HTMLAreaElement::href):
+        (HTMLImageElement::src):
+        * khtml/dom/html_inline.cpp:
+        (HTMLAnchorElement::href):
+
 2003-11-01  David Hyatt  <hyatt at apple.com>
 
 	Fix for 3468924, an implementation of outline-offset.  We also give :focus links a built-in offset of 
diff --git a/WebCore/khtml/dom/html_base.cpp b/WebCore/khtml/dom/html_base.cpp
index d16a5de..676d279 100644
--- a/WebCore/khtml/dom/html_base.cpp
+++ b/WebCore/khtml/dom/html_base.cpp
@@ -371,7 +371,8 @@ DOMString HTMLIFrameElement::src() const
 {
     if(!impl) return DOMString();
     DOMString s = ((ElementImpl *)impl)->getAttribute(ATTR_SRC);
-    s = ownerDocument().completeURL( s );
+    if (!s.isNull())
+	s = ownerDocument().completeURL( s );
     return s;
 }
 
diff --git a/WebCore/khtml/dom/html_form.cpp b/WebCore/khtml/dom/html_form.cpp
index 4d09dcf..b97c886 100644
--- a/WebCore/khtml/dom/html_form.cpp
+++ b/WebCore/khtml/dom/html_form.cpp
@@ -464,7 +464,8 @@ DOMString HTMLInputElement::src() const
 {
     if(!impl) return DOMString();
     DOMString s = static_cast<ElementImpl*>(impl)->getAttribute(ATTR_SRC);
-    s = ownerDocument().completeURL( s );
+    if (!s.isNull())
+	s = ownerDocument().completeURL( s );
     return s;
 }
 
diff --git a/WebCore/khtml/dom/html_head.cpp b/WebCore/khtml/dom/html_head.cpp
index fb25e45..b26c643 100644
--- a/WebCore/khtml/dom/html_head.cpp
+++ b/WebCore/khtml/dom/html_head.cpp
@@ -60,7 +60,8 @@ DOMString HTMLBaseElement::href() const
 {
     if(!impl) return DOMString();
     DOMString s = ((ElementImpl *)impl)->getAttribute(ATTR_HREF);
-    s = ownerDocument().completeURL( s );
+    if (!s.isNull())
+	s = ownerDocument().completeURL( s );
     return s;
 }
 
@@ -139,7 +140,8 @@ DOMString HTMLLinkElement::href() const
 {
     if(!impl) return DOMString();
     DOMString s = ((ElementImpl *)impl)->getAttribute(ATTR_HREF);
-    s = ownerDocument().completeURL( s );
+    if (!s.isNull())
+	s = ownerDocument().completeURL( s );
     return s;
 }
 
@@ -385,7 +387,8 @@ DOMString HTMLScriptElement::src() const
 {
     if(!impl) return DOMString();
     DOMString s = ((ElementImpl *)impl)->getAttribute(ATTR_SRC);
-    s = ownerDocument().completeURL( s );
+    if (!s.isNull())
+	s = ownerDocument().completeURL( s );
     return s;
 }
 
diff --git a/WebCore/khtml/dom/html_image.cpp b/WebCore/khtml/dom/html_image.cpp
index e53f07e..9d2f804 100644
--- a/WebCore/khtml/dom/html_image.cpp
+++ b/WebCore/khtml/dom/html_image.cpp
@@ -97,7 +97,8 @@ DOMString HTMLAreaElement::href() const
 {
     if(!impl) return DOMString();
     DOMString s = ((ElementImpl *)impl)->getAttribute(ATTR_HREF);
-    s = ownerDocument().completeURL( s );
+    if (!s.isNull())
+	s = ownerDocument().completeURL( s );
     return s;
 }
 
@@ -289,7 +290,8 @@ DOMString HTMLImageElement::src() const
 {
     if(!impl) return DOMString();
     DOMString s = ((ElementImpl *)impl)->getAttribute(ATTR_SRC);
-    s = ownerDocument().completeURL( s );
+    if (!s.isNull())
+	s = ownerDocument().completeURL( s );
     return s;
 }
 
diff --git a/WebCore/khtml/dom/html_inline.cpp b/WebCore/khtml/dom/html_inline.cpp
index 873b4c7..16862e4 100644
--- a/WebCore/khtml/dom/html_inline.cpp
+++ b/WebCore/khtml/dom/html_inline.cpp
@@ -96,7 +96,8 @@ DOMString HTMLAnchorElement::href() const
 {
     if(!impl) return DOMString();
     DOMString s = ((ElementImpl *)impl)->getAttribute(ATTR_HREF);
-    s = ownerDocument().completeURL( s );
+    if (!s.isNull())
+	s = ownerDocument().completeURL( s );
     return s;
 }
 
diff --git a/WebCore/kwq/KWQTextCodec.mm b/WebCore/kwq/KWQTextCodec.mm
index 66d83eb..bd5442a 100644
--- a/WebCore/kwq/KWQTextCodec.mm
+++ b/WebCore/kwq/KWQTextCodec.mm
@@ -506,7 +506,7 @@ QString KWQTextDecoder::toUnicode(const char *chs, int len, bool flush)
 {
     ASSERT_ARG(len, len >= 0);
     
-    if (_error || !chs || len <= 0) {
+    if (_error || !chs || (len <= 0 && !flush)) {
         return QString();
     }
 

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list