summaryrefslogtreecommitdiff
path: root/channels.c
diff options
context:
space:
mode:
authorKlaus Schmidinger <vdr@tvdr.de>2013-10-11 11:38:05 +0200
committerKlaus Schmidinger <vdr@tvdr.de>2013-10-11 11:38:05 +0200
commit1caa78a3e7456a2be71526fb0db151f3e3519dc9 (patch)
tree852fb107ca54be29c169dd2c6a32d364188dfdf9 /channels.c
parente61e1ed4252054ce31e4dad525ecbb579422eb4b (diff)
downloadvdr-1caa78a3e7456a2be71526fb0db151f3e3519dc9.tar.gz
vdr-1caa78a3e7456a2be71526fb0db151f3e3519dc9.tar.bz2
Fixed writing group separators to channels.conf that contain a comma
Diffstat (limited to 'channels.c')
-rw-r--r--channels.c16
1 files changed, 9 insertions, 7 deletions
diff --git a/channels.c b/channels.c
index 05f8cdb1..7cb7e883 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 2.24 2012/07/14 12:15:00 kls Exp $
+ * $Id: channels.c 3.1 2013/10/11 11:03:26 kls Exp $
*/
#include "channels.h"
@@ -503,12 +503,14 @@ cString cChannel::ToText(const cChannel *Channel)
char FullName[strlen(Channel->name) + 1 + strlen(Channel->shortName) + 1 + strlen(Channel->provider) + 1 + 10]; // +10: paranoia
char *q = FullName;
q += sprintf(q, "%s", Channel->name);
- if (!isempty(Channel->shortName))
- q += sprintf(q, ",%s", Channel->shortName);
- else if (strchr(Channel->name, ','))
- q += sprintf(q, ",");
- if (!isempty(Channel->provider))
- q += sprintf(q, ";%s", Channel->provider);
+ if (!Channel->groupSep) {
+ if (!isempty(Channel->shortName))
+ q += sprintf(q, ",%s", Channel->shortName);
+ else if (strchr(Channel->name, ','))
+ q += sprintf(q, ",");
+ if (!isempty(Channel->provider))
+ q += sprintf(q, ";%s", Channel->provider);
+ }
*q = 0;
strreplace(FullName, ':', '|');
cString buffer;