From 716ca530e1c4515d8683c9d5be3d56b301758b66 Mon Sep 17 00:00:00 2001 From: James <> Date: Wed, 4 Nov 2015 11:49:21 +0000 Subject: trunk-47381 --- .../utils/xfsprogs/patches/120-portability.patch | 47 ++++++++++++++++++++++ 1 file changed, 47 insertions(+) create mode 100644 package/utils/xfsprogs/patches/120-portability.patch (limited to 'package/utils/xfsprogs/patches/120-portability.patch') diff --git a/package/utils/xfsprogs/patches/120-portability.patch b/package/utils/xfsprogs/patches/120-portability.patch new file mode 100644 index 0000000..1e9b533 --- /dev/null +++ b/package/utils/xfsprogs/patches/120-portability.patch @@ -0,0 +1,47 @@ +commit d2aef8b3967e53fe58178f5af50fef488ee0faed +Author: Jens Muecke +Date: Thu Jan 26 00:37:52 2012 +0100 + + 120-portability + +diff --git a/copy/xfs_copy.c b/copy/xfs_copy.c +index c01e0b9..2e2f320 100644 +--- a/copy/xfs_copy.c ++++ b/copy/xfs_copy.c +@@ -463,6 +463,15 @@ read_ag_header(int fd, xfs_agnumber_t agno, wbuf *buf, ag_header_t *ag, + } + + ++static void sig_mask(int type) ++{ ++ sigset_t mask; ++ sigemptyset(&mask); ++ sigaddset(&mask, SIGCHLD); ++ sigprocmask(type, &mask, NULL); ++} ++ ++ + void + write_wbuf(void) + { +@@ -478,9 +487,9 @@ write_wbuf(void) + if (target[i].state != INACTIVE) + pthread_mutex_unlock(&targ[i].wait); /* wake up */ + +- sigrelse(SIGCHLD); ++ sig_mask(SIG_UNBLOCK); + pthread_mutex_lock(&mainwait); +- sighold(SIGCHLD); ++ sig_mask(SIG_BLOCK); + } + + +@@ -847,7 +856,7 @@ main(int argc, char **argv) + /* set up sigchild signal handler */ + + signal(SIGCHLD, handler); +- sighold(SIGCHLD); ++ sig_mask(SIG_BLOCK); + + /* make children */ + -- cgit v1.2.3