Changeset 1930
- Timestamp:
- 10/30/07 20:51:50 (13 months ago)
- Files:
-
- 1 modified
-
branches/3.2/src/common/sendpacket.c (modified) (4 diffs)
Legend:
- Unmodified
- Added
- Removed
-
branches/3.2/src/common/sendpacket.c
r1897 r1930 392 392 pcap_t *pcap; 393 393 sendpacket_t *sp; 394 /*395 394 u_int spoof_eth_src = 1; 396 395 int fd; 397 */ 396 398 397 assert(device); 399 398 assert(errbuf); … … 409 408 sp->handle.pcap = pcap; 410 409 411 /*412 410 fd = pcap_get_selectable_fd(pcap); 413 if (ioctl(fd, BIOCSHDRCMPLT, &spoof_eth_src) == -1) {411 if (ioctl(fd, BIOCSHDRCMPLT, &spoof_eth_src) == -1) 414 412 errx(1, "Unable to enable source MAC spoof support: %s", strerror(errno)); 415 }416 */417 413 418 414 return sp; … … 648 644 struct bpf_version bv; 649 645 u_int v; 650 #if defined(BIOCGHDRCMPLT) && defined(BIOCSHDRCMPLT) && !(__APPLE__)646 #if defined(BIOCGHDRCMPLT) && defined(BIOCSHDRCMPLT) 651 647 u_int spoof_eth_src = 1; 652 648 #endif … … 705 701 * automatic filling of the link level source address. 706 702 */ 707 #if defined(BIOCGHDRCMPLT) && defined(BIOCSHDRCMPLT) && !(__APPLE__)703 #if defined(BIOCGHDRCMPLT) && defined(BIOCSHDRCMPLT) 708 704 if (ioctl(mysocket, BIOCSHDRCMPLT, &spoof_eth_src) == -1) { 709 705 snprintf(errbuf, SENDPACKET_ERRBUF_SIZE,
