Skip to content

Commit bcbd279

Browse files
committed
DefaultUserAgent: the value given by META http-equiv="default-style" was not being set (bug).
(cherry picked from commit a355549)
1 parent ab1d6e5 commit bcbd279

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/io/sf/carte/doc/agent/net/DefaultUserAgent.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -161,7 +161,7 @@ public DOMDocument readURL(URL url) throws IOException, io.sf.carte.doc.Document
161161
for (int i = listL - 1; i >= 0; i--) {
162162
if ("Default-Style".equalsIgnoreCase(((Element) list.item(i)).getAttribute("http-equiv"))) {
163163
String metaDefStyle = ((Element) list.item(i)).getAttribute("content");
164-
if (metaDefStyle.length() == 0) {
164+
if (metaDefStyle.length() != 0) {
165165
// Per HTML4 spec § 14.3.2:
166166
// "If two or more META declarations or HTTP headers specify
167167
// the preferred style sheet, the last one takes precedence."

0 commit comments

Comments
 (0)