OMNeT++/OMNEST Bug Tracker - OMNeT++
View Issue Details
0000320OMNeT++simulation kernelpublic2011-05-23 17:352011-05-23 17:35
jesjones 
 
normalminoralways
newopen 
4.1 
 
0000320: XML types should support null
One of our guys patched nedsupport.cc to allow xml types to have default null values.
--- a/src/sim/nedsupport.cc
+++ b/src/sim/nedsupport.cc
@@ -200,6 +200,13 @@ Value XMLDoc::evaluate(cComponent *context, Value args[], int numargs)
     cXMLElement *node;
     if (numargs==1)
     {
+ if(args[0].s.empty())
+ {
+ node = NULL;
+ return node;
+ }
+
         node = ev.getXMLDocument(args[0].s.c_str(), NULL);
         if (!node)
             throw cRuntimeError("xmldoc(\"%s\"): element not found", args[0].s.c_str());
No tags attached.
Issue History
2011-05-23 17:35jesjonesNew Issue

There are no notes attached to this issue.