]>
Commit | Line | Data |
---|---|---|
0083c904 BK |
1 | |
2 | /* | |
1f414ac4 | 3 | * server.c Set up and handle communications with a server process. |
0083c904 | 4 | * |
1f414ac4 | 5 | * Server Handling copyright 1992-1999 The Free Software Foundation |
0083c904 BK |
6 | * |
7 | * Server Handling is free software. | |
8 | * You may redistribute it and/or modify it under the terms of the | |
9 | * GNU General Public License, as published by the Free Software | |
10 | * Foundation; either version 2, or (at your option) any later version. | |
11 | * | |
12 | * Server Handling is distributed in the hope that it will be useful, | |
13 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | |
14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
15 | * GNU General Public License for more details. | |
16 | * | |
17 | * You should have received a copy of the GNU General Public License | |
18 | * along with Server Handling. See the file "COPYING". If not, | |
19 | * write to: The Free Software Foundation, Inc., | |
20 | * 59 Temple Place - Suite 330, | |
21 | * Boston, MA 02111-1307, USA. | |
22 | * | |
1f414ac4 BK |
23 | * As a special exception, The Free Software Foundation gives |
24 | * permission for additional uses of the text contained in his release | |
25 | * of ServerHandler. | |
0083c904 BK |
26 | * |
27 | * The exception is that, if you link the ServerHandler library with other | |
28 | * files to produce an executable, this does not by itself cause the | |
29 | * resulting executable to be covered by the GNU General Public License. | |
30 | * Your use of that executable is in no way restricted on account of | |
31 | * linking the ServerHandler library code into it. | |
32 | * | |
33 | * This exception does not however invalidate any other reasons why | |
34 | * the executable file might be covered by the GNU General Public License. | |
35 | * | |
1f414ac4 BK |
36 | * This exception applies only to the code released by The Free |
37 | * Software Foundation under the name ServerHandler. If you copy code | |
38 | * from other sources under the General Public License into a copy of | |
39 | * ServerHandler, as the General Public License permits, the exception | |
40 | * does not apply to the code that you add in this way. To avoid | |
41 | * misleading anyone as to the status of such modified files, you must | |
42 | * delete this exception notice from them. | |
0083c904 BK |
43 | * |
44 | * If you write modifications of your own for ServerHandler, it is your | |
45 | * choice whether to permit this exception to apply to your modifications. | |
46 | * If you do not wish that, delete this exception notice. | |
47 | */ | |
48 | ||
88657302 RH |
49 | #ifndef GCC_SERVER_H |
50 | #define GCC_SERVER_H | |
0083c904 | 51 | |
0083c904 BK |
52 | /* |
53 | * Dual pipe opening of a child process | |
54 | */ | |
55 | ||
56 | typedef struct | |
1f414ac4 BK |
57 | { |
58 | int read_fd; | |
59 | int write_fd; | |
60 | } t_fd_pair; | |
0083c904 BK |
61 | |
62 | typedef struct | |
1f414ac4 BK |
63 | { |
64 | FILE *pf_read; /* parent read fp */ | |
65 | FILE *pf_write; /* parent write fp */ | |
66 | } t_pf_pair; | |
0083c904 | 67 | |
3af556f7 | 68 | char *run_shell PARAMS (( const char *pzCmd)); |
2629a114 BK |
69 | pid_t proc2_fopen PARAMS (( t_pf_pair * p_pair, tCC ** pp_args)); |
70 | pid_t proc2_open PARAMS (( t_fd_pair * p_pair, tCC ** pp_args)); | |
71 | int chain_open PARAMS (( int in_fd, tCC ** pp_args, | |
3af556f7 BK |
72 | pid_t * p_child)); |
73 | void close_server PARAMS (( void )); | |
88657302 RH |
74 | |
75 | #endif /* ! GCC_SERVER_H */ |