summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--CONTRIBUTORS2
-rw-r--r--HISTORY5
-rw-r--r--channels.c26
-rw-r--r--config.h6
4 files changed, 27 insertions, 12 deletions
diff --git a/CONTRIBUTORS b/CONTRIBUTORS
index b869c6b5..d4ae37b7 100644
--- a/CONTRIBUTORS
+++ b/CONTRIBUTORS
@@ -732,6 +732,8 @@ Sascha Volkenandt <sascha@akv-soft.de>
some broken graphics tools
for fixing a memory leak in theme description handling
for pointing out a "near miss" condition in cCondVar
+ for reporting a bug in cChannel::SetName() in case only the ShortName or Provider
+ has changed
Malcolm Caldwell <malcolm.caldwell@ntu.edu.au>
for modifying LOF handling to allow for C-band reception
diff --git a/HISTORY b/HISTORY
index 67361141..3bbd1c3b 100644
--- a/HISTORY
+++ b/HISTORY
@@ -3116,3 +3116,8 @@ Video Disk Recorder Revision History
- Now displaying the name of the remote control for which the keys are being
learned inside the menu to avoid overwriting the date/time in the 'classic'
skin (thanks to Oliver Endriss for reporting this one).
+
+2004-11-02: Version 1.3.16
+
+- Fixed cChannel::SetName() in case only the ShortName or Provider has changed
+ (thanks to Sascha Volkenandt for reporting this one).
diff --git a/channels.c b/channels.c
index 57986e35..5d500ece 100644
--- a/channels.c
+++ b/channels.c
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: channels.c 1.30 2004/10/31 12:54:06 kls Exp $
+ * $Id: channels.c 1.31 2004/11/02 18:07:05 kls Exp $
*/
#include "channels.h"
@@ -358,15 +358,23 @@ void cChannel::SetId(int Nid, int Tid, int Sid, int Rid)
void cChannel::SetName(const char *Name, const char *ShortName, const char *Provider)
{
- if (!isempty(Name) && strcmp(name, Name) != 0) {
- if (Number()) {
- dsyslog("changing name of channel %d from '%s,%s;%s' to '%s,%s;%s'", Number(), name, shortName, provider, Name, ShortName, Provider);
- modification |= CHANNELMOD_NAME;
- Channels.SetModified();
+ if (!isempty(Name)) {
+ bool nn = strcmp(name, Name) != 0;
+ bool ns = strcmp(shortName, ShortName) != 0;
+ bool np = strcmp(provider, Provider) != 0;
+ if (nn || ns || np) {
+ if (Number()) {
+ dsyslog("changing name of channel %d from '%s,%s;%s' to '%s,%s;%s'", Number(), name, shortName, provider, Name, ShortName, Provider);
+ modification |= CHANNELMOD_NAME;
+ Channels.SetModified();
+ }
+ if (nn)
+ name = strcpyrealloc(name, Name);
+ if (ns)
+ shortName = strcpyrealloc(shortName, ShortName);
+ if (np)
+ provider = strcpyrealloc(provider, Provider);
}
- name = strcpyrealloc(name, Name);
- shortName = strcpyrealloc(shortName, ShortName);
- provider = strcpyrealloc(provider, Provider);
}
}
diff --git a/config.h b/config.h
index bc9052ae..955eb9f8 100644
--- a/config.h
+++ b/config.h
@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
- * $Id: config.h 1.203 2004/10/31 16:17:02 kls Exp $
+ * $Id: config.h 1.204 2004/11/02 17:20:27 kls Exp $
*/
#ifndef __CONFIG_H
@@ -20,8 +20,8 @@
#include "i18n.h"
#include "tools.h"
-#define VDRVERSION "1.3.15"
-#define VDRVERSNUM 10315 // Version * 10000 + Major * 100 + Minor
+#define VDRVERSION "1.3.16"
+#define VDRVERSNUM 10316 // Version * 10000 + Major * 100 + Minor
#define MAXPRIORITY 99
#define MAXLIFETIME 99