CreateNamedPipeW(): Set access rights according to the given open mode.
Modified: trunk/reactos/lib/kernel32/file/npipe.c
_____
Modified: trunk/reactos/lib/kernel32/file/npipe.c
--- trunk/reactos/lib/kernel32/file/npipe.c 2005-01-27 14:11:19 UTC
(rev 13337)
+++ trunk/reactos/lib/kernel32/file/npipe.c 2005-01-27 15:28:08 UTC
(rev 13338)
@@ -123,14 +123,17 @@
if (dwOpenMode & PIPE_ACCESS_DUPLEX)
{
CreateOptions = CreateOptions | FILE_PIPE_FULL_DUPLEX;
+ DesiredAccess |= (FILE_GENERIC_READ | FILE_GENERIC_WRITE);
}
else if (dwOpenMode & PIPE_ACCESS_INBOUND)
{
CreateOptions = CreateOptions | FILE_PIPE_INBOUND;
+ DesiredAccess |= FILE_GENERIC_READ;
}
else if (dwOpenMode & PIPE_ACCESS_OUTBOUND)
{
CreateOptions = CreateOptions | FILE_PIPE_OUTBOUND;
+ DesiredAccess |= FILE_GENERIC_WRITE;
}
if (dwPipeMode & PIPE_TYPE_BYTE)