diff options
author | Bastien Nocera <hadess@users.sourceforge.net> | 2007-01-23 23:20:23 +0000 |
---|---|---|
committer | Bastien Nocera <hadess@users.sourceforge.net> | 2007-01-23 23:20:23 +0000 |
commit | 01ef002ace693476f29d0cd7ffff816c90570137 (patch) | |
tree | 5c147073f22d0a859135ce9c10e0439e5ce02b48 | |
parent | b96aa212a0661cd1daf2cef5c1e3bfa5fa0432da (diff) | |
download | xine-lib-01ef002ace693476f29d0cd7ffff816c90570137.tar.gz xine-lib-01ef002ace693476f29d0cd7ffff816c90570137.tar.bz2 |
- Don't try to print "<title> / <chapter>" if there's no title, avoid
things like "(null) / Chapter 1" when the title isn't available (and
a possible crasher on non-Linux platforms)
CVS patchset: 8547
CVS date: 2007/01/23 23:20:23
-rw-r--r-- | src/demuxers/demux_ogg.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/demuxers/demux_ogg.c b/src/demuxers/demux_ogg.c index a042bc7ec..218728e1b 100644 --- a/src/demuxers/demux_ogg.c +++ b/src/demuxers/demux_ogg.c @@ -19,7 +19,7 @@ */ /* - * $Id: demux_ogg.c,v 1.173 2007/01/22 17:33:35 klan Exp $ + * $Id: demux_ogg.c,v 1.174 2007/01/23 23:20:23 hadess Exp $ * * demultiplexer for ogg streams * @@ -536,7 +536,11 @@ static void update_chapter_display (demux_ogg_t *this, int stream_num, ogg_packe if (chapter >= 0) { char t_title[256]; - snprintf(t_title, sizeof (t_title), "%s / %s", this->title, this->chapter_info->entries[chapter].name); + if (this->title) { + snprintf(t_title, sizeof (t_title), "%s / %s", this->title, this->chapter_info->entries[chapter].name); + } else { + snprintf(t_title, sizeof (t_title), "%s", this->chapter_info->entries[chapter].name); + } title = t_title; } else { title = this->title; |