summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorPaul Eggert <eggert@cs.ucla.edu>2010-06-14 12:20:22 -0700
committerPaul Eggert <eggert@cs.ucla.edu>2010-06-14 12:20:22 -0700
commit823b6cf1431f71d7b5f939830444771d23346e66 (patch)
treea3739a1201a35c27acbb1bd0f656b617682ff5d1 /lib
parent682a983ba6ec26161cf2b5c2d71830cf2928ad26 (diff)
downloadgnulib-823b6cf1431f71d7b5f939830444771d23346e66.tar.gz
priv-set: Don't assume that priv.h exists merely because getppriv does.
See Jan Andersen's bug report about AIX 5L in http://lists.gnu.org/archive/html/bug-tar/2010-06/msg00019.html * m4/priv-set.m4 (gl_PRIV_SET): Check for priv.h. * lib/priv-set.c: Do nothing unless HAVE_PRIV_H. * lib/priv-set.h: Likewise. * tests/test-priv-set.c: Likewise.
Diffstat (limited to 'lib')
-rw-r--r--lib/priv-set.c2
-rw-r--r--lib/priv-set.h2
2 files changed, 2 insertions, 2 deletions
diff --git a/lib/priv-set.c b/lib/priv-set.c
index 911c28000f..0ac1b977e2 100644
--- a/lib/priv-set.c
+++ b/lib/priv-set.c
@@ -20,7 +20,7 @@
#include <config.h>
#include "priv-set.h"
-#if HAVE_GETPPRIV
+#if HAVE_GETPPRIV && HAVE_PRIV_H
# include <errno.h>
# include <stdbool.h>
diff --git a/lib/priv-set.h b/lib/priv-set.h
index b8f8b72723..5cac9cedec 100644
--- a/lib/priv-set.h
+++ b/lib/priv-set.h
@@ -17,7 +17,7 @@
Written by David Bartley. */
-#if HAVE_GETPPRIV
+#if HAVE_GETPPRIV && HAVE_PRIV_H
# include <priv.h>