mirror of
https://github.com/hierynomus/sshj.git
synced 2025-12-06 15:20:54 +03:00
Fix issue 209.
This commit is contained in:
@@ -194,7 +194,10 @@ public class RemoteFile
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public long skip(long n) throws IOException {
|
public long skip(long n) throws IOException {
|
||||||
return (this.fileOffset = Math.min(fileOffset + n, length()));
|
final long fileLength = length();
|
||||||
|
final Long previousFileOffset = fileOffset;
|
||||||
|
fileOffset = Math.min(fileOffset + n, fileLength);
|
||||||
|
return fileOffset - previousFileOffset;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
Reference in New Issue
Block a user