mirror of
https://github.com/TalAloni/SMBLibrary.git
synced 2025-07-19 15:45:54 +02:00
Fixed InvalidCastException during SMB 2.002 connection
This commit is contained in:
parent
3539d3bd31
commit
1679629b47
2 changed files with 10 additions and 2 deletions
|
@ -47,8 +47,12 @@ namespace SMBLibrary.Server
|
|||
if (command is NegotiateRequest)
|
||||
{
|
||||
NegotiateRequest request = (NegotiateRequest)command;
|
||||
state = new SMB2ConnectionState(state, AllocatePersistentFileID);
|
||||
return NegotiateHelper.GetNegotiateResponse(request, state, m_serverGuid);
|
||||
SMB2Command response = NegotiateHelper.GetNegotiateResponse(request, state, m_serverGuid);
|
||||
if (state.ServerDialect != SMBDialect.NotSet)
|
||||
{
|
||||
state = new SMB2ConnectionState(state, AllocatePersistentFileID);
|
||||
}
|
||||
return response;
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue