FACT++  1.0
int dna_close ( int  conn_id)

Definition at line 835 of file dna.c.

References DIM_ERROR, DIMTCPWRTMO, dna_report_error(), find_pend_conn(), ins_pend_conn(), Net_conns, release_conn(), and time.

Referenced by dic_close_dns(), dic_find_server_conns(), dic_get_id(), dis_find_client_conns(), dis_remove_service(), dis_stop_serving(), dna_open_client(), do_dis_add_service(), do_dis_stop_serving_dns(), recv_dns_dic_rout(), recv_dns_dis_rout(), release_all_requests(), release_conn(), and web_open_server().

836 {
837  if(conn_id > 0)
838  {
839  if(Net_conns[conn_id].write_timedout)
840  {
841  dna_report_error(conn_id, -1,
842  "Write timeout, disconnecting from", DIM_ERROR, DIMTCPWRTMO);
843  if(!find_pend_conn(Net_conns[conn_id].node, Net_conns[conn_id].task, 0, 0, 1))
844  ins_pend_conn(Net_conns[conn_id].node, Net_conns[conn_id].task, 0, 0, 1, time(NULL));
845  }
846  release_conn(conn_id);
847  }
848  return(1);
849 }
Definition: dns.c:26
DllExp DIM_NOSHARE NET_CONNECTION * Net_conns
Definition: conn_handler.c:32
#define DIMTCPWRTMO
Definition: dim_common.h:295
Warning because the service this data corrsponds to might have been last updated longer ago than Local time
Definition: smartfact.txt:92
void dna_report_error(int conn_id, int code, char *routine_name, int severity, int errcode)
Definition: dna.c:903
static void release_conn(int conn_id)
Definition: dna.c:853
static int ins_pend_conn(char *node, char *task, int port, SRC_TYPES src_type, int type, time_t last_used)
Definition: dna.c:620
static int find_pend_conn(char *node, char *task, int port, SRC_TYPES src_type, int type)
Definition: dna.c:675

+ Here is the call graph for this function:

+ Here is the caller graph for this function: