diff src/recpt1.c @ 170:4f3640bf350d

Change display name of DLNA. - old_display name: (recpt1:devN) - new_display name: (hostname: /dev/ptXdevY) - change UUID format.
author Naoya OYAMA <naoya.oyama@gmail.com>
date Wed, 17 Oct 2012 23:47:16 +0900
parents 061ef2cd98f0
children 89e24a1c8a64
line wrap: on
line diff
--- a/src/recpt1.c	Sun Oct 07 00:37:34 2012 +0900
+++ b/src/recpt1.c	Wed Oct 17 23:47:16 2012 +0900
@@ -47,9 +47,6 @@
 extern struct ushare_t *ut;
 thread_data *gp_tdata;
 
-/* prototypes */
-static int get_device_id_by_name ( const char *name );
-
 static struct channel_info_list *open_list_file(
        char *type,
        struct channel_info_list *info_list)
@@ -168,7 +165,8 @@
 
         sscanf(rbuf.mtext, "ch=%s t=%d e=%d i=%s", channel, &recsec, &time_to_add, sid_list);
 
-        if ((strcmp(channel, "")) && strcmp(tdata->ch, channel)) {
+        if ((strcmp(channel, "")) && strcmp(tdata->ch, channel) ||
+            (strcmp(sid_list, "")) && strcmp(tdata->sid_list, sid_list)) {
 #if 0
             /* re-initialize decoder */
             if(tdata->decoder) {
@@ -1457,16 +1455,3 @@
 
     return 0;
 }
-
-static int
-get_device_id_by_name
-( const char *name )
-{
-    int i = -1;
-    if ( name != NULL ) {
-        if( ! strncmp(name, DEVICE_NAME_BASE, strlen(DEVICE_NAME_BASE) ) ) {
-            i = atoi(name+strlen(DEVICE_NAME_BASE));
-        }
-    }
-    return i;
-}