AFSDeleteDirEntry( pObjectInfo->ParentObjectInformation,
pDirCB);
- if( pObjectInfo->ObjectReferenceCount == 0)
+ AFSAcquireShared( &pObjectInfo->NonPagedInfo->ObjectInfoLock,
+ TRUE);
+
+ if( pObjectInfo->ObjectReferenceCount <= 0)
{
if( BooleanFlagOn( pObjectInfo->Flags, AFS_OBJECT_INSERTED_HASH_TREE))
ClearFlag( pObjectInfo->Flags, AFS_OBJECT_INSERTED_HASH_TREE);
}
-
- SetFlag( pObjectInfo->Flags, AFS_OBJECT_FLAGS_DELETED);
}
+
+ AFSReleaseResource( &pObjectInfo->NonPagedInfo->ObjectInfoLock);
}
AFSReleaseResource( pObjectInfo->ParentObjectInformation->Specific.Directory.DirectoryNodeHdr.TreeLock);
// Tear 'em down, we'll not be needing them again
//
- if( AFSTearDownFcbExtents( pFcb,
- &pCcb->AuthGroup))
- {
-
- //
- // Indicate to the service that the file required complete flushing to the
- // server.
- //
-
- AFSProcessRequest( AFS_REQUEST_TYPE_FLUSH_FILE,
- AFS_REQUEST_FLAG_SYNCHRONOUS,
- &pCcb->AuthGroup,
- NULL,
- &pFcb->ObjectInformation->FileId,
- NULL,
- 0,
- NULL,
- NULL);
- }
+ AFSTearDownFcbExtents( pFcb,
+ &pCcb->AuthGroup);
}
else
{
AFSCompleteRequest( Irp,
ntStatus);
}
- __except( AFSExceptionFilter( GetExceptionCode(), GetExceptionInformation()) )
+ __except( AFSExceptionFilter( __FUNCTION__, GetExceptionCode(), GetExceptionInformation()) )
{
AFSDbgLogMsg( 0,
0,
"EXCEPTION - AFSClose\n");
+
+ AFSDumpTraceFilesFnc();
}
return ntStatus;