server: Use attributes instead of inherit flag in dup_handle request.

This commit is contained in:
Alexandre Julliard 2005-12-09 12:21:35 +01:00
parent 836d07c369
commit 7b910f40f2
5 changed files with 10 additions and 10 deletions

View File

@ -306,7 +306,7 @@ NTSTATUS WINAPI NtDuplicateObject( HANDLE source_process, HANDLE source,
req->src_handle = source;
req->dst_process = dest_process;
req->access = access;
req->inherit = (attributes & OBJ_INHERIT) != 0;
req->attributes = attributes;
req->options = options;
if (!(ret = wine_server_call( req )))

View File

@ -547,8 +547,8 @@ struct dup_handle_request
obj_handle_t src_handle;
obj_handle_t dst_process;
unsigned int access;
int inherit;
int options;
unsigned int attributes;
unsigned int options;
};
struct dup_handle_reply
{
@ -4321,6 +4321,6 @@ union generic_reply
struct query_symlink_reply query_symlink_reply;
};
#define SERVER_PROTOCOL_VERSION 213
#define SERVER_PROTOCOL_VERSION 214
#endif /* __WINE_WINE_SERVER_PROTOCOL_H */

View File

@ -573,12 +573,12 @@ DECL_HANDLER(dup_handle)
if (req->options & DUP_HANDLE_MAKE_GLOBAL)
{
reply->handle = duplicate_handle( src, req->src_handle, NULL,
req->access, req->inherit, req->options );
req->access, req->attributes & OBJ_INHERIT, req->options );
}
else if ((dst = get_process_from_handle( req->dst_process, PROCESS_DUP_HANDLE )))
{
reply->handle = duplicate_handle( src, req->src_handle, dst,
req->access, req->inherit, req->options );
req->access, req->attributes & OBJ_INHERIT, req->options );
release_object( dst );
}
/* close the handle no matter what happened */

View File

@ -450,8 +450,8 @@ enum apc_type { APC_NONE, APC_USER, APC_TIMER, APC_ASYNC_IO };
obj_handle_t src_handle; /* src handle to duplicate */
obj_handle_t dst_process; /* dst process handle */
unsigned int access; /* wanted access rights */
int inherit; /* inherit flag */
int options; /* duplicate options (see below) */
unsigned int attributes; /* object attributes */
unsigned int options; /* duplicate options (see below) */
@REPLY
obj_handle_t handle; /* duplicated handle in dst process */
int fd; /* associated fd to close */

View File

@ -846,8 +846,8 @@ static void dump_dup_handle_request( const struct dup_handle_request *req )
fprintf( stderr, " src_handle=%p,", req->src_handle );
fprintf( stderr, " dst_process=%p,", req->dst_process );
fprintf( stderr, " access=%08x,", req->access );
fprintf( stderr, " inherit=%d,", req->inherit );
fprintf( stderr, " options=%d", req->options );
fprintf( stderr, " attributes=%08x,", req->attributes );
fprintf( stderr, " options=%08x", req->options );
}
static void dump_dup_handle_reply( const struct dup_handle_reply *req )