From 71601e363e730bc073dcc435da8de1d0e3453436 Mon Sep 17 00:00:00 2001 From: Klaus Schmidinger Date: Tue, 14 Feb 2017 11:04:24 +0100 Subject: [PATCH] Fixed setting the local machine's SVDRP host name --- HISTORY | 4 +++- config.c | 4 ++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/HISTORY b/HISTORY index 50ba2162..221a1bc4 100644 --- a/HISTORY +++ b/HISTORY @@ -8882,7 +8882,7 @@ Video Disk Recorder Revision History - Added a short sleep to cTSBuffer::Action() to avoid high CPU usage (thanks to Sergey Chernyavskiy). -2017-01-23: Version 2.3.3 +2017-02-14: Version 2.3.3 - Added 'S3W ABS-3A' to sources.conf (thanks to Frank Richter). - Fixed a possible deadlock in the recordings handler thread. @@ -8910,3 +8910,5 @@ Video Disk Recorder Revision History - The LCARS skin now displays the master CAM's number when a device is tuned to an encrypted channel. - The Setup/CAM menu now only displays master CAMs. +- Fixed setting the local machine's SVDRP host name (was overwritten if setup.conf + contained an empty string). diff --git a/config.c b/config.c index e5f5463c..79eec8a3 100644 --- a/config.c +++ b/config.c @@ -4,7 +4,7 @@ * See the main source file 'vdr.c' for copyright information and * how to reach the author. * - * $Id: config.c 4.4 2015/09/13 11:09:44 kls Exp $ + * $Id: config.c 4.5 2017/02/14 11:02:48 kls Exp $ */ #include "config.h" @@ -640,7 +640,7 @@ bool cSetup::Parse(const char *Name, const char *Value) else if (!strcasecmp(Name, "EPGLinger")) EPGLinger = atoi(Value); else if (!strcasecmp(Name, "SVDRPTimeout")) SVDRPTimeout = atoi(Value); else if (!strcasecmp(Name, "SVDRPPeering")) SVDRPPeering = atoi(Value); - else if (!strcasecmp(Name, "SVDRPHostName")) strn0cpy(SVDRPHostName, Value, sizeof(SVDRPHostName)); + else if (!strcasecmp(Name, "SVDRPHostName")) { if (!*SVDRPHostName) strn0cpy(SVDRPHostName, Value, sizeof(SVDRPHostName)); } else if (!strcasecmp(Name, "SVDRPdefaultHost")) strn0cpy(SVDRPDefaultHost, Value, sizeof(SVDRPDefaultHost)); else if (!strcasecmp(Name, "ZapTimeout")) ZapTimeout = atoi(Value); else if (!strcasecmp(Name, "ChannelEntryTimeout")) ChannelEntryTimeout= atoi(Value);