From 780da9a465e14d843b1f8bce818043a5803a489e Mon Sep 17 00:00:00 2001 From: Kalmer Apinis Date: Wed, 2 Apr 2014 14:46:26 +0200 Subject: [PATCH] unknown files --- src/g2html/Loc.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/g2html/Loc.java b/src/g2html/Loc.java index b92b878..3064a0c 100644 --- a/src/g2html/Loc.java +++ b/src/g2html/Loc.java @@ -48,7 +48,10 @@ static public void parseLocNode(XMLStreamReader parser, Result res, ResultStats int eventType = readcc.getEventType(); // add function name to the loc xml-node if (eventType==XMLStreamConstants.START_ELEMENT && readcc.getLocalName()=="loc"){ - xmlOutStream.writeAttribute("fun",fileStats.getNodeFun(id)); + String funName = fileStats.getNodeFun(id); + if (null==funName) + funName = "unknown"; + xmlOutStream.writeAttribute("fun",funName); // stop at the conclusion of the loc xml-node } else if (eventType==XMLStreamConstants.END_ELEMENT && readcc.getLocalName()=="loc"){ break;