File replace-sha0.diff of Package ccgfs

From 4b5b69055886073ee95d768443febee94177f59b Mon Sep 17 00:00:00 2001
From: Jan Engelhardt <jengelh@inai.de>
Date: Mon, 4 Dec 2017 09:55:13 +0100
Subject: [PATCH] ccgfs: replace SHA0 by SHA1 to fix build error with OpenSSL
 1.1

OpenSSL 1.1.x removed SHA0 support. It was used by ccgfs only to find
duplicate config entries, so any hash function can be substituted.
---
 src/super.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/src/super.c b/src/super.c
index f406e79..955d6a0 100644
--- a/src/super.c
+++ b/src/super.c
@@ -497,10 +497,10 @@ static bool config_parse_subproc(struct HXclist_head *dq,
 	}
 
 	/* Calculate checksum and convert to vector */
-	SHA_Init(&ctx);
+	SHA1_Init(&ctx);
 	for (node = args->first; node != NULL; node = node->next)
-		SHA_Update(&ctx, node->ptr, strlen(node->ptr) + 1);
-	SHA_Final(subp->checksum, &ctx);
+		SHA1_Update(&ctx, node->ptr, strlen(node->ptr) + 1);
+	SHA1_Final(subp->checksum, &ctx);
 	subp->args = reinterpret_cast(char **, HXdeque_to_vec(args, NULL));
 	HXdeque_free(args);
 
-- 
2.15.0

openSUSE Build Service is sponsored by