patch-src_log_text_c 1.9 KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. --- snort-2.8.5.2.orig/src/log_text.c 2009-05-07 00:28:15.000000000 +0200
  2. +++ snort-2.8.5.2/src/log_text.c 2010-01-19 20:00:30.000000000 +0100
  3. @@ -1604,7 +1604,7 @@ void LogArpHeader(TextLog* log, Packet *
  4. switch(ntohs(p->ah->ea_hdr.ar_op))
  5. {
  6. case ARPOP_REQUEST:
  7. - bcopy((void *)p->ah->arp_tpa, (void *) &ip_addr, sizeof(ip_addr));
  8. + memcpy((void *) &ip_addr, (void *)p->ah->arp_tpa, sizeof(ip_addr));
  9. TextLog_Print(log, "ARP who-has %s", inet_ntoa(ip_addr));
  10. if(memcmp((char *) ezero, (char *) p->ah->arp_tha, 6) != 0)
  11. @@ -1613,7 +1613,7 @@ void LogArpHeader(TextLog* log, Packet *
  12. p->ah->arp_tha[1], p->ah->arp_tha[2], p->ah->arp_tha[3],
  13. p->ah->arp_tha[4], p->ah->arp_tha[5]);
  14. }
  15. - bcopy((void *)p->ah->arp_spa, (void *) &ip_addr, sizeof(ip_addr));
  16. + memcpy((void *) &ip_addr, (void *)p->ah->arp_spa, sizeof(ip_addr));
  17. TextLog_Print(log, " tell %s", inet_ntoa(ip_addr));
  18. @@ -1626,7 +1626,7 @@ void LogArpHeader(TextLog* log, Packet *
  19. break;
  20. case ARPOP_REPLY:
  21. - bcopy((void *)p->ah->arp_spa, (void *) &ip_addr, sizeof(ip_addr));
  22. + memcpy((void *) &ip_addr, (void *)p->ah->arp_spa, sizeof(ip_addr));
  23. TextLog_Print(log, "ARP reply %s", inet_ntoa(ip_addr));
  24. /* print out the originating request if we're on a weirder
  25. @@ -1659,7 +1659,7 @@ void LogArpHeader(TextLog* log, Packet *
  26. break;
  27. case ARPOP_RREPLY:
  28. - bcopy((void *)p->ah->arp_tpa, (void *) &ip_addr, sizeof(ip_addr));
  29. + memcpy((void *) &ip_addr, (void *)p->ah->arp_tpa, sizeof(ip_addr));
  30. TextLog_Print(log, "RARP reply %X:%X:%X:%X:%X:%X at %s",
  31. p->ah->arp_tha[0], p->ah->arp_tha[1], p->ah->arp_tha[2],
  32. p->ah->arp_tha[3], p->ah->arp_tha[4], p->ah->arp_tha[5],