changeset 24503:5a70ac2aea03

Simplify another two ifs into one
author reimar
date Sat, 15 Sep 2007 11:41:47 +0000
parents 0266e095b2d7
children 75ed76f49c9c
files libmpdemux/demux_ty.c
diffstat 1 files changed, 1 insertions(+), 7 deletions(-) [+]
line wrap: on
line diff
--- a/libmpdemux/demux_ty.c	Sat Sep 15 11:35:35 2007 +0000
+++ b/libmpdemux/demux_ty.c	Sat Sep 15 11:41:47 2007 +0000
@@ -197,13 +197,7 @@
 
    fileoffset = tmf_filetooffset(tivo, readChunk);
 
-   if (fileoffset == -1) {
-      mp_msg(MSGT_DEMUX, MSGL_ERR, "Read past EOF()\n");
-      return 0;
-   }
-
-   if ( stream_seek( demux->stream, fileoffset ) != 1 )
-   {
+   if (fileoffset == -1 || !stream_seek(demux->stream, fileoffset)) {
       mp_msg( MSGT_DEMUX, MSGL_ERR, "Read past EOF()\n" );
       return 0;
    }