mirror of
https://github.com/VDR4Arch/vdr.git
synced 2023-10-10 13:36:52 +02:00
Fixed setting the local machine's SVDRP host name; only saving the SVDRP host name if it differs from the system's host name
This commit is contained in:
parent
3b1b5bde68
commit
0f1f277819
3
HISTORY
3
HISTORY
@ -9043,3 +9043,6 @@ Video Disk Recorder Revision History
|
|||||||
#define VDR_NO_STL_PROTOTYPES
|
#define VDR_NO_STL_PROTOTYPES
|
||||||
before including tools.h.
|
before including tools.h.
|
||||||
- Removed TsGetContinuityCounter() from remux.h, using TsContinuityCounter() instead.
|
- Removed TsGetContinuityCounter() from remux.h, using TsContinuityCounter() instead.
|
||||||
|
- Fixed setting the local machine's SVDRP host name (was overwritten if setup.conf
|
||||||
|
contained an empty string). The SVDRP host name is now only written to setup.conf
|
||||||
|
if it differs from the system's host name.
|
||||||
|
6
config.c
6
config.c
@ -4,7 +4,7 @@
|
|||||||
* See the main source file 'vdr.c' for copyright information and
|
* See the main source file 'vdr.c' for copyright information and
|
||||||
* how to reach the author.
|
* how to reach the author.
|
||||||
*
|
*
|
||||||
* $Id: config.c 4.5 2017/02/14 11:02:48 kls Exp $
|
* $Id: config.c 4.6 2017/05/21 10:25:26 kls Exp $
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "config.h"
|
#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, "EPGLinger")) EPGLinger = atoi(Value);
|
||||||
else if (!strcasecmp(Name, "SVDRPTimeout")) SVDRPTimeout = atoi(Value);
|
else if (!strcasecmp(Name, "SVDRPTimeout")) SVDRPTimeout = atoi(Value);
|
||||||
else if (!strcasecmp(Name, "SVDRPPeering")) SVDRPPeering = atoi(Value);
|
else if (!strcasecmp(Name, "SVDRPPeering")) SVDRPPeering = atoi(Value);
|
||||||
else if (!strcasecmp(Name, "SVDRPHostName")) { if (!*SVDRPHostName) strn0cpy(SVDRPHostName, Value, sizeof(SVDRPHostName)); }
|
else if (!strcasecmp(Name, "SVDRPHostName")) { if (*Value) strn0cpy(SVDRPHostName, Value, sizeof(SVDRPHostName)); }
|
||||||
else if (!strcasecmp(Name, "SVDRPdefaultHost")) strn0cpy(SVDRPDefaultHost, Value, sizeof(SVDRPDefaultHost));
|
else if (!strcasecmp(Name, "SVDRPdefaultHost")) strn0cpy(SVDRPDefaultHost, Value, sizeof(SVDRPDefaultHost));
|
||||||
else if (!strcasecmp(Name, "ZapTimeout")) ZapTimeout = atoi(Value);
|
else if (!strcasecmp(Name, "ZapTimeout")) ZapTimeout = atoi(Value);
|
||||||
else if (!strcasecmp(Name, "ChannelEntryTimeout")) ChannelEntryTimeout= atoi(Value);
|
else if (!strcasecmp(Name, "ChannelEntryTimeout")) ChannelEntryTimeout= atoi(Value);
|
||||||
@ -771,7 +771,7 @@ bool cSetup::Save(void)
|
|||||||
Store("EPGLinger", EPGLinger);
|
Store("EPGLinger", EPGLinger);
|
||||||
Store("SVDRPTimeout", SVDRPTimeout);
|
Store("SVDRPTimeout", SVDRPTimeout);
|
||||||
Store("SVDRPPeering", SVDRPPeering);
|
Store("SVDRPPeering", SVDRPPeering);
|
||||||
Store("SVDRPHostName", SVDRPHostName);
|
Store("SVDRPHostName", strcmp(SVDRPHostName, GetHostName()) ? SVDRPHostName : "");
|
||||||
Store("SVDRPDefaultHost", SVDRPDefaultHost);
|
Store("SVDRPDefaultHost", SVDRPDefaultHost);
|
||||||
Store("ZapTimeout", ZapTimeout);
|
Store("ZapTimeout", ZapTimeout);
|
||||||
Store("ChannelEntryTimeout",ChannelEntryTimeout);
|
Store("ChannelEntryTimeout",ChannelEntryTimeout);
|
||||||
|
Loading…
Reference in New Issue
Block a user