From 33e60e8e78543462d31e8c6a7c3577ffe18b6647 Mon Sep 17 00:00:00 2001 From: tpearson Date: Wed, 29 Sep 2010 05:15:51 +0000 Subject: Critical security patches for the following vulnerabilities: CVE-2009-0689 CVE-2009-1687 CVE-2009-1690 CVE-2009-1698 CVE-2009-2702 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdelibs@1180823 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- khtml/html/htmlparser.cpp | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) (limited to 'khtml/html/htmlparser.cpp') diff --git a/khtml/html/htmlparser.cpp b/khtml/html/htmlparser.cpp index 703186689..9da99f4b3 100644 --- a/khtml/html/htmlparser.cpp +++ b/khtml/html/htmlparser.cpp @@ -195,7 +195,6 @@ void KHTMLParser::reset() form = 0; map = 0; - head = 0; end = false; isindex = 0; @@ -612,8 +611,7 @@ bool KHTMLParser::insertNode(NodeImpl *n, bool flat) case ID_BASE: if(!head) { head = new HTMLHeadElementImpl(document); - e = head; - insertNode(e); + insertNode(head.get()); handled = true; } break; @@ -835,7 +833,7 @@ NodeImpl *KHTMLParser::getElement(Token* t) case ID_HEAD: if(!head && current->id() == ID_HTML) { head = new HTMLHeadElementImpl(document); - n = head; + n = head.get(); } break; case ID_BODY: @@ -1684,12 +1682,12 @@ void KHTMLParser::createHead() head = new HTMLHeadElementImpl(document); HTMLElementImpl *body = doc()->body(); int exceptioncode = 0; - doc()->firstChild()->insertBefore(head, body, exceptioncode); + doc()->firstChild()->insertBefore(head.get(), body, exceptioncode); if ( exceptioncode ) { #ifdef PARSER_DEBUG kdDebug( 6035 ) << "creation of head failed!!!!" << endl; #endif - delete head; + delete head.get(); head = 0; } } -- cgit v1.2.1