Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-cw
Commits
850ee4ba
Commit
850ee4ba
authored
Feb 12, 2004
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Authors: David Hammerton <david@transgaming.com>, Mike McCormack <mike@codeweavers.com>
Completed PeekNamedPipe implementation.
parent
e8fedffa
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
22 additions
and
6 deletions
+22
-6
sync.c
dlls/kernel/sync.c
+22
-6
No files found.
dlls/kernel/sync.c
View file @
850ee4ba
...
...
@@ -32,6 +32,9 @@
#ifdef HAVE_SYS_POLL_H
#include <sys/poll.h>
#endif
#ifdef HAVE_SYS_SOCKET_H
#include <sys/socket.h>
#endif
#include <stdarg.h>
#include <stdio.h>
...
...
@@ -1117,13 +1120,26 @@ BOOL WINAPI PeekNamedPipe( HANDLE hPipe, LPVOID lpvBuffer, DWORD cbBuffer,
return
FALSE
;
}
}
wine_server_release_fd
(
hPipe
,
fd
);
TRACE
(
" 0x%08x bytes available
\n
"
,
avail
);
if
(
!
lpvBuffer
&&
lpcbAvail
)
{
*
lpcbAvail
=
avail
;
return
TRUE
;
}
ret
=
TRUE
;
if
(
lpcbAvail
)
*
lpcbAvail
=
avail
;
if
(
lpcbRead
)
*
lpcbRead
=
0
;
if
(
avail
&&
lpvBuffer
)
{
int
readbytes
=
(
avail
<
cbBuffer
)
?
avail
:
cbBuffer
;
readbytes
=
recv
(
fd
,
lpvBuffer
,
readbytes
,
MSG_PEEK
);
if
(
readbytes
<
0
)
{
WARN
(
"failed to peek socket (%d)
\n
"
,
errno
);
ret
=
FALSE
;
}
else
if
(
lpcbRead
)
*
lpcbRead
=
readbytes
;
}
wine_server_release_fd
(
hPipe
,
fd
);
return
ret
;
#endif
/* defined(FIONREAD) */
SetLastError
(
ERROR_CALL_NOT_IMPLEMENTED
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment