summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDimitar Petrovski <dimeptr@gmail.com>2015-02-15 19:16:29 (GMT)
committerDimitar Petrovski <dimeptr@gmail.com>2015-02-15 19:16:29 (GMT)
commit9cd9a75a061ed301378e8102b726549f5a0e672d (patch)
tree5a912eef793e64b5cb06128ad035957969a876bb
parentd7dc6141c91b48c410e9cc5734ca9a2adecc278e (diff)
downloadvdr-plugin-eepg-9cd9a75a061ed301378e8102b726549f5a0e672d.tar.gz
vdr-plugin-eepg-9cd9a75a061ed301378e8102b726549f5a0e672d.tar.bz2
Implement fix for memory leak in case of broken Extended Event Descriptors for vdr 2.1.9+
-rw-r--r--eit2.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/eit2.c b/eit2.c
index 4e813af..d5f928b 100644
--- a/eit2.c
+++ b/eit2.c
@@ -133,8 +133,12 @@ void cEIT2::ProcessEventDescriptors(bool ExternalData, int Source,
UseExtendedEventDescriptor = true;
}
if (UseExtendedEventDescriptor) {
+#if APIVERSNUM < 20109
ExtendedEventDescriptors->Add(eed);
- d = NULL; // so that it is not deleted
+#else
+ if (ExtendedEventDescriptors->Add(eed))
+#endif
+ d = NULL; // so that it is not deleted
}
if (eed->getDescriptorNumber() == eed->getLastDescriptorNumber())
UseExtendedEventDescriptor = false;