Commit 9ffce009 authored by Uwe Bonnes's avatar Uwe Bonnes Committed by Alexandre Julliard

Pass inherit handle flag properly for CreateNamedPipe.

parent 0053b8b2
......@@ -1062,6 +1062,7 @@ HANDLE WINAPI CreateNamedPipeW( LPCWSTR name, DWORD dwOpenMode,
req->outsize = nOutBufferSize;
req->insize = nInBufferSize;
req->timeout = nDefaultTimeOut;
req->inherit = (attr && (attr->nLength>=sizeof(*attr)) && attr->bInheritHandle);
wine_server_add_data( req, name, len * sizeof(WCHAR) );
SetLastError(0);
if (!wine_server_call_err( req )) ret = reply->handle;
......
......@@ -2414,6 +2414,7 @@ struct create_named_pipe_request
unsigned int outsize;
unsigned int insize;
unsigned int timeout;
int inherit;
/* VARARG(name,unicode_str); */
};
struct create_named_pipe_reply
......@@ -3762,6 +3763,6 @@ union generic_reply
struct set_global_windows_reply set_global_windows_reply;
};
#define SERVER_PROTOCOL_VERSION 131
#define SERVER_PROTOCOL_VERSION 132
#endif /* __WINE_WINE_SERVER_PROTOCOL_H */
......@@ -629,7 +629,7 @@ DECL_HANDLER(create_named_pipe)
{
server->state = ps_idle_server;
reply->handle = alloc_handle( current->process, server,
GENERIC_READ|GENERIC_WRITE, 0 );
GENERIC_READ|GENERIC_WRITE, req->inherit );
server->pipe->instances++;
release_object( server );
}
......
......@@ -1705,6 +1705,7 @@ enum message_type
unsigned int outsize;
unsigned int insize;
unsigned int timeout;
int inherit; /* inherit flag */
VARARG(name,unicode_str); /* pipe name */
@REPLY
obj_handle_t handle; /* handle to the pipe */
......
......@@ -2005,6 +2005,7 @@ static void dump_create_named_pipe_request( const struct create_named_pipe_reque
fprintf( stderr, " outsize=%08x,", req->outsize );
fprintf( stderr, " insize=%08x,", req->insize );
fprintf( stderr, " timeout=%08x,", req->timeout );
fprintf( stderr, " inherit=%d,", req->inherit );
fprintf( stderr, " name=" );
dump_varargs_unicode_str( cur_size );
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment