File pacemaker#3381-0001-Fix-libcrmcommon-use-uint32_t-for-32-bit-magic-numbe.patch of Package pacemaker.36842

From f964f4de46eb9719ac4d93971074573bec7b34b8 Mon Sep 17 00:00:00 2001
From: "Gao,Yan" <ygao@suse.com>
Date: Fri, 1 Mar 2024 17:36:17 +0100
Subject: [PATCH] Fix: libcrmcommon: use uint32_t for 32-bit magic numbers

So that they are correctly handled on 32-bit systems.

Previously unit test would fail on 32-bit systems:

  > lib/common/tests/xml/crm_xml_init_test
  TAP version 13
  1..8
  ok 1 - buffer_scheme_test
  not ok 2 - create_document_node
  # 0xffffffff81726354 != 0x81726354
  # crm_xml_init_test.c:61: error: Failure!
---
 lib/common/crmcommon_private.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/lib/common/crmcommon_private.h b/lib/common/crmcommon_private.h
index 3844dbed3..82b0fd9a5 100644
--- a/lib/common/crmcommon_private.h
+++ b/lib/common/crmcommon_private.h
@@ -38,12 +38,12 @@ typedef struct pcmk__deleted_xml_s {
 } pcmk__deleted_xml_t;
 
 typedef struct xml_node_private_s {
-        long check;
+        uint32_t check;
         uint32_t flags;
 } xml_node_private_t;
 
 typedef struct xml_doc_private_s {
-        long check;
+        uint32_t check;
         uint32_t flags;
         char *user;
         GList *acls;
-- 
2.35.3

openSUSE Build Service is sponsored by