pcap_offline_read(pcap_t *p, int cnt, pcap_handler callback, u_char *user)
{
struct bpf_insn *fcode;
- int status = 0;
int n = 0;
u_char *data;
- while (status == 0) {
+ for (;;) {
struct pcap_pkthdr h;
+ int status;
/*
* Has "pcap_breakloop()" been called?
}
if (status == 0) {
/*
- * EOF. Return the number of packets we've
- * processed in the loop; if we haven't
- * processed any, we return 0, which indicates
- * that we're at the end of the file.
+ * EOF. Nothing more to process;
*/
- return (n);
+ break;
}
/*