#include fix for glibc 2.1.3
[citadel.git] / citadel / sysdep_decls.h
1 /* $Id$ */
2
3 #include <pthread.h>
4 #include "sysdep.h"
5 #include "server.h"
6
7 void lprintf (int loglevel, const char *format, ...);
8 void init_sysdep (void);
9 void begin_critical_section (int which_one);
10 void end_critical_section (int which_one);
11 int ig_tcp_server (int port_number, int queue_len);
12 int ig_uds_server(char *sockpath, int queue_len);
13 struct CitContext *MyContext (void);
14 struct CitContext *CreateNewContext (void);
15 void InitMyContext (struct CitContext *con);
16 void client_write (char *buf, int nbytes);
17 void cprintf (const char *format, ...);
18 int client_read_to (char *buf, int bytes, int timeout);
19 int client_read (char *buf, int bytes);
20 int client_gets (char *buf);
21 void sysdep_master_cleanup (void);
22 void kill_session (int session_to_kill);
23 void *sd_context_loop (struct CitContext *con);
24 void start_daemon (int do_close_stdio);
25 void cmd_nset (char *cmdbuf);
26 int convert_login (char *NameToConvert);
27 void *worker_thread (void *arg);
28 inline void become_session(struct CitContext *which_con);
29 void CtdlRedirectOutput(FILE *fp, int sock);
30 void InitializeMasterCC(void);
31 void init_master_fdset(void);
32 void create_worker(void);
33
34 extern DLEXP int num_sessions;
35 extern DLEXP volatile int time_to_die;
36 extern DLEXP int verbosity;
37 extern DLEXP int rescan[];
38 extern DLEXP pthread_t initial_thread;
39
40 extern DLEXP struct worker_node {
41         pthread_t tid;
42         struct worker_node *next;
43 } *worker_list;