Lines Matching defs:pp

56 	Netflow_file_t*	pp;
58 if (!(pp = vmnewof(file->vm, 0, Netflow_file_t, 1, (file->flags & DSS_FILE_WRITE) ? NETFLOW_PACKET : 0)))
64 file->data = pp;
65 pp->data = pp->last = 0;
66 pp->data++;
77 register Netflow_file_t* pp = (Netflow_file_t*)file->data;
79 register Netflow_t* rp = &pp->record;
89 if ((pp->data += pp->next) <= (pp->last - pp->next))
92 sfprintf(sfstderr, "count %d\n", pp->count);
93 pp->count--;
97 pp->data = pp->last;
101 sfprintf(sfstderr, "count %d\n", pp->count);
102 while (!pp->count--)
105 if (!(pp->data = (unsigned char*)sfreserve(file->io, NETFLOW_PACKET, 0)))
111 if ((rp->version = BE2(pp->data)) != 9)
113 pp->count = rp->count = BE2(pp->data);
115 sfprintf(sfstderr, "header version %d size %d flowsets %d offset %I*d\n", rp->version, 20, pp->count, sizeof(file->offset), file->offset);
116 rp->uptime = BE4(pp->data);
117 rp->time = BE4(pp->data);
118 rp->flow_sequence = BE4(pp->data);
119 rp->source_id = BE4(pp->data);
120 pp->boot = ((Nftime_t)rp->time * MS - (Nftime_t)rp->uptime) * US + (Nftime_t)rp->nsec;
123 sfprintf(sfstderr, "record %d flowset %d\n", file->count, rp->count - pp->count);
124 n = BE2(pp->data);
125 if ((z = BE2(pp->data) - 4) <= 0)
127 pp->count = 0;
130 pp->last = pp->data + z;
141 pp->count = 0;
149 pp->count = 0;
152 pp->template = tp;
153 pp->next = tp->size;
159 pp->count++;
160 while (pp->data < (pp->last - 4))
162 n = BE2(pp->data);
163 m = BE2(pp->data);
166 if ((pp->last - pp->data) < m * 4)
184 pp->count--;
189 n = BE2(pp->data);
190 z = BE2(pp->data);
208 pp->count++;
210 while (pp->data < (pp->last - 6))
212 n = BE2(pp->data);
213 m = BE2(pp->data) / 4;
214 k = BE2(pp->data) / 4;
234 pp->count--;
239 n = BE2(pp->data);
240 z = BE2(pp->data);
247 n = BE2(pp->data);
248 z = BE2(pp->data);
271 pp->data = pp->last;