diff options
author | John Marino <marino@FreeBSD.org> | 2014-07-07 15:16:05 +0000 |
---|---|---|
committer | John Marino <marino@FreeBSD.org> | 2014-07-07 15:16:05 +0000 |
commit | b6c08b0df5503be01627016cd107b835b91a8c8d (patch) | |
tree | 4311c9ac50ce47a0a3629b7ae3f5511c88c6cf0b /security/arpCounterattack/files/patch-address.hpp | |
parent | Add staging support (diff) |
security/arpCounterattack: stage, fix on F10+, fix on DragonFly
Also:
* convert to c++11 for clang builds
* convert to new LIB_DEPENDS format
* use @sample keyword
* pet portlint
* USE=tar
Notes
Notes:
svn path=/head/; revision=361098
Diffstat (limited to 'security/arpCounterattack/files/patch-address.hpp')
-rw-r--r-- | security/arpCounterattack/files/patch-address.hpp | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/security/arpCounterattack/files/patch-address.hpp b/security/arpCounterattack/files/patch-address.hpp new file mode 100644 index 000000000000..57fb6a54fa1e --- /dev/null +++ b/security/arpCounterattack/files/patch-address.hpp @@ -0,0 +1,29 @@ +--- address.hpp.orig 2010-09-28 18:12:26.000000000 +0000 ++++ address.hpp +@@ -28,7 +28,7 @@ + #include <sys/socket.h> + + #include <arpa/inet.h> +-#ifdef __FreeBSD__ ++#if defined(__FreeBSD__) || defined(__DragonFly__) + #include <netinet/if_ether.h> + #endif + #ifdef __linux__ +@@ -44,7 +44,7 @@ + std::string textToEthernet(const std::string &textEthernetAddress) { + ether_addr binaryEthernetAddress; + ether_aton_r(textEthernetAddress.c_str(), &binaryEthernetAddress); +- #ifdef __FreeBSD__ ++ #if defined(__FreeBSD__) || defined(__DragonFly__) + return std::string((char*)binaryEthernetAddress.octet, ETHER_ADDR_LEN); + #endif + #ifdef __linux__ +@@ -60,7 +60,7 @@ std::string textToEthernet(const std::st + std::string ethernetToText(const char *binaryEthernetAddress) { + ether_addr _binaryEthernetAddress; + char textEthernetAddress[17]; +- #ifdef __FreeBSD__ ++ #if defined(__FreeBSD__) || defined(__DragonFly__) + memcpy(_binaryEthernetAddress.octet, binaryEthernetAddress, ETHER_ADDR_LEN); + #endif + #ifdef __linux__ |