-
Notifications
You must be signed in to change notification settings - Fork 0
/
ndrxloop.c
75 lines (53 loc) · 1.29 KB
/
ndrxloop.c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
/*
This file is an adapted version of the "main" file from the ENDUROX
command "buildserver -k ...". The main() function has been removed and replaced
by the ndrx_mainloop() function in the ndrxmodule.c file
(c) 1999, 2000 Ralf Henschkowski ([email protected])
*/
#include <stdio.h>
#include <xa.h>
#include <atmi.h>
#include <Python.h>
#if defined(__cplusplus)
extern "C" {
#endif
extern int _tmrunserver _((int));
#if defined(__cplusplus)
}
#endif
extern void endurox_dispatch(TPSVCINFO * rqst);
static struct tmdsptchtbl_t _tmdsptchtbl[] = {
{ "", "dispatch", (void (*) _((TPSVCINFO *))) endurox_dispatch, 0, 0 },
{ NULL, NULL, NULL, 0, 0 }
};
#ifndef _TMDLLIMPORT
#define _TMDLLIMPORT
#endif
_TMDLLIMPORT extern struct xa_switch_t tmnull_switch;
static struct xa_switch_t* xa_switch = &tmnull_switch;
static struct tmsvrargs_t tmsvrargs = {
NULL,
&_tmdsptchtbl[0],
0,
tpsvrinit,
tpsvrdone,
_tmrunserver, /* PRIVATE */
NULL, /* RESERVED */
NULL, /* RESERVED */
NULL, /* RESERVED */
NULL /* RESERVED */
};
struct tmsvrargs_t *
#ifdef _TMPROTOTYPES
_tmgetsvrargs(void)
#else
_tmgetsvrargs()
#endif
{
tmsvrargs.xa_switch = xa_switch;
return(&tmsvrargs);
}
void _set_XA_switch(struct xa_switch_t* new_xa_switch)
{
xa_switch = new_xa_switch;
}