16 #define DIM_VERSION_NUMBER 2015 19 #define MY_LITTLE_ENDIAN 0x1 20 #define MY_BIG_ENDIAN 0x2 22 #define VAX_FLOAT 0x10 23 #define IEEE_FLOAT 0x20 24 #define AXP_FLOAT 0x30 27 #define IT_IS_FLOAT 0x1000 36 #define DIM_NOSHARE noshare 37 #define RE_ENABLE_AST long int ast_enable = sys$setast(1); 38 #define RE_DISABLE_AST if (ast_enable != SS$_WASSET) sys$setast(0); 42 #define MY_FORMAT MY_LITTLE_ENDIAN+AXP_FLOAT 44 #define MY_FORMAT MY_LITTLE_ENDIAN+VAX_FLOAT 51 #include <sys/types.h> 52 #include <netinet/in.h> 61 #define RE_ENABLE_AST sigset_t set, oset;sigemptyset(&set);sigaddset(&set,SIGIO);sigaddset(&set,SIGALRM);sigprocmask(SIG_UNBLOCK,&set,&oset); 62 #define RE_DISABLE_AST sigprocmask(SIG_SETMASK,&oset,0); 66 #define MY_FORMAT MY_LITTLE_ENDIAN+IEEE_FLOAT 69 #define vtohl(l) _swapl(l) 70 #define htovl(l) _swapl(l) 71 #define vtohs(s) _swaps(s) 72 #define htovs(s) _swaps(s) 73 #define MY_FORMAT MY_BIG_ENDIAN+IEEE_FLOAT 91 #define RE_DISABLE_AST 95 #define MY_FORMAT MY_LITTLE_ENDIAN+IEEE_FLOAT 98 #define vtohl(l) _swapl(l) 99 #define htovl(l) _swapl(l) 100 #define vtohs(s) _swaps(s) 101 #define htovs(s) _swaps(s) 102 #define MY_FORMAT MY_BIG_ENDIAN+IEEE_FLOAT 111 #include <machine/types.h> 120 #define RE_ENABLE_AST sigmask(DEC_LEVEL); 121 #define RE_DISABLE_AST sigmask(INC_LEVEL); 122 #define vtohl(l) _swapl(l) 123 #define htovl(l) _swapl(l) 124 #define vtohs(s) _swaps(s) 125 #define htovs(s) _swaps(s) 126 #define MY_FORMAT MY_BIG_ENDIAN+IEEE_FLOAT+MY_OS9 127 typedef unsigned short ushort;
138 #define DNS_TASK "DIM_DNS" 139 #define DNS_PORT 2505 142 #define MIN_BIOCNT 50 144 #define DIS_DNS_TMOUT_MIN 5 145 #define DIS_DNS_TMOUT_MAX 10 146 #define DIC_DNS_TMOUT_MIN 5 147 #define DIC_DNS_TMOUT_MAX 10 148 #define MAX_SERVICE_UNIT 32 149 #define MAX_REGISTRATION_UNIT 100 150 #define CONN_BLOCK 32 153 #define TCP_RCV_BUF_SIZE 4096 154 #define TCP_SND_BUF_SIZE 4096 156 #define DIS_DNS_TMOUT_MIN 5 157 #define DIS_DNS_TMOUT_MAX 10 158 #define DIC_DNS_TMOUT_MIN 5 159 #define DIC_DNS_TMOUT_MAX 10 160 #define MAX_SERVICE_UNIT 100 161 #define MAX_REGISTRATION_UNIT 100 162 #define CONN_BLOCK 256 163 #define MAX_CONNS 1024 165 #define TCP_RCV_BUF_SIZE 65536 166 #define TCP_SND_BUF_SIZE 65536 168 #define DID_DNS_TMOUT_MIN 5 169 #define DID_DNS_TMOUT_MAX 10 174 #define WATCHDOG_TMOUT_MIN 60 175 #define WATCHDOG_TMOUT_MAX 90 180 #define MAX_NODE_NAME 40 181 #define MAX_TASK_NAME 40 197 #define STA_DISC (-1) 201 #define START_PORT_RANGE 5100 202 #define STOP_PORT_RANGE 10000 203 #define TEST_TIME_OSK 15 204 #define TEST_TIME_VMS 30 205 #define TEST_WRITE_TAG 25 206 #define WRITE_TMOUT 5 208 #define OPN_MAGIC 0xc0dec0de 209 #define HDR_MAGIC 0xfeadfead 210 #define LONG_HDR_MAGIC 0xfeadc0de 211 #define TST_MAGIC 0x11131517 212 #define TRP_MAGIC 0x71513111 240 #define DIC_HEADER (MAX_NAME + 20) 260 #define DIS_STAMPED_HEADER 32 283 #define DIS_DNS_HEADER (MAX_NODE_NAME + MAX_TASK_NAME + 28) 291 #define DNS_DIS_HEADER 8 319 #define DNS_DIC_HEADER (MAX_NODE_NAME + MAX_TASK_NAME + MAX_NAME + 24) 487 #define __CXX_CONST const 498 int *port,
void (*error_ast)()) );
501 int server_protocol,
void (*read_ast)(),
void (*error_ast)(),
SRC_TYPES src_type ));
512 void (*ast_routine)()) );
571 void *buff_out,
void *buff_in,
int size) );
573 void *buff_in,
int size) );
596 #define SIZEOF_CHAR 1 597 #define SIZEOF_SHORT 2 598 #define SIZEOF_LONG 4 599 #define SIZEOF_FLOAT 4 600 #define SIZEOF_DOUBLE 8 602 #if defined(OSK) && !defined(_UCC) 603 # define inc_pter(p,i) (char *)p += (i) 605 # define inc_pter(p,i) p = (void *)((char *)p + (i))
int tcpip_start_listen(int conn_id, void(*ast_routine)())
DIM_NOSHARE DIC_CONNECTION * Dic_conns
_DIM_PROTOE(int dna_start_read,(int conn_id, int size))
void dna_test_write(int conn_id)
int dtq_delete(int queue_id)
DllExp DIM_NOSHARE int Curr_N_Conns
SLL * sll_get_head(SLL *head)
void _swaps_buffer(short *s2, short *s1, int n)
DLL * dll_get_prev(DLL *head, DLL *item)
int dna_write(int conn_id, void *buffer, int size)
void dll_insert_after(DLL *atitem, DLL *item)
int copy_swap_buffer_in(FORMAT_STR *format_data, void *buff_out, void *buff_in, int size)
DllExp DIM_NOSHARE DNS_CONNECTION * Dns_conns
int dna_open_client(char *server_node, char *server_task, int port, int server_protocol, void(*read_ast)(), void(*error_ast)(), SRC_TYPES src_type)
void * arr_increase(void *conn_ptr, int conn_size, int n_conns)
DllExp DIM_NOSHARE NET_CONNECTION * Net_conns
void dll_insert_queue(DLL *head, DLL *item)
int dna_close(int conn_id)
int copy_swap_buffer_out(int format, FORMAT_STR *format_data, void *buff_out, void *buff_in, int size)
void conn_free(int conn_id)
int _swapl_by_addr(int *l)
struct dic_serv DIC_SERVICE
void dll_remove(DLL *item)
SLL * sll_get_next(SLL *item)
void conn_arr_create(SRC_TYPES type)
int get_dns_node_name(char *node_name)
SLL * sll_remove_head(SLL *head)
int sll_insert_queue(SLL *head, SLL *item)
int dtq_clear_entry(TIMR_ENT *entry)
int dtq_rem_entry(int queue_id, TIMR_ENT *entry)
int tcpip_start_read(int conn_id, char *buffer, int size, void(*ast_routine)())
SLL * sll_search_next_remove(SLL *item, int offset, char *data, int size)
int get_dns_accepted_nodes(char *nodes)
int tcpip_close(int conn_id)
int dna_get_node_task(int conn_id, char *node, char *task)
void dna_report_error(int conn_id, int code, char *routine_name, int severity, int errcode)
FORMAT_STR format_data[MAX_NAME/4]
int sll_remove(SLL *head, SLL *item)
void _swapl_buffer(int *s2, int *s1, int n)
int dna_write_nowait(int conn_id, void *buffer, int size)
void _swapd_buffer(double *s2, double *s1, int n)
int get_dns_port_number()
struct timer_entry TIMR_ENT
struct timer_entry * next_done
double _swapd_by_addr(double *d)
int dna_open_server(char *task, void(*read_ast)(), int *protocol, int *port, void(*error_ast)())
int tcpip_write(int conn_id, char *buffer, int size)
TIMR_ENT * dtq_add_entry(int queue_id, int time, void(*user_routine)(), dim_long tag)
DllExp DIM_NOSHARE DNA_CONNECTION * Dna_conns
short _swaps_by_addr(short *s)
DLL * dll_get_next(DLL *head, DLL *item)
int tcpip_open_client(int conn_id, char *node, char *task, int port)
void * id_arr_increase(void *id_ptr, int id_size, int n_ids)
int HashFunction(char *name, int max)
void tcpip_get_node_task(int conn_id, char *node, char *task)
struct timer_entry * next
int tcpip_open_server(int conn_id, char *task, int *port)
int dna_start_read(int conn_id, int size)
int get_node_name(char *node_name)
int tcpip_failure(int code)
SLL * sll_search(SLL *head, char *data, int size)
_DIM_PROTO(void DimDummy,())
int get_dns_accepted_domains(char *domains)
DLL * dll_search(DLL *head, char *data, int size)
int tcpip_open_connection(int conn_id, int path)
struct timer_entry * prev
void tcpip_report_error(int code)