Blame SOURCES/0044-Issue-4563-Failure-on-s390x-Fails-to-split-RDN-o-pki.patch

a458d3
From 7e042cbc74440b81f46efa73ccb36d80732c7074 Mon Sep 17 00:00:00 2001
a458d3
From: tbordaz <tbordaz@redhat.com>
a458d3
Date: Thu, 28 Jan 2021 10:39:31 +0100
a458d3
Subject: [PATCH] Issue 4563 - Failure on s390x: 'Fails to split RDN
a458d3
 "o=pki-tomcat-CA" into components' (#4573)
a458d3
a458d3
Bug description:
a458d3
	SLAPI_OPERATION_TYPE is a stored/read as an int (slapi_pblock_get/set).
a458d3
	This although the storage field is an unsigned long.
a458d3
	Calling slapi_pblock_get with an long (8 btyes) destination creates
a458d3
	a problem on big-endian (s390x).
a458d3
a458d3
Fix description:
a458d3
	Define destination op_type as an int (4 bytes)
a458d3
a458d3
relates: https://github.com/389ds/389-ds-base/issues/4563
a458d3
a458d3
Reviewed by: Mark Reynolds, William Brown
a458d3
a458d3
Platforms tested: F31 (little endian), Debian (big endian)
a458d3
---
a458d3
 ldap/servers/slapd/back-ldbm/ldbm_modify.c | 2 +-
a458d3
 1 file changed, 1 insertion(+), 1 deletion(-)
a458d3
a458d3
diff --git a/ldap/servers/slapd/back-ldbm/ldbm_modify.c b/ldap/servers/slapd/back-ldbm/ldbm_modify.c
a458d3
index a507f3c31..49ca01d1d 100644
a458d3
--- a/ldap/servers/slapd/back-ldbm/ldbm_modify.c
a458d3
+++ b/ldap/servers/slapd/back-ldbm/ldbm_modify.c
a458d3
@@ -216,7 +216,7 @@ error:
a458d3
 int32_t
a458d3
 entry_get_rdn_mods(Slapi_PBlock *pb, Slapi_Entry *entry, CSN *csn, int repl_op, Slapi_Mods **smods_ret)
a458d3
 {
a458d3
-    unsigned long op_type = SLAPI_OPERATION_NONE;
a458d3
+    int op_type = SLAPI_OPERATION_NONE;
a458d3
     char *new_rdn = NULL;
a458d3
     char **dns = NULL;
a458d3
     char **rdns = NULL;
a458d3
-- 
a458d3
2.31.1
a458d3