server: Use attributes instead of inherit flag in file requests.
diff --git a/server/file.c b/server/file.c
index 4d13ca7..1b34c7a 100644
--- a/server/file.c
+++ b/server/file.c
@@ -356,7 +356,8 @@
if ((file = create_file( get_req_data(), get_req_data_size(), req->access,
req->sharing, req->create, req->options, req->attrs )))
{
- reply->handle = alloc_handle( current->process, file, req->access, req->inherit );
+ reply->handle = alloc_handle( current->process, file, req->access,
+ req->attributes & OBJ_INHERIT );
release_object( file );
}
}
@@ -375,7 +376,8 @@
}
if ((file = create_file_for_fd( fd, req->access, FILE_SHARE_READ | FILE_SHARE_WRITE )))
{
- reply->handle = alloc_handle( current->process, file, req->access, req->inherit );
+ reply->handle = alloc_handle( current->process, file, req->access,
+ req->attributes & OBJ_INHERIT );
release_object( file );
}
}
diff --git a/server/protocol.def b/server/protocol.def
index bbb842e..98bcb90 100644
--- a/server/protocol.def
+++ b/server/protocol.def
@@ -590,7 +590,7 @@
/* Create a file */
@REQ(create_file)
unsigned int access; /* wanted access rights */
- int inherit; /* inherit flag */
+ unsigned int attributes; /* object attributes */
unsigned int sharing; /* sharing flags */
int create; /* file create action */
unsigned int options; /* file options */
@@ -604,7 +604,7 @@
/* Allocate a file handle for a Unix fd */
@REQ(alloc_file_handle)
unsigned int access; /* wanted access rights */
- int inherit; /* inherit flag */
+ unsigned int attributes; /* object attributes */
int fd; /* file descriptor on the client side */
@REPLY
obj_handle_t handle; /* handle to the file */
diff --git a/server/trace.c b/server/trace.c
index eeb4e76..6ede1c2 100644
--- a/server/trace.c
+++ b/server/trace.c
@@ -1008,7 +1008,7 @@
static void dump_create_file_request( const struct create_file_request *req )
{
fprintf( stderr, " access=%08x,", req->access );
- fprintf( stderr, " inherit=%d,", req->inherit );
+ fprintf( stderr, " attributes=%08x,", req->attributes );
fprintf( stderr, " sharing=%08x,", req->sharing );
fprintf( stderr, " create=%d,", req->create );
fprintf( stderr, " options=%08x,", req->options );
@@ -1025,7 +1025,7 @@
static void dump_alloc_file_handle_request( const struct alloc_file_handle_request *req )
{
fprintf( stderr, " access=%08x,", req->access );
- fprintf( stderr, " inherit=%d,", req->inherit );
+ fprintf( stderr, " attributes=%08x,", req->attributes );
fprintf( stderr, " fd=%d", req->fd );
}