2 * Wine server definitions
4 * Copyright (C) 1998 Alexandre Julliard
7 #ifndef __WINE_SERVER_H
8 #define __WINE_SERVER_H
10 /* message header as sent on the wire */
13 unsigned int len; /* total msg length (including this header) */
14 unsigned int type; /* msg type */
15 unsigned int seq; /* sequence number */
18 /* max msg length (not including the header) */
19 #define MAX_MSG_LENGTH (16384 - sizeof(struct header))
21 /* request from client to server */
25 REQ_TIMEOUT, /* internal timeout msg */
26 REQ_KILL_THREAD, /* internal kill thread msg */
27 REQ_NEW_THREAD, /* create a new thread (called from the creator) */
28 REQ_INIT_THREAD, /* init a new thread (called by itself) */
32 /* request structures */
34 struct new_thread_request
36 void *pid; /* process id for the new thread (or 0 if none yet) */
39 struct new_thread_reply
41 void *tid; /* thread id */
42 void *pid; /* process id (created if necessary) */
45 struct init_thread_request
51 /* server-side functions */
53 extern void server_main_loop( int fd );
56 /* client-side functions */
58 #ifndef __WINE_SERVER__
60 extern int CLIENT_NewThread( struct _THDB *thdb );
61 extern int CLIENT_InitThread(void);
62 #endif /* __WINE_SERVER__ */
64 #endif /* __WINE_SERVER_H */