summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog2
-rw-r--r--openbsd-compat/bsd-misc.c5
2 files changed, 6 insertions, 1 deletions
diff --git a/ChangeLog b/ChangeLog
index 88e4fe267..8dd37b2c0 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -8,6 +8,8 @@
8 platforms that don't have it. 8 platforms that don't have it.
9 - (dtucker) [openbsd-compat/openbsd-compat.h] Add prototype for strtoul, 9 - (dtucker) [openbsd-compat/openbsd-compat.h] Add prototype for strtoul,
10 group strto* function prototypes together. 10 group strto* function prototypes together.
11 - (dtucker) [openbsd-compat/bsd-misc.c] Handle the case where setpgrp() takes
12 an argument. Pointed out by djm.
11 - (djm) OpenBSD CVS Sync 13 - (djm) OpenBSD CVS Sync
12 - djm@cvs.openbsd.org 2013/02/14 21:35:59 14 - djm@cvs.openbsd.org 2013/02/14 21:35:59
13 [auth2-pubkey.c] 15 [auth2-pubkey.c]
diff --git a/openbsd-compat/bsd-misc.c b/openbsd-compat/bsd-misc.c
index ad524b8b7..8dc7d02d1 100644
--- a/openbsd-compat/bsd-misc.c
+++ b/openbsd-compat/bsd-misc.c
@@ -253,10 +253,13 @@ isblank(int c)
253pid_t 253pid_t
254getpgid(pid_t pid) 254getpgid(pid_t pid)
255{ 255{
256#ifdef HAVE_GETPGRP 256#if defined(HAVE_GETPGRP) && !defined(GETPGRP_VOID)
257 return getpgrp(pid);
258#elif defined(HAVE_GETPGRP)
257 if (pid == 0) 259 if (pid == 0)
258 return getpgrp(); 260 return getpgrp();
259#endif 261#endif
262
260 errno = ESRCH; 263 errno = ESRCH;
261 return -1; 264 return -1;
262} 265}