summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorphintuka <phintuka>2007-03-14 14:21:11 +0000
committerphintuka <phintuka>2007-03-14 14:21:11 +0000
commit007c8ab55c3ca1e2f5a97fe17e091d4b9627bd4c (patch)
tree64580d903212f73bb2354e572a2592f8fefdb259
parentae7a3aed6374be736946f199df76181ada7e3a4f (diff)
downloadxineliboutput-007c8ab55c3ca1e2f5a97fe17e091d4b9627bd4c.tar.gz
xineliboutput-007c8ab55c3ca1e2f5a97fe17e091d4b9627bd4c.tar.bz2
Fix SPUMAP handling when there are no subtitles
-rw-r--r--frontend.c18
1 files changed, 10 insertions, 8 deletions
diff --git a/frontend.c b/frontend.c
index d56da1ba..514318c2 100644
--- a/frontend.c
+++ b/frontend.c
@@ -4,7 +4,7 @@
* See the main source file 'xineliboutput.c' for copyright information and
* how to reach the author.
*
- * $Id: frontend.c,v 1.32 2007-03-14 11:30:34 phintuka Exp $
+ * $Id: frontend.c,v 1.33 2007-03-14 14:21:11 phintuka Exp $
*
*/
@@ -103,13 +103,15 @@ void cXinelibThread::InfoHandler(const char *info)
Current = true;
map++;
}
- int id = atoi(map);
- while(*map && *map != ':') map++;
- if(*map == ':') map++;
- char *lang = map;
- while(*map && *map != ' ') map++;
- if(*map == ' ') { *map = 0; map++; };
- cXinelibDevice::Instance().SetAvailableDvdSpuTrack(id, *lang ? lang : NULL, Current);
+ if(*map >= '0' && *map <= '9') {
+ int id = atoi(map);
+ while(*map && *map != ':') map++;
+ if(*map == ':') map++;
+ char *lang = map;
+ while(*map && *map != ' ') map++;
+ if(*map == ' ') { *map = 0; map++; };
+ cXinelibDevice::Instance().SetAvailableDvdSpuTrack(id, *lang ? lang : NULL, Current);
+ }
}
}