Skip to content

Commit 90f3086

Browse files
committed
Fix warning.
1 parent 0da2c06 commit 90f3086

File tree

1 file changed

+2
-4
lines changed

1 file changed

+2
-4
lines changed

Renci.SshClient/Renci.SshNet/Sftp/SftpFileStream.cs

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@ public class SftpFileStream : Stream
1414
// TODO: Add security method to set userid, groupid and other permission settings
1515
// Internal state.
1616
private byte[] _handle;
17-
private readonly FileAccess _access;
1817
private readonly bool _ownsHandle;
1918
private readonly bool _isAsync;
2019
private ISftpSession _session;
@@ -211,15 +210,14 @@ internal SftpFileStream(ISftpSession session, string path, FileMode mode, FileAc
211210

212211
// Initialize the object state.
213212
_session = session;
214-
_access = access;
215213
_ownsHandle = true;
216214
_isAsync = useAsync;
217215
_bufferPosition = 0;
218216
_bufferLen = 0;
219217
_bufferOwnedByWrite = false;
220-
_canRead = ((_access & FileAccess.Read) != 0);
218+
_canRead = ((access & FileAccess.Read) != 0);
221219
_canSeek = true;
222-
_canWrite = ((_access & FileAccess.Write) != 0);
220+
_canWrite = ((access & FileAccess.Write) != 0);
223221
_position = 0;
224222
_serverFilePosition = 0;
225223

0 commit comments

Comments
 (0)