mirror of
https://github.com/winfsp/winfsp.git
synced 2025-04-23 17:03:12 -05:00
tst: winfsp-tests: stream testing
This commit is contained in:
parent
8ffb359f20
commit
fa6b621042
@ -599,7 +599,6 @@ static void stream_getsecurity_dotest(ULONG Flags, PWSTR Prefix, ULONG FileInfoT
|
|||||||
{
|
{
|
||||||
void *memfs = memfs_start_ex(Flags, FileInfoTimeout);
|
void *memfs = memfs_start_ex(Flags, FileInfoTimeout);
|
||||||
|
|
||||||
#if 0
|
|
||||||
static PWSTR Sddl = L"D:P(A;;GA;;;SY)(A;;GA;;;BA)(A;;GA;;;WD)";
|
static PWSTR Sddl = L"D:P(A;;GA;;;SY)(A;;GA;;;BA)(A;;GA;;;WD)";
|
||||||
PSECURITY_DESCRIPTOR SecurityDescriptor, FileSecurityDescriptor;
|
PSECURITY_DESCRIPTOR SecurityDescriptor, FileSecurityDescriptor;
|
||||||
SECURITY_ATTRIBUTES SecurityAttributes = { 0 };
|
SECURITY_ATTRIBUTES SecurityAttributes = { 0 };
|
||||||
@ -617,7 +616,7 @@ static void stream_getsecurity_dotest(ULONG Flags, PWSTR Prefix, ULONG FileInfoT
|
|||||||
SecurityAttributes.nLength = sizeof SecurityAttributes;
|
SecurityAttributes.nLength = sizeof SecurityAttributes;
|
||||||
SecurityAttributes.lpSecurityDescriptor = SecurityDescriptor;
|
SecurityAttributes.lpSecurityDescriptor = SecurityDescriptor;
|
||||||
|
|
||||||
StringCbPrintfW(FilePath, sizeof FilePath, L"%s%s\\file0",
|
StringCbPrintfW(FilePath, sizeof FilePath, L"%s%s\\file0:foo",
|
||||||
Prefix ? L"" : L"\\\\?\\GLOBALROOT", Prefix ? Prefix : memfs_volumename(memfs));
|
Prefix ? L"" : L"\\\\?\\GLOBALROOT", Prefix ? Prefix : memfs_volumename(memfs));
|
||||||
|
|
||||||
Handle = CreateFileW(FilePath,
|
Handle = CreateFileW(FilePath,
|
||||||
@ -626,6 +625,9 @@ static void stream_getsecurity_dotest(ULONG Flags, PWSTR Prefix, ULONG FileInfoT
|
|||||||
ASSERT(INVALID_HANDLE_VALUE != Handle);
|
ASSERT(INVALID_HANDLE_VALUE != Handle);
|
||||||
CloseHandle(Handle);
|
CloseHandle(Handle);
|
||||||
|
|
||||||
|
StringCbPrintfW(FilePath, sizeof FilePath, L"%s%s\\file0",
|
||||||
|
Prefix ? L"" : L"\\\\?\\GLOBALROOT", Prefix ? Prefix : memfs_volumename(memfs));
|
||||||
|
|
||||||
Handle = CreateFileW(FilePath,
|
Handle = CreateFileW(FilePath,
|
||||||
GENERIC_READ | GENERIC_WRITE, FILE_SHARE_READ | FILE_SHARE_WRITE, 0, OPEN_EXISTING, FILE_FLAG_DELETE_ON_CLOSE, 0);
|
GENERIC_READ | GENERIC_WRITE, FILE_SHARE_READ | FILE_SHARE_WRITE, 0, OPEN_EXISTING, FILE_FLAG_DELETE_ON_CLOSE, 0);
|
||||||
ASSERT(INVALID_HANDLE_VALUE != Handle);
|
ASSERT(INVALID_HANDLE_VALUE != Handle);
|
||||||
@ -678,7 +680,6 @@ static void stream_getsecurity_dotest(ULONG Flags, PWSTR Prefix, ULONG FileInfoT
|
|||||||
CloseHandle(Handle);
|
CloseHandle(Handle);
|
||||||
|
|
||||||
LocalFree(SecurityDescriptor);
|
LocalFree(SecurityDescriptor);
|
||||||
#endif
|
|
||||||
|
|
||||||
memfs_stop(memfs);
|
memfs_stop(memfs);
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user