Packets: Add StringParser ostream operation
[senf.git] / Socket / Protocols / Raw / MACAddress.ct
index 2f87896..e0b4ef3 100644 (file)
@@ -26,6 +26,7 @@
 //#include "MACAddress.ih"
 
 // Custom includes
+#include "../../../config.hh"
 
 #define prefix_
 ///////////////////////////////ct.p////////////////////////////////////////
@@ -37,10 +38,7 @@ template <class InputIterator>
 prefix_ senf::MACAddress::MACAddress senf::MACAddress::from_data(InputIterator i)
 {
     MACAddress mac (senf::noinit);
-    iterator j (mac.begin());
-    iterator const j_end (mac.end());
-    for (;j!=j_end;++j,++i)
-        *j = *i;
+    SENF_copy_n(i, 6, mac.begin());
     return mac;
 }