From 471b287f700f4e74c940399d43567ca06dad779a Mon Sep 17 00:00:00 2001 From: Klaus Schmidinger Date: Sun, 1 Feb 2015 14:59:52 +0100 Subject: Fixed a memory leak in case of broken Extended Event Descriptors --- eit.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'eit.c') diff --git a/eit.c b/eit.c index 30c017b5..1f960bb2 100644 --- a/eit.c +++ b/eit.c @@ -8,7 +8,7 @@ * Robert Schneider and Rolf Hakenes . * Adapted to 'libsi' for VDR 1.3.0 by Marcel Wiesweg . * - * $Id: eit.c 3.5 2014/02/08 14:20:27 kls Exp $ + * $Id: eit.c 3.6 2015/02/01 14:55:27 kls Exp $ */ #include "eit.h" @@ -136,8 +136,8 @@ cEIT::cEIT(cSchedules *Schedules, int Source, u_char Tid, const u_char *Data, bo UseExtendedEventDescriptor = true; } if (UseExtendedEventDescriptor) { - ExtendedEventDescriptors->Add(eed); - d = NULL; // so that it is not deleted + if (ExtendedEventDescriptors->Add(eed)) + d = NULL; // so that it is not deleted } if (eed->getDescriptorNumber() == eed->getLastDescriptorNumber()) UseExtendedEventDescriptor = false; -- cgit v1.2.3