rpm/0001-build-Limit-copying-ch...

29 lines
896 B
Diff

From 8aab33f69c9d78b6d4d4e79ba661ae01cd970f2b Mon Sep 17 00:00:00 2001
From: Igor Gnatenko <i.gnatenko.brain@gmail.com>
Date: Tue, 11 Jun 2019 14:22:07 +0200
Subject: [PATCH] build: Limit copying changelog one at a time
Getting header content in multiple threads is causing problems since it
can (and apparently does) change internal state.
Signed-off-by: Igor Gnatenko <i.gnatenko.brain@gmail.com>
---
build/pack.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/build/pack.c b/build/pack.c
index ab72750be..e6cec1816 100644
--- a/build/pack.c
+++ b/build/pack.c
@@ -713,6 +713,7 @@ static rpmRC packageBinary(rpmSpec spec, Package pkg, const char *cookie, int ch
}
/* Copy changelog from src rpm */
+ #pragma omp critical
headerCopyTags(spec->sourcePackage->header, pkg->header, copyTags);
headerPutString(pkg->header, RPMTAG_RPMVERSION, VERSION);
--
2.22.0