diff options
author | phk <phk@FreeBSD.org> | 2003-04-03 11:32:01 +0000 |
---|---|---|
committer | phk <phk@FreeBSD.org> | 2003-04-03 11:32:01 +0000 |
commit | f8257495cfc91bb077fec7f102ef9041f0f69e99 (patch) | |
tree | 5ef5bc6e24bd0a3c6ed3a210012eed43de162d1d /sys/sys/endian.h | |
parent | 7d796a935a99e23431509cea2c7a54171aea8d22 (diff) | |
download | FreeBSD-src-f8257495cfc91bb077fec7f102ef9041f0f69e99.zip FreeBSD-src-f8257495cfc91bb077fec7f102ef9041f0f69e99.tar.gz |
Pointy hat commit:
Don't Cut&Paste from big endian to little endian function without subsequent
adjustments.
Diffstat (limited to 'sys/sys/endian.h')
-rw-r--r-- | sys/sys/endian.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/sys/endian.h b/sys/sys/endian.h index 8ffa66c..01af506 100644 --- a/sys/sys/endian.h +++ b/sys/sys/endian.h @@ -136,7 +136,7 @@ le64dec(const void *pp) { unsigned char const *p = pp; - return (((uint64_t)be32dec(p + 4) << 32) | be32dec(p)); + return (((uint64_t)le32dec(p + 4) << 32) | le32dec(p)); } static __inline void @@ -193,8 +193,8 @@ le64enc(void *pp, uint64_t u) { unsigned char *p = pp; - be32enc(p, u & 0xffffffff); - be32enc(p + 4, u >> 32); + le32enc(p, u & 0xffffffff); + le32enc(p + 4, u >> 32); } #endif /* _SYS_ENDIAN_H_ */ |