From patchwork Sat Jan 5 08:26:26 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mika Laitio X-Patchwork-Id: 16136 Received: from localhost ([127.0.0.1] helo=www.linuxtv.org) by www.linuxtv.org with esmtp (Exim 4.72) (envelope-from ) id 1TrP5m-00032S-QY; Sat, 05 Jan 2013 09:26:58 +0100 Received: from mail.tu-berlin.de ([130.149.7.33]) by www.linuxtv.org with esmtp (Exim 4.72) (envelope-from ) id 1TrP5L-000325-8A for vdr@linuxtv.org; Sat, 05 Jan 2013 09:26:56 +0100 X-tubIT-Incoming-IP: 46.163.230.9 Received: from pilppa.org ([46.163.230.9] helo=shogun.pilppa.org) by mail.tu-berlin.de (exim-4.75/mailfrontend-3) with esmtps [TLSv1:AES256-SHA:256] for id 1TrP5L-00009X-D0; Sat, 05 Jan 2013 09:26:31 +0100 Received: from localhost (shogun.pilppa.org [127.0.0.1]) by shogun.pilppa.org (Postfix) with ESMTP id 73C7D11CC20F for ; Sat, 5 Jan 2013 10:26:28 +0200 (EET) X-Virus-Scanned: amavisd-new at pilppa.org Received: from shogun.pilppa.org ([127.0.0.1]) by localhost (shogun.pilppa.org [127.0.0.1]) (amavisd-new, port 10024) with LMTP id RESvNcPmCudY for ; Sat, 5 Jan 2013 10:26:26 +0200 (EET) Received: from mail.pilppa.org (mail.pilppa.org [83.102.60.31]) Message-ID: <50E7E3B2.5090508@pilppa.org> Date: Sat, 05 Jan 2013 10:26:26 +0200 From: Mika Laitio User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:10.0.11) Gecko/20121122 Thunderbird/10.0.11 MIME-Version: 1.0 To: vdr@linuxtv.org References: <50E715D8.5090703@192.168.95.249> In-Reply-To: <50E715D8.5090703@192.168.95.249> X-PMX-Version: 5.6.1.2065439, Antispam-Engine: 2.7.2.376379, Antispam-Data: 2013.1.5.81814 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_SIZE_2000_2999 0, BODY_SIZE_5000_LESS 0, BODY_SIZE_7000_LESS 0, RATWARE_LC_DIGITS_HELO 0, __ANY_URI 0, __BAT_BOUNDARY 0, __BOUNCE_CHALLENGE_SUBJ 0, __BOUNCE_NDR_SUBJ_EXEMPT 0, __CT 0, __CTYPE_HAS_BOUNDARY 0, __CTYPE_MULTIPART 0, __CTYPE_MULTIPART_MIXED 0, __HAS_FROM 0, __HAS_MSGID 0, __INT_PROD_TV 0, __MIME_TEXT_ONLY 0, __MIME_VERSION 0, __MOZILLA_MSGID 0, __MOZILLA_USER_AGENT 0, __SANE_MSGID 0, __SUBJ_ALPHA_END 0, __TO_MALFORMED_2 0, __TO_NO_NAME 0, __URI_NO_MAILTO 0, __URI_NO_PATH 0, __URI_NO_WWW 0, __USER_AGENT 0' X-LSpam-Score: -1.1 (-) X-LSpam-Report: No, score=-1.1 required=5.0 tests=BAYES_00=-1.9, RDNS_NONE=0.793, UNPARSEABLE_RELAY=0.001 autolearn=no Subject: Re: [vdr] UPnP/DLNA media server plugin for the VDR 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: , Sender: vdr-bounces@linuxtv.org Errors-To: vdr-bounces@linuxtv.org On 01/04/2013 07:48 PM, Brian-Imap wrote: > Hi, > this looks to be pretty interesting. > So where exactly does it fit in between XVDR, VNSI, streamdev, etc. > > I just bought a Samsung smart TV, haven't found a single DLNA > music server that it could receive music from (sure I've heard about > updating the headers that are sent from the server), still none of them > worked with the TV. > Seems I could watch VDR directly on the TV without any kind of Set-Top > box inbetween with this plugin. Samung has some bug's in their handling of upnp messages and therefore a MediaTomp requires for example a small patch so that samsung tv is able to show the media listing and play the recordings. I patched the Mageia's mediatomb-0.12.1-4.mga2.src.rpm version with the attached patch (found somewhere from the net) and at least Samsung 6305 with newest software works now ok with mediatomb. Mika diff -ruN mediatomb.orig/tombupnp/upnp/src/genlib/net/uri/uri.c mediatomb/tombupnp/upnp/src/genlib/net/uri/uri.c --- mediatomb.orig/tombupnp/upnp/src/genlib/net/uri/uri.c 2012-06-06 23:01:22.000000000 +0200 +++ mediatomb/tombupnp/upnp/src/genlib/net/uri/uri.c 2012-06-07 08:22:01.000000000 +0200 @@ -1042,7 +1042,8 @@ out->path_type = REL_PATH; } - if( ( ( begin_hostport + 1 ) < max ) && ( in[begin_hostport] == '/' ) + //parse hostport only if scheme was found + if( ( begin_hostport > 0 ) && ( ( begin_hostport + 1 ) < max ) && ( in[begin_hostport] == '/' ) && ( in[begin_hostport + 1] == '/' ) ) { begin_hostport += 2; @@ -1059,6 +1060,12 @@ out->hostport.text.size = 0; out->hostport.text.buff = 0; begin_path = begin_hostport; + + //remove excessive leading slashes (fix for Samsung Smart TV 2012) + while( ( ( begin_path + 1 ) < max ) && ( in[begin_path] == '/' ) && ( in[begin_path + 1] == '/') ) { + begin_path++; + } + } begin_fragment =