Lines Matching defs:idx
41 mopGetChar(const u_char *pkt, int *idx)
45 ret = pkt[*idx];
46 *idx = *idx + 1;
51 mopGetShort(const u_char *pkt, int *idx)
55 ret = pkt[*idx] + pkt[*idx+1]*256;
56 *idx = *idx + 2;
61 mopGetLong(const u_char *pkt, int *idx)
65 ret = pkt[*idx] +
66 pkt[*idx+1]*0x100 +
67 pkt[*idx+2]*0x10000 +
68 pkt[*idx+3]*0x1000000;
69 *idx = *idx + 4;
74 mopGetMulti(const u_char *pkt, int *idx, u_char *dest, int size)
79 dest[i] = pkt[*idx+i];
81 *idx = *idx + size;
102 mopGetHeader(const u_char *pkt, int *idx, const u_char **dst, const u_char **src,
107 *idx = *idx + 12;
111 *proto = (u_short)(pkt[*idx]*256 + pkt[*idx+1]);
112 *idx = *idx + 2;
113 *len = (int)(pkt[*idx+1]*256 + pkt[*idx]);
114 *idx = *idx + 2;
117 *len = (int)(pkt[*idx]*256 + pkt[*idx+1]);
118 *idx = *idx + 8;
119 *proto = (u_short)(pkt[*idx]*256 + pkt[*idx+1]);
120 *idx = *idx + 2;