fixed yet another endian issue (I used the wrong define for it)

This commit is contained in:
TLINDEN
2013-11-19 21:02:59 +01:00
parent 8b3b76d52d
commit 04dbf19381
8 changed files with 26 additions and 14 deletions

View File

@@ -78,7 +78,7 @@ pcp_sig_t *pcp_ed_newsig(unsigned char *hash, char *id) {
}
pcp_sig_t *sig2native(pcp_sig_t *s) {
#ifdef __BIG_ENDIAN
#ifdef __CPU_IS_BIG_ENDIAN
return s;
#else
s->version = be32toh(s->version);
@@ -88,7 +88,7 @@ pcp_sig_t *sig2native(pcp_sig_t *s) {
}
pcp_sig_t *sig2be(pcp_sig_t *s) {
#ifdef __BIG_ENDIAN
#ifdef __CPU_IS_BIG_ENDIAN
return s;
#else
s->version = htobe32(s->version);