root/src/modules/external_proc.h

Revision dc414cff50ce974e1b64ce24d6be49d5c0c70a83, 0.7 kB (checked in by Theo Schlossnagle <jesus@omniti.com>, 6 years ago)

initial implementation.. works on Mac OS X. refs #101

  • Property mode set to 100644
Line 
1 #ifndef MODULES_EXTERNAL_PROC_H
2 #define MODULES_EXTERNAL_PROC_H
3
4 #include "noit_defines.h"
5 #include "eventer/eventer.h"
6 #include "utils/noit_atomic.h"
7 #include "utils/noit_hash.h"
8
9 struct external_response {
10   int64_t check_no;
11   int32_t exit_code;
12   int stdoutlen_sofar;
13   u_int16_t stdoutlen;
14   char *stdoutbuff;
15   int stderrlen_sofar;
16   u_int16_t stderrlen;
17   char *stderrbuff;
18 };
19 typedef struct {
20   noit_log_stream_t nlerr;
21   noit_log_stream_t nldeb;
22   int child;
23   int pipe_n2e[2];
24   int pipe_e2n[2];
25   eventer_jobq_t *jobq;
26   noit_atomic64_t check_no_seq;
27   noit_hash_table external_checks;
28
29   struct external_response *cr;
30 } external_data_t;
31
32 int external_child(external_data_t *);
33
34 #endif
Note: See TracBrowser for help on using the browser.