diff options
author | Andrew Tridgell <tridge@samba.org> | 2010-03-29 22:47:34 +1100 |
---|---|---|
committer | Andrew Tridgell <tridge@samba.org> | 2010-03-30 12:31:03 +1100 |
commit | e4c75252a962341c35ef45989ea12c637f7b3a1b (patch) | |
tree | 59eaa9f0a5f79cf550906afc3e7aa6ee5e5d0edf /source4/heimdal_build | |
parent | 0cdc021ba4cc0f400e6fbce173e0d17dee69ee64 (diff) | |
download | samba-e4c75252a962341c35ef45989ea12c637f7b3a1b.tar.gz samba-e4c75252a962341c35ef45989ea12c637f7b3a1b.tar.bz2 samba-e4c75252a962341c35ef45989ea12c637f7b3a1b.zip |
s4-heimdal: a better way of handling dirfd()
This prevents us getting thousands of warnings about dirfd() on
solaris
Diffstat (limited to 'source4/heimdal_build')
-rw-r--r-- | source4/heimdal_build/config.h | 4 | ||||
-rw-r--r-- | source4/heimdal_build/roken.h | 9 |
2 files changed, 9 insertions, 4 deletions
diff --git a/source4/heimdal_build/config.h b/source4/heimdal_build/config.h index be544cb83b..35981b85d2 100644 --- a/source4/heimdal_build/config.h +++ b/source4/heimdal_build/config.h @@ -9,10 +9,6 @@ #include "include/config.h" #include "../replace/replace.h" -#if !defined(HAVE_DIRFD) && !defined(HAVE_DIRFD_DECL) && !defined(dirfd) -#define dirfd(d) (-1) -#endif - #define RCSID(msg) struct __rcsid { int __rcsdi; } #define KRB5 diff --git a/source4/heimdal_build/roken.h b/source4/heimdal_build/roken.h index 172dc76a29..d8c49fb688 100644 --- a/source4/heimdal_build/roken.h +++ b/source4/heimdal_build/roken.h @@ -119,6 +119,15 @@ #define STRERROR_R_PROTO_COMPATIBLE #endif +#ifndef HAVE_DIRFD +#ifdef HAVE_DIR_DD_FD +#define dirfd(x) ((x)->dd_fd) +#else +#define dirfd(d) (-1) +#endif +#define HAVE_DIRFD 1 +#endif + /* we lie about having pidfile() so that NetBSD5 can compile. Nothing in the parts of heimdal we use actually uses pidfile(), and we |