FreeCalypso > hg > freecalypso-tools
comparison rvinterf/lowlevel/rvtdump.c @ 222:7168f63fc3b8
rvinterf: implemented keepalive mechanism
author | Mychaela Falconia <falcon@freecalypso.org> |
---|---|
date | Sat, 20 May 2017 21:00:15 +0000 |
parents | e7502631a0f9 |
children | 6f078c4a5506 |
comparison
equal
deleted
inserted
replaced
221:a46a68500517 | 222:7168f63fc3b8 |
---|---|
20 char *logfname; | 20 char *logfname; |
21 FILE *logF; | 21 FILE *logF; |
22 time_t logtime; | 22 time_t logtime; |
23 int background; | 23 int background; |
24 int no_output; /* for output.c */ | 24 int no_output; /* for output.c */ |
25 | |
26 static char keepalive_msg[] = | |
27 "Received keepalive query, unable to respond, please run rvinterf"; | |
25 | 28 |
26 main(argc, argv) | 29 main(argc, argv) |
27 char **argv; | 30 char **argv; |
28 { | 31 { |
29 extern char *optarg; | 32 extern char *optarg; |
126 report_extui_packet(); | 129 report_extui_packet(); |
127 return; | 130 return; |
128 case RVT_TCH_HEADER: | 131 case RVT_TCH_HEADER: |
129 print_tch_output_raw(); | 132 print_tch_output_raw(); |
130 return; | 133 return; |
134 case RVT_KEEPALIVE_HEADER: | |
135 if (rxpkt_len != 2 || rxpkt[1] != 'Q') | |
136 goto unknown; | |
137 output_line(keepalive_msg); | |
138 return; | |
131 case '*': | 139 case '*': |
132 print_fc_lld_msg(); | 140 print_fc_lld_msg(); |
133 return; | 141 return; |
134 default: | 142 default: |
135 unknown: | 143 unknown: |