Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
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-winehq
Commits
c18e8d6a
Commit
c18e8d6a
authored
Apr 18, 2007
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
server: Use the standard file descriptor wait queue for named pipe server async waits.
parent
6105a93b
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
8 deletions
+4
-8
fd.c
server/fd.c
+2
-2
named_pipe.c
server/named_pipe.c
+2
-6
No files found.
server/fd.c
View file @
c18e8d6a
...
@@ -1738,12 +1738,12 @@ struct async *fd_queue_async( struct fd *fd, const async_data_t *data, int type,
...
@@ -1738,12 +1738,12 @@ struct async *fd_queue_async( struct fd *fd, const async_data_t *data, int type,
assert
(
0
);
assert
(
0
);
}
}
if
((
async
=
create_async
(
current
,
queue
,
data
)))
if
((
async
=
create_async
(
current
,
queue
,
data
))
&&
type
!=
ASYNC_TYPE_WAIT
)
{
{
if
(
!
fd
->
inode
)
if
(
!
fd
->
inode
)
set_fd_events
(
fd
,
fd
->
fd_ops
->
get_poll_events
(
fd
)
);
set_fd_events
(
fd
,
fd
->
fd_ops
->
get_poll_events
(
fd
)
);
else
/* regular files are always ready for read and write */
else
/* regular files are always ready for read and write */
if
(
type
!=
ASYNC_TYPE_WAIT
)
async_wake_up
(
queue
,
STATUS_ALERTED
);
async_wake_up
(
queue
,
STATUS_ALERTED
);
}
}
return
async
;
return
async
;
}
}
...
...
server/named_pipe.c
View file @
c18e8d6a
...
@@ -76,7 +76,6 @@ struct pipe_server
...
@@ -76,7 +76,6 @@ struct pipe_server
struct
named_pipe
*
pipe
;
struct
named_pipe
*
pipe
;
struct
timeout_user
*
flush_poll
;
struct
timeout_user
*
flush_poll
;
struct
event
*
event
;
struct
event
*
event
;
struct
async_queue
*
wait_q
;
/* only a single one can be queued */
unsigned
int
options
;
/* pipe options */
unsigned
int
options
;
/* pipe options */
};
};
...
@@ -385,8 +384,6 @@ static void pipe_server_destroy( struct object *obj)
...
@@ -385,8 +384,6 @@ static void pipe_server_destroy( struct object *obj)
server
->
client
=
NULL
;
server
->
client
=
NULL
;
}
}
free_async_queue
(
server
->
wait_q
);
assert
(
server
->
pipe
->
instances
);
assert
(
server
->
pipe
->
instances
);
server
->
pipe
->
instances
--
;
server
->
pipe
->
instances
--
;
...
@@ -587,7 +584,7 @@ static void pipe_server_ioctl( struct fd *fd, ioctl_code_t code, const async_dat
...
@@ -587,7 +584,7 @@ static void pipe_server_ioctl( struct fd *fd, ioctl_code_t code, const async_dat
case
ps_idle_server
:
case
ps_idle_server
:
case
ps_wait_connect
:
case
ps_wait_connect
:
set_server_state
(
server
,
ps_wait_open
);
set_server_state
(
server
,
ps_wait_open
);
if
((
async
=
create_async
(
current
,
server
->
wait_q
,
async_data
)))
if
((
async
=
fd_queue_async
(
server
->
ioctl_fd
,
async_data
,
ASYNC_TYPE_WAIT
,
0
)))
{
{
if
(
server
->
pipe
->
waiters
)
async_wake_up
(
server
->
pipe
->
waiters
,
STATUS_SUCCESS
);
if
(
server
->
pipe
->
waiters
)
async_wake_up
(
server
->
pipe
->
waiters
,
STATUS_SUCCESS
);
release_object
(
async
);
release_object
(
async
);
...
@@ -709,7 +706,6 @@ static struct pipe_server *create_pipe_server( struct named_pipe *pipe, unsigned
...
@@ -709,7 +706,6 @@ static struct pipe_server *create_pipe_server( struct named_pipe *pipe, unsigned
server
->
client
=
NULL
;
server
->
client
=
NULL
;
server
->
flush_poll
=
NULL
;
server
->
flush_poll
=
NULL
;
server
->
options
=
options
;
server
->
options
=
options
;
server
->
wait_q
=
create_async_queue
(
NULL
);
list_add_head
(
&
pipe
->
servers
,
&
server
->
entry
);
list_add_head
(
&
pipe
->
servers
,
&
server
->
entry
);
grab_object
(
pipe
);
grab_object
(
pipe
);
...
@@ -791,7 +787,7 @@ static struct object *named_pipe_open_file( struct object *obj, unsigned int acc
...
@@ -791,7 +787,7 @@ static struct object *named_pipe_open_file( struct object *obj, unsigned int acc
if
(
client
->
fd
&&
server
->
fd
)
if
(
client
->
fd
&&
server
->
fd
)
{
{
if
(
server
->
state
==
ps_wait_open
)
if
(
server
->
state
==
ps_wait_open
)
async_wake_up
(
server
->
wait_q
,
STATUS_SUCCESS
);
fd_async_wake_up
(
server
->
ioctl_fd
,
ASYNC_TYPE_WAIT
,
STATUS_SUCCESS
);
set_server_state
(
server
,
ps_connected_server
);
set_server_state
(
server
,
ps_connected_server
);
server
->
client
=
client
;
server
->
client
=
client
;
client
->
server
=
server
;
client
->
server
=
server
;
...
...
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