summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDimitar Petrovski <dimeptr@gmail.com>2015-02-15 19:08:32 (GMT)
committerDimitar Petrovski <dimeptr@gmail.com>2015-02-15 19:08:32 (GMT)
commitbae08c5a8299861111afadde92b3fbce34e758e8 (patch)
tree9b53abfe87a4421e015c18db74300da4e59134da
parentfd944ccd25762873a5235b44b23ff8cbc2147d98 (diff)
downloadvdr-plugin-eepg-bae08c5a8299861111afadde92b3fbce34e758e8.tar.gz
vdr-plugin-eepg-bae08c5a8299861111afadde92b3fbce34e758e8.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;