From 6c01f4c84f768b6c6b247a11106bf51b40015e66 Mon Sep 17 00:00:00 2001
From: Panu Matilainen <pmatilai@redhat.com>
Date: Mon, 18 Mar 2024 09:56:51 +0200
Subject: [PATCH] Fix an enum/int type mismatch in rpmfiArchiveReadToFilePsm()

rpmfiDigestAlgo() hysterically returns a signed int (and that's what
really ought to be changed) but lets at least make all these uses
consistent.

Conflict:modify pgpHashAlgo instead of rpmHashAlgo because
01d6605d93e9b5 is not mearged.
Reference:https://github.com/rpm-software-management/rpm/commit/6c01f4c84f768b6c6b247a11106bf51b40015e66

---
 lib/rpmfi.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/rpmfi.c b/lib/rpmfi.c
index cfb388b4c..db1460711 100644
--- a/lib/rpmfi.c
+++ b/lib/rpmfi.c
@@ -2384,7 +2384,7 @@ int rpmfiArchiveReadToFilePsm(rpmfi fi, FD_t fd, int nodigest, rpmpsm psm)
 
     rpm_loff_t left = rpmfiFSize(fi);
     const unsigned char * fidigest = NULL;
-    pgpHashAlgo digestalgo = 0;
+    int digestalgo = 0;
     int rc = 0;
     char buf[BUFSIZ*4];
 
-- 
2.33.0

