From patchwork Sun Apr 8 16:38:45 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Patrick Boettcher X-Patchwork-Id: 12939 Received: from mail.tu-berlin.de ([130.149.7.33]) by www.linuxtv.org with esmtp (Exim 4.72) (envelope-from ) id 1SGv8e-0007nN-3T for vdr@linuxtv.org; Sun, 08 Apr 2012 18:39:17 +0200 X-tubIT-Incoming-IP: 74.125.82.182 Received: from mail-we0-f182.google.com ([74.125.82.182]) by mail.tu-berlin.de (exim-4.75/mailfrontend-4) with esmtps [TLSv1:RC4-SHA:128] for id 1SGv8d-0002hH-Bp; Sun, 08 Apr 2012 18:38:51 +0200 Received: by wern13 with SMTP id n13so2647164wer.41 for ; Sun, 08 Apr 2012 09:38:50 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=from:organization:to:subject:date:user-agent:mime-version :content-type:message-id:x-gm-message-state; bh=D5xC03L4A2YqKk44z3q/u2jZWv2HmOpt5F0VeFmMquk=; b=goEoOZ/ypOQLzUA7giVFNOCqbOlNYUpfKqPtVVrofQp3fAeeC2H8rdWqm9LIBWSdft XiYSpdFS8csl9vdNOXe+FOpqI1u71YFBmYTP+pOPHp+AK8/+UgJay1RaT6d+XsDlL9QU QHgh45kFJdwOAZ7fvL71SrMk5YMC6+Qhohh8mw77c8aIhHqnoJlXUENDfD8gccIoHT8Z F7YS1TTMH49R+nJknJjScH5FGgQB7MLFeG+45IqQ2HHrATWj9zftAxyWcgudUsp8X7nv RN5gWfGr+AQrw5drmoC+cE5e9QSD1RMeCZYbmJMnGvJ71OKhD1L/H2BPjZIYhIi5iMDh KfjA== Received: by 10.180.91.10 with SMTP id ca10mr10134444wib.17.1333903130424; Sun, 08 Apr 2012 09:38:50 -0700 (PDT) Received: from vdr.localnet (etr91-2-88-188-115-138.fbx.proxad.net. [88.188.115.138]) by mx.google.com with ESMTPS id fz9sm23498348wib.3.2012.04.08.09.38.48 (version=TLSv1/SSLv3 cipher=OTHER); Sun, 08 Apr 2012 09:38:49 -0700 (PDT) From: Patrick Boettcher Organization: KernelLabs Inc. To: VDR Mailing List Date: Sun, 8 Apr 2012 18:38:45 +0200 User-Agent: KMail/1.13.7 (Linux/3.2.0-1-amd64; KDE/4.7.4; x86_64; ; ) MIME-Version: 1.0 Message-Id: <201204081838.46069.pboettcher@kernellabs.com> X-Gm-Message-State: ALoCoQkhY433GsGp00IiNoiGZ3R5zEQqmjtTxE1AgjdXeTbEiv/zXQ2jy/edWjhTt/wQ7fZ6CS8R X-PMX-Version: 5.6.1.2065439, Antispam-Engine: 2.7.2.376379, Antispam-Data: 2012.4.8.162415 X-PMX-Spam: Gauge=IIIIIIII, Probability=8%, Report=' HTML_00_01 0.05, HTML_00_10 0.05, MIME_TEXT_ONLY_MP_MIXED 0.05, BODYTEXTP_SIZE_3000_LESS 0, BODY_ENDS_IN_URL 0, BODY_SIZE_3000_3999 0, BODY_SIZE_5000_LESS 0, BODY_SIZE_7000_LESS 0, WEBMAIL_SOURCE 0, __ANY_URI 0, __CP_MEDIA_BODY 0, __CP_URI_IN_BODY 0, __CT 0, __CTYPE_HAS_BOUNDARY 0, __CTYPE_MULTIPART 0, __CTYPE_MULTIPART_MIXED 0, __HAS_MSGID 0, __MIME_TEXT_ONLY 0, __MIME_VERSION 0, __RDNS_GMAIL 0, __SANE_MSGID 0, __SUBJ_ALPHA_END 0, __TO_MALFORMED_2 0, __URI_NO_MAILTO 0, __URI_NS , __USER_AGENT 0' X-LSpam-Score: -1.8 (-) X-LSpam-Report: No, score=-1.8 required=5.0 tests=BAYES_00=-1.9, RCVD_IN_DNSWL_LOW=-0.7, RDNS_NONE=0.793 autolearn=no Subject: [vdr] Bug in pat.c (VDR 1.7.27) - possible fix attached X-BeenThere: vdr@linuxtv.org X-Mailman-Version: 2.1.13 Precedence: list Reply-To: VDR Mailing List List-Id: VDR Mailing List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 08 Apr 2012 16:39:17 -0000 Status: O X-Status: X-Keywords: X-UID: 26048 Hi, I located a small bug which has been introduced in 1.7.18 (at least I think so). Reading the Changes file I could not determine which change caused it, but the problem is the following. In pat.c: if the PMT of a service has a stream of stream-type 128 (0x80) the vpid is overridden with the PID signalled in the Elementary-PID-field of this stream. This happens to be the case here in France for some of the DVB- T services. It breaks 2 channels (France 2 and France 5) when channel- updates is at least configured to "update PIDs". The code which is doing that is described as "STREAMTYPE_USER_PRIVATE - DigiCipher II VIDEO (ANSI/SCTE 57)" which before was only applied when the stream had a certain descriptor and there a certain type. The attached patch resets the code to do exactly that for STREAMTYPE 0x80 - though can't check whether the digiCipher-stuff is still working. Please consider applying soon. Thanks, --- Patrick http://www.kernellabs.com/ diff --git a/pat.c b/pat.c index d9b93f6..f0d0024 100644 --- a/pat.c +++ b/pat.c @@ -456,12 +456,30 @@ void cPatFilter::Process(u_short Pid, u_char Tid, const u_char *Data, int Length } } break; - case 0x80: // STREAMTYPE_USER_PRIVATE - DigiCipher II VIDEO (ANSI/SCTE 57) - Vpid = esPid; - Ppid = pmt.getPCRPid(); - Vtype = 0x02; // compression based upon MPEG-2 - ProcessCaDescriptors = true; - break; + case 0x80: { + SI::Descriptor *d; + for (SI::Loop::Iterator it; (d = stream.streamDescriptors.getNext(it)); ) { + switch (d->getDescriptorTag()) { + case SI::RegistrationDescriptorTag: { + SI::RegistrationDescriptor *rd = (SI::RegistrationDescriptor *)d; + // http://www.smpte-ra.org/mpegreg/mpegreg.html + switch (rd->getFormatIdentifier()) { + case 0x44434949: // STREAMTYPE_USER_PRIVATE - DigiCipher II VIDEO (ANSI/SCTE 57) + Vpid = esPid; + Ppid = pmt.getPCRPid(); + Vtype = 0x02; // compression based upon MPEG-2 + ProcessCaDescriptors = true; + break; + default: + break; + } + } break; + default: + break; + } + } + } break; + case 0x81: // STREAMTYPE_USER_PRIVATE - ATSC A/53 AUDIO (ANSI/SCTE 57) { char lang[MAXLANGCODE1] = { 0 };