summaryrefslogtreecommitdiffstats
path: root/libmpdemux/stream.c
diff options
context:
space:
mode:
Diffstat (limited to 'libmpdemux/stream.c')
-rw-r--r--libmpdemux/stream.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/libmpdemux/stream.c b/libmpdemux/stream.c
index 840d70badf..96e8bc1122 100644
--- a/libmpdemux/stream.c
+++ b/libmpdemux/stream.c
@@ -314,6 +314,14 @@ if(newpos==0 || newpos!=s->pos){
// A function call that return -1 can tell that the protocol
// doesn't support seeking.
#ifdef MPLAYER_NETWORK
+ if(s->seek) { // new stream seek is much cleaner than streaming_ctrl one
+ if(!s->seek(s,newpos)) {
+ mp_msg(MSGT_STREAM,MSGL_ERR, "Seek failed\n");
+ return 1;
+ }
+ break;
+ }
+
if( s->streaming_ctrl!=NULL && s->streaming_ctrl->streaming_seek ) {
if( s->streaming_ctrl->streaming_seek( s->fd, pos, s->streaming_ctrl )<0 ) {
mp_msg(MSGT_STREAM,MSGL_INFO,"Stream not seekable!\n");