[FFmpeg-cvslog] lavf/libssh: fix seek with whence==SEEK_CUR

Lukasz Marek git at videolan.org
Wed Jan 22 02:02:14 CET 2014


ffmpeg | branch: release/2.1 | Lukasz Marek <lukasz.m.luki at gmail.com> | Tue Jan 21 01:18:15 2014 +0100| [c5a2a65e1e923f0bcb39625ac121c5eb643cf93f] | committer: Michael Niedermayer

lavf/libssh: fix seek with whence==SEEK_CUR

Signed-off-by: Lukasz Marek <lukasz.m.luki at gmail.com>
(cherry picked from commit e0d124a9209f44a34e812fb26ba581552b55a731)

Conflicts:

	libavformat/libssh.c

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=c5a2a65e1e923f0bcb39625ac121c5eb643cf93f
---

 libavformat/libssh.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/libavformat/libssh.c b/libavformat/libssh.c
index 4a9b867..5d5b91f 100644
--- a/libavformat/libssh.c
+++ b/libavformat/libssh.c
@@ -159,7 +159,7 @@ static int64_t libssh_seek(URLContext *h, int64_t pos, int whence)
         newpos = pos;
         break;
     case SEEK_CUR:
-        newpos = sftp_tell64(s->file);
+        newpos = sftp_tell64(s->file) + pos;
         break;
     case SEEK_END:
         newpos = s->filesize + pos;



More information about the ffmpeg-cvslog mailing list