summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoe Orton <jorton@redhat.com>2020-04-17 15:28:16 +0100
committerJoe Orton <jorton@redhat.com>2020-04-17 15:28:16 +0100
commit445d1f5655fccaca91b1a16c5db1dcda2bfb54c0 (patch)
tree3e2021a87dab0dac7fb512bbaeac37b65c32c506
parent893b22035de2f34af478df11f837738a315429cb (diff)
downloadneon-git-445d1f5655fccaca91b1a16c5db1dcda2bfb54c0.tar.gz
* src/ne_md5.c (md5_read_ctx): Fix for big-endian platforms.
-rw-r--r--.travis.yml3
-rw-r--r--src/ne_md5.c4
2 files changed, 5 insertions, 2 deletions
diff --git a/.travis.yml b/.travis.yml
index ccc9209..52f0426 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -49,6 +49,9 @@ matrix:
- name: OpenSSL on arm64
arch: arm64
env: CONF="--with-ssl=openssl"
+ - name: OpenSSL on s390x
+ arch: s390x
+ env: CONF="--with-ssl=openssl"
- name: OpenSSL on trusty
dist: trusty
env: CONF="--with-ssl=openssl"
diff --git a/src/ne_md5.c b/src/ne_md5.c
index f07041c..2a8458e 100644
--- a/src/ne_md5.c
+++ b/src/ne_md5.c
@@ -426,9 +426,9 @@ void *
md5_read_ctx (const struct md5_ctx *ctx, void *resbuf)
{
#ifdef HAVE_OPENSSL
-#define SWAP_CTX(x) (ctx->ctx.x)
+#define SWAP_CTX(x) SWAP(ctx->ctx.x)
#else
-#define SWAP_CTX(x) (ctx->x)
+#define SWAP_CTX(x) SWAP(ctx->x)
#endif
((md5_uint32 *) resbuf)[0] = SWAP_CTX (A);