mirror of
https://git.openafs.org/openafs.git
synced 2025-01-19 07:20:11 +00:00
Windows: AFSRDFSProvider NPOpenEnum vs no redirector
If there is no redirector device present, return WN_NO_NETWORK to indicate that this network provider is not ready for browsing. Change-Id: I3e33769bb2d52a59b0ff993aa07e89d959d60800 Reviewed-on: http://gerrit.openafs.org/10523 Tested-by: BuildBot <buildbot@rampaginggeek.com> Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
This commit is contained in:
parent
45f7528af7
commit
1e24762a2c
@ -2246,6 +2246,7 @@ NPOpenEnum( DWORD dwScope,
|
||||
|
||||
DWORD dwStatus = WN_SUCCESS;
|
||||
AFSEnumerationCB *pEnumCB = NULL;
|
||||
HANDLE hControlDevice = NULL;
|
||||
|
||||
#ifdef AFS_DEBUG_TRACE
|
||||
if ( lpNetResource == NULL)
|
||||
@ -2282,6 +2283,21 @@ NPOpenEnum( DWORD dwScope,
|
||||
}
|
||||
#endif
|
||||
|
||||
hControlDevice = OpenRedirector();
|
||||
|
||||
if( hControlDevice == NULL)
|
||||
{
|
||||
|
||||
#ifdef AFS_DEBUG_TRACE
|
||||
AFSDbgPrint( L"NPOpenEnum OpenRedirector failure, returning WN_NET_ERROR\n");
|
||||
#endif
|
||||
|
||||
return WN_NO_NETWORK;
|
||||
}
|
||||
|
||||
CloseHandle( hControlDevice);
|
||||
|
||||
|
||||
*lphEnum = HeapAlloc( GetProcessHeap( ), HEAP_ZERO_MEMORY, sizeof( AFSEnumerationCB));
|
||||
|
||||
if( *lphEnum == NULL)
|
||||
|
Loading…
Reference in New Issue
Block a user