1999-05-15 12:48:19 +02:00
|
|
|
/*
|
|
|
|
* Server-side handle definitions
|
|
|
|
*
|
|
|
|
* Copyright (C) 1999 Alexandre Julliard
|
|
|
|
*/
|
|
|
|
|
|
|
|
#ifndef __WINE_SERVER_HANDLE_H
|
|
|
|
#define __WINE_SERVER_HANDLE_H
|
|
|
|
|
1999-06-22 19:26:53 +02:00
|
|
|
#include <stdlib.h>
|
1999-11-25 22:30:24 +01:00
|
|
|
#include "windef.h"
|
2001-07-19 02:35:37 +02:00
|
|
|
#include "wine/server_protocol.h"
|
1999-06-22 19:26:53 +02:00
|
|
|
|
1999-05-15 12:48:19 +02:00
|
|
|
struct process;
|
|
|
|
struct object_ops;
|
|
|
|
|
|
|
|
/* handle functions */
|
|
|
|
|
|
|
|
/* alloc_handle takes a void *obj for convenience, but you better make sure */
|
|
|
|
/* that the thing pointed to starts with a struct object... */
|
2001-01-05 05:08:07 +01:00
|
|
|
extern handle_t alloc_handle( struct process *process, void *obj,
|
|
|
|
unsigned int access, int inherit );
|
|
|
|
extern int close_handle( struct process *process, handle_t handle, int *fd );
|
|
|
|
extern struct object *get_handle_obj( struct process *process, handle_t handle,
|
1999-05-15 12:48:19 +02:00
|
|
|
unsigned int access, const struct object_ops *ops );
|
2001-01-05 05:08:07 +01:00
|
|
|
extern int get_handle_fd( struct process *process, handle_t handle, unsigned int access );
|
|
|
|
extern handle_t duplicate_handle( struct process *src, handle_t src_handle, struct process *dst,
|
|
|
|
unsigned int access, int inherit, int options );
|
|
|
|
extern handle_t open_object( const WCHAR *name, size_t len, const struct object_ops *ops,
|
|
|
|
unsigned int access, int inherit );
|
1999-06-04 21:49:54 +02:00
|
|
|
extern struct object *alloc_handle_table( struct process *process, int count );
|
|
|
|
extern struct object *copy_handle_table( struct process *process, struct process *parent );
|
|
|
|
extern void close_global_handles(void);
|
1999-05-15 12:48:19 +02:00
|
|
|
|
|
|
|
#endif /* __WINE_SERVER_HANDLE_H */
|