mirror of
https://git.openafs.org/openafs.git
synced 2025-01-18 23:10:58 +00:00
Windows: NPCancelConnection set correct length
The RemoteNameLength passed in the IOCTL_AFS_CANCEL_CONNECTION call must not include the trailing NUL. NPGetConnection() returns the size of the buffer used which does include the trailing NUL. Change-Id: Ic5eae51aade91db4a799bea83d898af6fbc37504 Reviewed-on: http://gerrit.openafs.org/5806 Tested-by: BuildBot <buildbot@rampaginggeek.com> Reviewed-by: Jeffrey Altman <jaltman@secure-endpoints.com> Tested-by: Jeffrey Altman <jaltman@secure-endpoints.com>
This commit is contained in:
parent
3acd9b854e
commit
da00d719a7
@ -912,6 +912,11 @@ NPCancelConnection( LPWSTR lpName,
|
||||
#endif
|
||||
try_return( dwStatus = WN_NOT_CONNECTED);
|
||||
}
|
||||
|
||||
//
|
||||
// NPGetConnection returns the buffer size not the length without NUL
|
||||
//
|
||||
dwRemoteNameLength -= sizeof( WCHAR);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user