comparison rvinterf/tmsh/init.c @ 0:e7502631a0f9

initial import from freecalypso-sw rev 1033:5ab737ac3ad7
author Mychaela Falconia <falcon@freecalypso.org>
date Sat, 11 Jun 2016 00:13:35 +0000
parents
children 2c6dca514a20
comparison
equal deleted inserted replaced
-1:000000000000 0:e7502631a0f9
1 /*
2 * This module contains the initialization code for fc-tmsh.
3 */
4
5 #include <sys/types.h>
6 #include <stdio.h>
7 #include <string.h>
8 #include <strings.h>
9 #include <stdlib.h>
10 #include "pktmux.h"
11 #include "localsock.h"
12
13 extern int sock;
14
15 init()
16 {
17 static u_char want_rvt_lost[9] = {CLI2RVI_WANT_RVTRACE,
18 0xFF, 0xFF, 0xFF, 0xFF,
19 0x00, 0x00, 0x00, 0x00};
20 static u_char want_rvt_etm[9] = {CLI2RVI_WANT_RVTRACE,
21 0xFF, 0xFF, 0xFF, 0xFF,
22 0x00, 0x1E, 0x00, 0x04};
23 static u_char want_etm_mux[2] = {CLI2RVI_WANT_MUXPROTO, RVT_TM_HEADER};
24
25 if (!sock)
26 connect_local_socket();
27 localsock_prep_for_length_rx();
28 send_init_command(want_rvt_lost, 9);
29 send_init_command(want_rvt_etm, 9);
30 send_init_command(want_etm_mux, 2);
31 }