2 * Server-side handle definitions
4 * Copyright (C) 1999 Alexandre Julliard
7 #ifndef __WINE_SERVER_HANDLE_H
8 #define __WINE_SERVER_HANDLE_H
12 #include "wine/server_protocol.h"
17 /* handle functions */
19 /* alloc_handle takes a void *obj for convenience, but you better make sure */
20 /* that the thing pointed to starts with a struct object... */
21 extern handle_t
alloc_handle( struct process
*process
, void *obj
,
22 unsigned int access
, int inherit
);
23 extern int close_handle( struct process
*process
, handle_t handle
, int *fd
);
24 extern struct object
*get_handle_obj( struct process
*process
, handle_t handle
,
25 unsigned int access
, const struct object_ops
*ops
);
26 extern int get_handle_fd( struct process
*process
, handle_t handle
, unsigned int access
);
27 extern handle_t
duplicate_handle( struct process
*src
, handle_t src_handle
, struct process
*dst
,
28 unsigned int access
, int inherit
, int options
);
29 extern handle_t
open_object( const WCHAR
*name
, size_t len
, const struct object_ops
*ops
,
30 unsigned int access
, int inherit
);
31 extern struct object
*alloc_handle_table( struct process
*process
, int count
);
32 extern struct object
*copy_handle_table( struct process
*process
, struct process
*parent
);
33 extern void close_global_handles(void);
35 #endif /* __WINE_SERVER_HANDLE_H */