]> git.proxmox.com Git - ceph.git/blobdiff - ceph/src/crypto/isa-l/isa-l_crypto/mh_sha1/mh_sha1_update_test.c
update ceph source to reef 18.1.2
[ceph.git] / ceph / src / crypto / isa-l / isa-l_crypto / mh_sha1 / mh_sha1_update_test.c
index 2b1b79179b2ab519c8965367378a6cdd8413479b..942dfd09fd818da4df451202de5947b3e2482978 100644 (file)
@@ -2,7 +2,7 @@
   Copyright(c) 2011-2016 Intel Corporation All rights reserved.
 
   Redistribution and use in source and binary forms, with or without
-  modification, are permitted provided that the following conditions 
+  modification, are permitted provided that the following conditions
   are met:
     * Redistributions of source code must retain the above copyright
       notice, this list of conditions and the following disclaimer.
@@ -80,22 +80,22 @@ void dump(char *buf, int len)
                printf("\n");
 }
 
-int compare_digests(uint32_t hash_base[SHA1_DIGEST_WORDS],
+int compare_digests(uint32_t hash_ref[SHA1_DIGEST_WORDS],
                    uint32_t hash_test[SHA1_DIGEST_WORDS])
 {
        int i;
        int mh_sha1_fail = 0;
 
        for (i = 0; i < SHA1_DIGEST_WORDS; i++) {
-               if (hash_test[i] != hash_base[i])
+               if (hash_test[i] != hash_ref[i])
                        mh_sha1_fail++;
        }
 
        if (mh_sha1_fail) {
                printf("mh_sha1 fail test\n");
-               printf("base: ");
-               dump((char *)hash_base, 20);
                printf("ref: ");
+               dump((char *)hash_ref, 20);
+               printf("test: ");
                dump((char *)hash_test, 20);
        }