[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Gnash-commit] gnash ChangeLog server/asobj/xml.cpp server/aso...
From: |
Benjamin Wolsey |
Subject: |
[Gnash-commit] gnash ChangeLog server/asobj/xml.cpp server/aso... |
Date: |
Wed, 14 Nov 2007 09:16:50 +0000 |
CVSROOT: /sources/gnash
Module name: gnash
Changes by: Benjamin Wolsey <bwy> 07/11/14 09:16:50
Modified files:
. : ChangeLog
server/asobj : xml.cpp xmlnode.cpp
Log message:
* server/asobj/xml.cpp: (getXMLOptions) strip CDATA nodes
and just add text (fixes part of bug 21268); (extractNode)
drop comment nodes but continue to parse siblings (they can
be siblings of a text node).
* server/asobj/xmlnode.cpp: minor cleanups, better debugging
output.
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/gnash/ChangeLog?cvsroot=gnash&r1=1.4854&r2=1.4855
http://cvs.savannah.gnu.org/viewcvs/gnash/server/asobj/xml.cpp?cvsroot=gnash&r1=1.51&r2=1.52
http://cvs.savannah.gnu.org/viewcvs/gnash/server/asobj/xmlnode.cpp?cvsroot=gnash&r1=1.39&r2=1.40
Patches:
Index: ChangeLog
===================================================================
RCS file: /sources/gnash/gnash/ChangeLog,v
retrieving revision 1.4854
retrieving revision 1.4855
diff -u -b -r1.4854 -r1.4855
--- ChangeLog 14 Nov 2007 08:16:03 -0000 1.4854
+++ ChangeLog 14 Nov 2007 09:16:49 -0000 1.4855
@@ -1,3 +1,11 @@
+2007-11-14 Benjamin Wolsey <address@hidden>
+
+ * server/asobj/xml.cpp: (getXMLOptions) strip CDATA nodes
+ and just add text (fixes part of bug 21268); (extractNode)
+ drop comment nodes but continue to parse siblings (they can
+ be siblings of a text node).
+ * server/asobj/xmlnode.cpp: minor cleanups, better debugging output.
+
2007-11-14 Sandro Santilli <address@hidden>
* testsuite/misc-ming.all/ButtonEventsTest.c: add self-contained
Index: server/asobj/xml.cpp
===================================================================
RCS file: /sources/gnash/gnash/server/asobj/xml.cpp,v
retrieving revision 1.51
retrieving revision 1.52
diff -u -b -r1.51 -r1.52
--- server/asobj/xml.cpp 20 Oct 2007 10:47:14 -0000 1.51
+++ server/asobj/xml.cpp 14 Nov 2007 09:16:49 -0000 1.52
@@ -17,7 +17,7 @@
// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
//
-/* $Id: xml.cpp,v 1.51 2007/10/20 10:47:14 strk Exp $ */
+/* $Id: xml.cpp,v 1.52 2007/11/14 09:16:49 bwy Exp $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
@@ -276,8 +276,14 @@
element._attributes.push_back(attrib);
attr = attr->next;
}
-
- if (node->type == XML_ELEMENT_NODE)
+ if (node->type == XML_COMMENT_NODE)
+ {
+ // Comments apparently not handled until AS3
+ // Comments in a text node are a *sibling* of the text node
+ // for libxml2.
+ return false;
+ }
+ else if (node->type == XML_ELEMENT_NODE)
{
element.nodeTypeSet(tElement);
@@ -316,8 +322,7 @@
{
child = new XMLNode();
child->setParent(&element);
- if ( ! extractNode(*child, childnode, mem) ) break;
- element._children.push_back(child);
+ if ( extractNode(*child, childnode, mem) )
element._children.push_back(child);
childnode = childnode->next;
}
@@ -907,7 +912,10 @@
int
XML::getXMLOptions() const
{
- int options = XML_PARSE_RECOVER | XML_PARSE_NOWARNING | XML_PARSE_NOERROR;
+ int options = XML_PARSE_RECOVER | XML_PARSE_NOWARNING
+ | XML_PARSE_NOERROR | XML_PARSE_NOCDATA;
+ // Using libxml2 to convert CDATA nodes to text seems to be what is
+ // required.
if ( ignoreWhite() )
{
Index: server/asobj/xmlnode.cpp
===================================================================
RCS file: /sources/gnash/gnash/server/asobj/xmlnode.cpp,v
retrieving revision 1.39
retrieving revision 1.40
diff -u -b -r1.39 -r1.40
--- server/asobj/xmlnode.cpp 31 Aug 2007 21:53:32 -0000 1.39
+++ server/asobj/xmlnode.cpp 14 Nov 2007 09:16:50 -0000 1.40
@@ -16,7 +16,7 @@
// along with this program; if not, write to the Free Software
// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
-/* $Id: xmlnode.cpp,v 1.39 2007/08/31 21:53:32 strk Exp $ */
+/* $Id: xmlnode.cpp,v 1.40 2007/11/14 09:16:50 bwy Exp $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
@@ -71,7 +71,7 @@
static as_value xmlnode_parentNode(const fn_call& fn);
as_object* getXMLNodeInterface();
-static LogFile& dbglogfile = gnash::LogFile::getDefaultInstance();
+//static LogFile& dbglogfile = gnash::LogFile::getDefaultInstance();
//std::vector<as_object *> _xmlobjs; // FIXME: hack alert
@@ -124,7 +124,7 @@
{
//log_msg("%s: %p", __PRETTY_FUNCTION__, this);
#ifdef DEBUG_MEMORY_ALLOCATION
- log_msg(_("\tDeleting XMLNode data %s at %p"), this->_name.c_str(), this);
+ log_msg(_("\tDeleting XMLNode data %s with value %s at %p"),
this->_name.c_str(), this->_value.c_str(), this);
#endif
}
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Gnash-commit] gnash ChangeLog server/asobj/xml.cpp server/aso...,
Benjamin Wolsey <=