[dpkg] 189/200: s-s-d: Use 5-argument kvm_getprocs() call form on OpenBSD

Ximin Luo infinity0 at debian.org
Wed Apr 5 15:17:39 UTC 2017


This is an automated email from the git hooks/post-receive script.

infinity0 pushed a commit to branch master
in repository dpkg.

commit 2283f64a899e73d5e9db15508083fe31e995c4e1
Author: Guillem Jover <guillem at debian.org>
Date:   Sat Feb 11 22:37:52 2017 +0100

    s-s-d: Use 5-argument kvm_getprocs() call form on OpenBSD
---
 debian/changelog          | 1 +
 utils/start-stop-daemon.c | 4 ++++
 2 files changed, 5 insertions(+)

diff --git a/debian/changelog b/debian/changelog
index 178c395..50fe9b8 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -8,6 +8,7 @@ dpkg (1.18.23) UNRELEASED; urgency=medium
       Thanks to Thomas Klausner <wiz at NetBSD.org>.
     - Rename err variable to ret in start-stop-daemon as the former is a
       function on BSDs.
+    - Use 5-argument kvm_getprocs() call form on OpenBSD in start-stop-daemon.
   * Perl modules:
     - Do not special case EM_SPARC32PLUS for NetBSD in Dpkg::Shlibs::Objdump,
       the code has been fixed in NetBSD as that situation could not happen.
diff --git a/utils/start-stop-daemon.c b/utils/start-stop-daemon.c
index 976ec72..6e6693a 100644
--- a/utils/start-stop-daemon.c
+++ b/utils/start-stop-daemon.c
@@ -1356,7 +1356,11 @@ ssd_kvm_get_procs(kvm_t *kd, int op, int arg, int *count)
 		count = &lcount;
 	*count = 0;
 
+#if defined(OS_OpenBSD)
+	kp = kvm_getprocs(kd, op, arg, sizeof(*kp), count);
+#else
 	kp = kvm_getprocs(kd, op, arg, count);
+#endif
 	if (kp == NULL && errno != ESRCH)
 		errx(1, "%s", kvm_geterr(kd));
 

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/reproducible/dpkg.git



More information about the Reproducible-commits mailing list