Home GnuPG
Diffusion GnuPG f7f806afa508

agent: Fix get_client_pid for portability.
f7f806afa508Unpublished

Unpublished Commit · Learn More

Not On Permanent Ref: This commit is not an ancestor of any permanent ref.

Description

agent: Fix get_client_pid for portability.

* configure.ac: Simply check getpeerucred and ucred.h, and structure
members.
* agent/command-ssh.c: Include ucred.h.
(get_client_pid) [HAVE_STRUCT_SOCKPEERCRED_PID]: Use sockpeercred
structure for OpenBSD.
[LOCAL_PEERPID]: Use LOCAL_PEERPID for macOS.
[LOCAL_PEEREID]: Use LOCAL_PEEREID for NetBSD.
[HAVE_GETPEERUCRED]: Use getpeerucred for OpenSolaris.

This change also addresses following bug.

  • GnuPG-bug-id: T2981.
  • Signed-off-by: NIIBE Yutaka <gniibe@fsij.org>

Details

Provenance
gniibeAuthored on Mar 7 2017, 6:01 AM
Parents
rGb9ab733fc0dd: common: Fix warning for portability.
Branches
Unknown
Tags
Unknown