summaryrefslogtreecommitdiffstats
path: root/plugins-root/check_icmp.c
diff options
context:
space:
mode:
Diffstat (limited to 'plugins-root/check_icmp.c')
-rw-r--r--plugins-root/check_icmp.c14
1 files changed, 6 insertions, 8 deletions
diff --git a/plugins-root/check_icmp.c b/plugins-root/check_icmp.c
index 18eed74..d1fe5b1 100644
--- a/plugins-root/check_icmp.c
+++ b/plugins-root/check_icmp.c
@@ -991,17 +991,17 @@ wait_for_reply(int sock, u_int t)
991 if (jitter_tmp > host->jitter_max) 991 if (jitter_tmp > host->jitter_max)
992 host->jitter_max=jitter_tmp; 992 host->jitter_max=jitter_tmp;
993 } 993 }
994 994
995 /* Check if packets in order */ 995 /* Check if packets in order */
996 if (host->last_icmp_seq >= icp.icmp_seq) 996 if (host->last_icmp_seq >= packet.icp->icmp_seq)
997 host->order_status=STATE_CRITICAL; 997 host->order_status=STATE_CRITICAL;
998 } 998 }
999 host->last_tdiff=tdiff; 999 host->last_tdiff=tdiff;
1000 1000
1001 host->last_icmp_seq=icp.icmp_seq; 1001 host->last_icmp_seq=packet.icp->icmp_seq;
1002 1002
1003 //printf("%d tdiff %d host->jitter %u host->last_tdiff %u\n", icp.icmp_seq, tdiff, host->jitter, host->last_tdiff); 1003 //printf("%d tdiff %d host->jitter %u host->last_tdiff %u\n", icp.icmp_seq, tdiff, host->jitter, host->last_tdiff);
1004 1004
1005 host->time_waited += tdiff; 1005 host->time_waited += tdiff;
1006 host->icmp_recv++; 1006 host->icmp_recv++;
1007 icmp_recv++; 1007 icmp_recv++;
@@ -1596,8 +1596,6 @@ add_target_ip(char *arg, struct sockaddr_storage *in)
1596 } 1596 }
1597 1597
1598 /* fill out the sockaddr_in struct */ 1598 /* fill out the sockaddr_in struct */
1599 host->saddr_in.sin_family = AF_INET;
1600 host->saddr_in.sin_addr.s_addr = in->s_addr;
1601 host->rtmin = INFINITY; 1599 host->rtmin = INFINITY;
1602 host->rtmax = 0; 1600 host->rtmax = 0;
1603 host->jitter=0; 1601 host->jitter=0;