summaryrefslogtreecommitdiff
path: root/libsi
diff options
context:
space:
mode:
authorKlaus Schmidinger <vdr@tvdr.de>2004-05-31 08:35:12 +0200
committerKlaus Schmidinger <vdr@tvdr.de>2004-05-31 08:35:12 +0200
commit246a1c99bb390aded81257082b935bd222f2d8c6 (patch)
tree9f81aa03ac87d2851ed7253e3f21788371b12b2b /libsi
parent1bc35792d1da62b171e6358e62594eb5603c851c (diff)
downloadvdr-246a1c99bb390aded81257082b935bd222f2d8c6.tar.gz
vdr-246a1c99bb390aded81257082b935bd222f2d8c6.tar.bz2
Fixed handling descriptor loops in 'libsi'
Diffstat (limited to 'libsi')
-rw-r--r--libsi/si.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/libsi/si.c b/libsi/si.c
index 9ce46f0d..2bc8339a 100644
--- a/libsi/si.c
+++ b/libsi/si.c
@@ -6,7 +6,7 @@
* the Free Software Foundation; either version 2 of the License, or *
* (at your option) any later version. *
* *
- * $Id: si.c 1.9 2004/03/07 10:50:09 kls Exp $
+ * $Id: si.c 1.10 2004/05/29 17:06:23 kls Exp $
* *
***************************************************************************/
@@ -112,7 +112,7 @@ Descriptor *DescriptorLoop::getNext(Iterator &it, DescriptorTag tag, bool return
Descriptor *d=0;
if (it.i<getLength()) {
const unsigned char *p=data.getData(it.i);
- const unsigned char *end=p+getLength();
+ const unsigned char *end=p+getLength()-it.i;
while (p < end) {
if (Descriptor::getDescriptorTag(p) == tag) {
d=createDescriptor(it.i, returnUnimplemetedDescriptor);
@@ -130,7 +130,7 @@ Descriptor *DescriptorLoop::getNext(Iterator &it, DescriptorTag *tags, int array
Descriptor *d=0;
if (it.i<getLength()) {
const unsigned char *p=data.getData(it.i);
- const unsigned char *end=p+getLength();
+ const unsigned char *end=p+getLength()-it.i;
while (p < end) {
for (int u=0; u<arrayLength;u++)
if (Descriptor::getDescriptorTag(p) == tags[u]) {