1/*-
2 * Test 0010:	BPF_LD+BPF_H+BPF_IND
3 *
4 * $FreeBSD$
5 */
6
7/* BPF program */
8static struct bpf_insn	pc[] = {
9	BPF_STMT(BPF_LDX+BPF_IMM, 1),
10	BPF_STMT(BPF_LD+BPF_H+BPF_IND, 1),
11	BPF_STMT(BPF_RET+BPF_A, 0),
12};
13
14/* Packet */
15static u_char	pkt[] = {
16	0x01, 0x23, 0x45, 0x67,
17};
18
19/* Packet length seen on wire */
20static u_int	wirelen =	sizeof(pkt);
21
22/* Packet length passed on buffer */
23static u_int	buflen =	sizeof(pkt);
24
25/* Invalid instruction */
26static int	invalid =	0;
27
28/* Expected return value */
29static u_int	expect =	0x4567;
30
31/* Expected signal */
32static int	expect_signal =	0;
33