[rkward-cvs] SF.net SVN: rkward: [1873] trunk/rkward/rkward/misc/xmlhelper.cpp
tfry at users.sourceforge.net
tfry at users.sourceforge.net
Mon May 7 15:53:14 UTC 2007
Revision: 1873
http://svn.sourceforge.net/rkward/?rev=1873&view=rev
Author: tfry
Date: 2007-05-07 08:53:14 -0700 (Mon, 07 May 2007)
Log Message:
-----------
Make include safer
Modified Paths:
--------------
trunk/rkward/rkward/misc/xmlhelper.cpp
Modified: trunk/rkward/rkward/misc/xmlhelper.cpp
===================================================================
--- trunk/rkward/rkward/misc/xmlhelper.cpp 2007-05-07 15:52:46 UTC (rev 1872)
+++ trunk/rkward/rkward/misc/xmlhelper.cpp 2007-05-07 15:53:14 UTC (rev 1873)
@@ -79,10 +79,13 @@
// import
QDomElement included = openXMLFile (inc_filename, debug_level, true, false);
- QDomElement copied = doc.importNode (included, true).toElement ();
- // insert everything within the document tag
- replaceWithChildren (&el, copied);
+ if (!included.isNull ()) {
+ QDomElement copied = doc.importNode (included, true).toElement ();
+
+ // insert everything within the document tag
+ replaceWithChildren (&el, copied);
+ }
}
}
@@ -150,8 +153,6 @@
replaceWithChildren (&ref, snippet.cloneNode (true).toElement ());
}
- qDebug ("%s", from_doc.ownerDocument().toString ().latin1 ());
-
return from_doc;
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the rkward-tracker
mailing list