You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

20 lines
787 B

  1. --- a/src/main.c
  2. +++ b/src/main.c
  3. @@ -252,7 +252,7 @@ void packet_handler_ex(const struct pcap
  4. if (handle == NULL || pcap_sendpacket(handle, pkt_data, header->len) != 0)
  5. {
  6. //error detected
  7. - long nowTime;
  8. + time_t nowTime;
  9. time(&nowTime);
  10. if (nowTime - cfg.init_time > ERRTIMEOUT && header->len < 1500)
  11. {
  12. @@ -282,7 +282,7 @@ void packet_handler_ex(const struct pcap
  13. if (handle == NULL || pcap_sendpacket(handle, buf, header->len) != 0)
  14. {
  15. //error detected
  16. - long nowTime;
  17. + time_t nowTime;
  18. time(&nowTime);
  19. if (nowTime - cfg.init_time > ERRTIMEOUT && header->len < 1500)
  20. {