summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorErik Hovland <erik@hovland.org>2008-04-14 21:17:45 +0100
committerErik Hovland <erik@hovland.org>2008-04-14 21:17:45 +0100
commit1dde93f3dfd535813c291ff22ea678f47a455590 (patch)
tree6ffd4a66894dd5f699f61d0e66f2019a60e9894a /src
parent6705bdb0329e766bf5bd0bdc881b7b233c24d008 (diff)
downloadxine-lib-1dde93f3dfd535813c291ff22ea678f47a455590.tar.gz
xine-lib-1dde93f3dfd535813c291ff22ea678f47a455590.tar.bz2
strchr can return null. It should be checked.
Diffstat (limited to 'src')
-rw-r--r--src/libsputext/demux_sputext.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/libsputext/demux_sputext.c b/src/libsputext/demux_sputext.c
index 081a34449..ee7f6122e 100644
--- a/src/libsputext/demux_sputext.c
+++ b/src/libsputext/demux_sputext.c
@@ -544,6 +544,8 @@ static subtitle_t *sub_read_line_ssa(demux_sputext_t *this,subtitle_t *current)
line3) < 9 );
line2=strchr(line3, ',');
+ if (!line2)
+ return NULL;
for (comma = 4; comma < max_comma; comma ++)
{