use untoh64 instead of non-portable be64toh
authorAndreas Steffen <andreas.steffen@strongswan.org>
Tue, 6 Dec 2011 14:15:40 +0000 (15:15 +0100)
committerAndreas Steffen <andreas.steffen@strongswan.org>
Tue, 20 Mar 2012 16:31:13 +0000 (17:31 +0100)
src/libcharon/encoding/payloads/transform_attribute.c

index 6a6451e..a11ee98 100644 (file)
@@ -199,7 +199,7 @@ METHOD(transform_attribute_t, get_value, u_int64_t,
        }
        memcpy(((char*)&value) + sizeof(value) - this->attribute_value.len,
                   this->attribute_value.ptr, this->attribute_value.len);
-       return be64toh(value);
+       return untoh64((char*)&value);
 }
 
 METHOD(transform_attribute_t, get_attribute_type, u_int16_t,