From b4fccb307c49121ef4d9d7425bb7205eb30f5321 Mon Sep 17 00:00:00 2001 From: Jacek Jendrzej Date: Sun, 17 Apr 2016 20:04:15 +0200 Subject: [PATCH] src/eitd/xmlutil.cpp fix possible segfault --- src/eitd/xmlutil.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/eitd/xmlutil.cpp b/src/eitd/xmlutil.cpp index c88461e06..6748e14f5 100644 --- a/src/eitd/xmlutil.cpp +++ b/src/eitd/xmlutil.cpp @@ -306,7 +306,10 @@ bool readEventsFromFile(std::string &epgname, int &ev_count) onid = xmlGetNumericAttribute(service, "original_network_id", 16); tsid = xmlGetNumericAttribute(service, "transport_stream_id", 16); sid = xmlGetNumericAttribute(service, "service_id", 16); - + if(!onid || !tsid || !sid){ + service = xmlNextNode(service); + continue; + } event = xmlChildrenNode(service); while (event) {