summaryrefslogtreecommitdiff
path: root/source3
diff options
context:
space:
mode:
Diffstat (limited to 'source3')
-rwxr-xr-xsource3/configure462
-rw-r--r--source3/configure.in3
-rw-r--r--source3/include/config.h.in6
-rw-r--r--source3/include/includes.h45
-rw-r--r--source3/include/proto.h12
-rw-r--r--source3/include/smb.h53
-rw-r--r--source3/lib/util.c93
-rw-r--r--source3/locking/locking.c6
-rw-r--r--source3/locking/locking_shm.c24
-rw-r--r--source3/locking/locking_slow.c16
-rw-r--r--source3/smbd/close.c4
-rw-r--r--source3/smbd/files.c10
-rw-r--r--source3/smbd/open.c23
-rw-r--r--source3/smbd/oplock.c25
-rw-r--r--source3/smbd/reply.c4
-rw-r--r--source3/smbd/trans2.c5
16 files changed, 455 insertions, 336 deletions
diff --git a/source3/configure b/source3/configure
index cdb900b7ee..b576f02642 100755
--- a/source3/configure
+++ b/source3/configure
@@ -1413,7 +1413,7 @@ else
fi
done
-for ac_hdr in unistd.h utime.h grp.h sys/id.h limits.h memory.h net/if.h compat.h
+for ac_hdr in unistd.h utime.h grp.h sys/id.h limits.h memory.h net/if.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
@@ -1453,7 +1453,7 @@ else
fi
done
-for ac_hdr in rpc/types.h rpc/xdr.h rpc/auth.h rpc/clnt.h rpcsvc/yp_prot.h rpcsvc/ypclnt.h
+for ac_hdr in compat.h rpc/types.h rpc/xdr.h rpc/auth.h rpc/clnt.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
@@ -1493,7 +1493,7 @@ else
fi
done
-for ac_hdr in sys/param.h ctype.h sys/wait.h sys/resource.h sys/ioctl.h
+for ac_hdr in rpcsvc/yp_prot.h rpcsvc/ypclnt.h sys/param.h ctype.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
@@ -1533,7 +1533,7 @@ else
fi
done
-for ac_hdr in sys/mode.h sys/filio.h string.h strings.h stdlib.h sys/socket.h
+for ac_hdr in sys/wait.h sys/resource.h sys/ioctl.h sys/mode.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
@@ -1573,7 +1573,7 @@ else
fi
done
-for ac_hdr in sys/mount.h sys/vfs.h sys/fs/s5param.h sys/filsys.h termios.h
+for ac_hdr in sys/filio.h string.h strings.h stdlib.h sys/socket.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
@@ -1613,7 +1613,7 @@ else
fi
done
-for ac_hdr in sys/statfs.h sys/dustat.h sys/statvfs.h stdarg.h sys/sockio.h
+for ac_hdr in sys/mount.h sys/vfs.h sys/fs/s5param.h sys/filsys.h termios.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
@@ -1653,7 +1653,7 @@ else
fi
done
-for ac_hdr in shadow.h netinet/tcp.h sys/security.h security/pam_appl.h
+for ac_hdr in sys/statfs.h sys/dustat.h sys/statvfs.h stdarg.h sys/sockio.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
@@ -1693,9 +1693,89 @@ else
fi
done
+for ac_hdr in shadow.h netinet/tcp.h sys/security.h security/pam_appl.h
+do
+ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
+echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
+echo "configure:1701: checking for $ac_hdr" >&5
+if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ cat > conftest.$ac_ext <<EOF
+#line 1706 "configure"
+#include "confdefs.h"
+#include <$ac_hdr>
+EOF
+ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
+{ (eval echo configure:1711: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+ac_err=`grep -v '^ *+' conftest.out`
+if test -z "$ac_err"; then
+ rm -rf conftest*
+ eval "ac_cv_header_$ac_safe=yes"
+else
+ echo "$ac_err" >&5
+ echo "configure: failed program was:" >&5
+ cat conftest.$ac_ext >&5
+ rm -rf conftest*
+ eval "ac_cv_header_$ac_safe=no"
+fi
+rm -f conftest*
+fi
+if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
+ echo "$ac_t""yes" 1>&6
+ ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
+ cat >> confdefs.h <<EOF
+#define $ac_tr_hdr 1
+EOF
+
+else
+ echo "$ac_t""no" 1>&6
+fi
+done
+
+for ac_hdr in stropts.h poll.h
+do
+ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
+echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
+echo "configure:1741: checking for $ac_hdr" >&5
+if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
+ echo $ac_n "(cached) $ac_c" 1>&6
+else
+ cat > conftest.$ac_ext <<EOF
+#line 1746 "configure"
+#include "confdefs.h"
+#include <$ac_hdr>
+EOF
+ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
+{ (eval echo configure:1751: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
+ac_err=`grep -v '^ *+' conftest.out`
+if test -z "$ac_err"; then
+ rm -rf conftest*
+ eval "ac_cv_header_$ac_safe=yes"
+else
+ echo "$ac_err" >&5
+ echo "configure: failed program was:" >&5
+ cat conftest.$ac_ext >&5
+ rm -rf conftest*
+ eval "ac_cv_header_$ac_safe=no"
+fi
+rm -f conftest*
+fi
+if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
+ echo "$ac_t""yes" 1>&6
+ ac_tr_hdr=HAVE_`echo $ac_hdr | sed 'y%abcdefghijklmnopqrstuvwxyz./-%ABCDEFGHIJKLMNOPQRSTUVWXYZ___%'`
+ cat >> confdefs.h <<EOF
+#define $ac_tr_hdr 1
+EOF
+
+else
+ echo "$ac_t""no" 1>&6
+fi
+done
+
echo $ac_n "checking size of int""... $ac_c" 1>&6
-echo "configure:1699: checking size of int" >&5
+echo "configure:1779: checking size of int" >&5
if eval "test \"`echo '$''{'ac_cv_sizeof_int'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1703,7 +1783,7 @@ else
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 1707 "configure"
+#line 1787 "configure"
#include "confdefs.h"
#include <stdio.h>
main()
@@ -1714,7 +1794,7 @@ main()
exit(0);
}
EOF
-if { (eval echo configure:1718: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:1798: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
then
ac_cv_sizeof_int=`cat conftestval`
else
@@ -1734,7 +1814,7 @@ EOF
echo $ac_n "checking size of long""... $ac_c" 1>&6
-echo "configure:1738: checking size of long" >&5
+echo "configure:1818: checking size of long" >&5
if eval "test \"`echo '$''{'ac_cv_sizeof_long'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1742,7 +1822,7 @@ else
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 1746 "configure"
+#line 1826 "configure"
#include "confdefs.h"
#include <stdio.h>
main()
@@ -1753,7 +1833,7 @@ main()
exit(0);
}
EOF
-if { (eval echo configure:1757: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:1837: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
then
ac_cv_sizeof_long=`cat conftestval`
else
@@ -1773,7 +1853,7 @@ EOF
echo $ac_n "checking size of short""... $ac_c" 1>&6
-echo "configure:1777: checking size of short" >&5
+echo "configure:1857: checking size of short" >&5
if eval "test \"`echo '$''{'ac_cv_sizeof_short'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -1781,7 +1861,7 @@ else
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 1785 "configure"
+#line 1865 "configure"
#include "confdefs.h"
#include <stdio.h>
main()
@@ -1792,7 +1872,7 @@ main()
exit(0);
}
EOF
-if { (eval echo configure:1796: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:1876: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
then
ac_cv_sizeof_short=`cat conftestval`
else
@@ -1813,12 +1893,12 @@ EOF
echo $ac_n "checking for working const""... $ac_c" 1>&6
-echo "configure:1817: checking for working const" >&5
+echo "configure:1897: checking for working const" >&5
if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 1822 "configure"
+#line 1902 "configure"
#include "confdefs.h"
int main() {
@@ -1867,7 +1947,7 @@ ccp = (char const *const *) p;
; return 0; }
EOF
-if { (eval echo configure:1871: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1951: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_const=yes
else
@@ -1888,21 +1968,21 @@ EOF
fi
echo $ac_n "checking for inline""... $ac_c" 1>&6
-echo "configure:1892: checking for inline" >&5
+echo "configure:1972: checking for inline" >&5
if eval "test \"`echo '$''{'ac_cv_c_inline'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_c_inline=no
for ac_kw in inline __inline__ __inline; do
cat > conftest.$ac_ext <<EOF
-#line 1899 "configure"
+#line 1979 "configure"
#include "confdefs.h"
int main() {
} $ac_kw foo() {
; return 0; }
EOF
-if { (eval echo configure:1906: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:1986: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_inline=$ac_kw; break
else
@@ -1928,14 +2008,14 @@ EOF
esac
echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6
-echo "configure:1932: checking whether byte ordering is bigendian" >&5
+echo "configure:2012: checking whether byte ordering is bigendian" >&5
if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_c_bigendian=unknown
# See if sys/param.h defines the BYTE_ORDER macro.
cat > conftest.$ac_ext <<EOF
-#line 1939 "configure"
+#line 2019 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/param.h>
@@ -1946,11 +2026,11 @@ int main() {
#endif
; return 0; }
EOF
-if { (eval echo configure:1950: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:2030: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
# It does; now see whether it defined to BIG_ENDIAN or not.
cat > conftest.$ac_ext <<EOF
-#line 1954 "configure"
+#line 2034 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/param.h>
@@ -1961,7 +2041,7 @@ int main() {
#endif
; return 0; }
EOF
-if { (eval echo configure:1965: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:2045: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_bigendian=yes
else
@@ -1981,7 +2061,7 @@ if test "$cross_compiling" = yes; then
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 1985 "configure"
+#line 2065 "configure"
#include "confdefs.h"
main () {
/* Are we little or big endian? From Harbison&Steele. */
@@ -1994,7 +2074,7 @@ main () {
exit (u.c[sizeof (long) - 1] == 1);
}
EOF
-if { (eval echo configure:1998: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:2078: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
then
ac_cv_c_bigendian=no
else
@@ -2018,14 +2098,14 @@ EOF
fi
echo $ac_n "checking whether char is unsigned""... $ac_c" 1>&6
-echo "configure:2022: checking whether char is unsigned" >&5
+echo "configure:2102: checking whether char is unsigned" >&5
if eval "test \"`echo '$''{'ac_cv_c_char_unsigned'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
if test "$GCC" = yes; then
# GCC predefines this symbol on systems where it applies.
cat > conftest.$ac_ext <<EOF
-#line 2029 "configure"
+#line 2109 "configure"
#include "confdefs.h"
#ifdef __CHAR_UNSIGNED__
yes
@@ -2047,7 +2127,7 @@ if test "$cross_compiling" = yes; then
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 2051 "configure"
+#line 2131 "configure"
#include "confdefs.h"
/* volatile prevents gcc2 from optimizing the test away on sparcs. */
#if !defined(__STDC__) || __STDC__ != 1
@@ -2057,7 +2137,7 @@ main() {
volatile char c = 255; exit(c < 0);
}
EOF
-if { (eval echo configure:2061: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:2141: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
then
ac_cv_c_char_unsigned=yes
else
@@ -2082,12 +2162,12 @@ fi
echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6
-echo "configure:2086: checking return type of signal handlers" >&5
+echo "configure:2166: checking return type of signal handlers" >&5
if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2091 "configure"
+#line 2171 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <signal.h>
@@ -2104,7 +2184,7 @@ int main() {
int i;
; return 0; }
EOF
-if { (eval echo configure:2108: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:2188: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_type_signal=void
else
@@ -2123,12 +2203,12 @@ EOF
echo $ac_n "checking for uid_t in sys/types.h""... $ac_c" 1>&6
-echo "configure:2127: checking for uid_t in sys/types.h" >&5
+echo "configure:2207: checking for uid_t in sys/types.h" >&5
if eval "test \"`echo '$''{'ac_cv_type_uid_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2132 "configure"
+#line 2212 "configure"
#include "confdefs.h"
#include <sys/types.h>
EOF
@@ -2157,12 +2237,12 @@ EOF
fi
echo $ac_n "checking for mode_t""... $ac_c" 1>&6
-echo "configure:2161: checking for mode_t" >&5
+echo "configure:2241: checking for mode_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_mode_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2166 "configure"
+#line 2246 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
@@ -2190,12 +2270,12 @@ EOF
fi
echo $ac_n "checking for off_t""... $ac_c" 1>&6
-echo "configure:2194: checking for off_t" >&5
+echo "configure:2274: checking for off_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_off_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2199 "configure"
+#line 2279 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
@@ -2223,12 +2303,12 @@ EOF
fi
echo $ac_n "checking for size_t""... $ac_c" 1>&6
-echo "configure:2227: checking for size_t" >&5
+echo "configure:2307: checking for size_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2232 "configure"
+#line 2312 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
@@ -2256,12 +2336,12 @@ EOF
fi
echo $ac_n "checking for pid_t""... $ac_c" 1>&6
-echo "configure:2260: checking for pid_t" >&5
+echo "configure:2340: checking for pid_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_pid_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2265 "configure"
+#line 2345 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
@@ -2289,12 +2369,12 @@ EOF
fi
echo $ac_n "checking for st_rdev in struct stat""... $ac_c" 1>&6
-echo "configure:2293: checking for st_rdev in struct stat" >&5
+echo "configure:2373: checking for st_rdev in struct stat" >&5
if eval "test \"`echo '$''{'ac_cv_struct_st_rdev'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2298 "configure"
+#line 2378 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/stat.h>
@@ -2302,7 +2382,7 @@ int main() {
struct stat s; s.st_rdev;
; return 0; }
EOF
-if { (eval echo configure:2306: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:2386: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_struct_st_rdev=yes
else
@@ -2323,12 +2403,12 @@ EOF
fi
echo $ac_n "checking for ino_t""... $ac_c" 1>&6
-echo "configure:2327: checking for ino_t" >&5
+echo "configure:2407: checking for ino_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_ino_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2332 "configure"
+#line 2412 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
@@ -2358,14 +2438,14 @@ fi
echo $ac_n "checking for errno in errno.h... $ac_c"
cat > conftest.$ac_ext <<EOF
-#line 2362 "configure"
+#line 2442 "configure"
#include "confdefs.h"
#include <errno.h>
int main() {
int i = errno
; return 0; }
EOF
-if { (eval echo configure:2369: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:2449: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
echo yes; cat >> confdefs.h <<\EOF
#define HAVE_ERRNO_DECL 1
@@ -2382,14 +2462,14 @@ rm -f conftest*
# stupid glibc has the functions but no declaration. grrrr.
echo $ac_n "checking for setresuid declaration $ac_c"
cat > conftest.$ac_ext <<EOF
-#line 2386 "configure"
+#line 2466 "configure"
#include "confdefs.h"
#include <unistd.h>
int main() {
int i = setresuid
; return 0; }
EOF
-if { (eval echo configure:2393: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:2473: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
echo yes; cat >> confdefs.h <<\EOF
#define HAVE_SETRESUID_DECL 1
@@ -2410,12 +2490,12 @@ if test "$cross_compiling" = yes; then
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 2414 "configure"
+#line 2494 "configure"
#include "confdefs.h"
#include <errno.h>
main() { setresuid(1,1,1); setresuid(2,2,2); exit(errno==EPERM?0:1);}
EOF
-if { (eval echo configure:2419: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:2499: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
then
echo yes;cat >> confdefs.h <<\EOF
#define HAVE_SETRESUID 1
@@ -2433,7 +2513,7 @@ fi
echo $ac_n "checking for 8-bit clean memcmp""... $ac_c" 1>&6
-echo "configure:2437: checking for 8-bit clean memcmp" >&5
+echo "configure:2517: checking for 8-bit clean memcmp" >&5
if eval "test \"`echo '$''{'ac_cv_func_memcmp_clean'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -2441,7 +2521,7 @@ else
ac_cv_func_memcmp_clean=no
else
cat > conftest.$ac_ext <<EOF
-#line 2445 "configure"
+#line 2525 "configure"
#include "confdefs.h"
main()
@@ -2451,7 +2531,7 @@ main()
}
EOF
-if { (eval echo configure:2455: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:2535: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
then
ac_cv_func_memcmp_clean=yes
else
@@ -2473,7 +2553,7 @@ test $ac_cv_func_memcmp_clean = no && LIBOBJS="$LIBOBJS memcmp.o"
# test for where we get crypt() from
if test "$ac_cv_lib_crypt_crypt" = "yes"; then
echo $ac_n "checking for crypt in -lcrypt""... $ac_c" 1>&6
-echo "configure:2477: checking for crypt in -lcrypt" >&5
+echo "configure:2557: checking for crypt in -lcrypt" >&5
ac_lib_var=`echo crypt'_'crypt | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -2481,7 +2561,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lcrypt $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 2485 "configure"
+#line 2565 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -2492,7 +2572,7 @@ int main() {
crypt()
; return 0; }
EOF
-if { (eval echo configure:2496: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:2576: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -2528,12 +2608,12 @@ if test "$ac_cv_lib_crypt_crypt" = "no" ||
test "$ac_cv_lib_crypt_crypt" = ""; then
# look for crypt
echo $ac_n "checking for crypt""... $ac_c" 1>&6
-echo "configure:2532: checking for crypt" >&5
+echo "configure:2612: checking for crypt" >&5
if eval "test \"`echo '$''{'ac_cv_func_crypt'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2537 "configure"
+#line 2617 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char crypt(); below. */
@@ -2556,7 +2636,7 @@ crypt();
; return 0; }
EOF
-if { (eval echo configure:2560: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:2640: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
rm -rf conftest*
eval "ac_cv_func_crypt=yes"
else
@@ -2579,7 +2659,7 @@ else
case "$LIBS" in
*-lcrypt*) ;;
*) echo $ac_n "checking for crypt in -lcrypt""... $ac_c" 1>&6
-echo "configure:2583: checking for crypt in -lcrypt" >&5
+echo "configure:2663: checking for crypt in -lcrypt" >&5
ac_lib_var=`echo crypt'_'crypt | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -2587,7 +2667,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lcrypt $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 2591 "configure"
+#line 2671 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -2598,7 +2678,7 @@ int main() {
crypt()
; return 0; }
EOF
-if { (eval echo configure:2602: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:2682: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -2643,21 +2723,21 @@ fi
# might need libdl for this to work
if test "$ac_cv_header_security_pam_appl_h" = "yes"; then
echo $ac_n "checking for -ldl""... $ac_c" 1>&6
-echo "configure:2647: checking for -ldl" >&5
+echo "configure:2727: checking for -ldl" >&5
if eval "test \"`echo '$''{'ac_cv_lib_dl'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_save_LIBS="$LIBS"
LIBS="-ldl $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 2654 "configure"
+#line 2734 "configure"
#include "confdefs.h"
int main() {
main()
; return 0; }
EOF
-if { (eval echo configure:2661: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:2741: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
rm -rf conftest*
ac_cv_lib_dl=yes
else
@@ -2683,7 +2763,7 @@ fi
fi
if test "$ac_cv_lib_pam_pam_authenticate" = "yes"; then
echo $ac_n "checking for pam_authenticate in -lpam""... $ac_c" 1>&6
-echo "configure:2687: checking for pam_authenticate in -lpam" >&5
+echo "configure:2767: checking for pam_authenticate in -lpam" >&5
ac_lib_var=`echo pam'_'pam_authenticate | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -2691,7 +2771,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lpam $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 2695 "configure"
+#line 2775 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -2702,7 +2782,7 @@ int main() {
pam_authenticate()
; return 0; }
EOF
-if { (eval echo configure:2706: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:2786: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -2738,12 +2818,12 @@ if test "$ac_cv_lib_pam_pam_authenticate" = "no" ||
test "$ac_cv_lib_pam_pam_authenticate" = ""; then
# look for pam_authenticate
echo $ac_n "checking for pam_authenticate""... $ac_c" 1>&6
-echo "configure:2742: checking for pam_authenticate" >&5
+echo "configure:2822: checking for pam_authenticate" >&5
if eval "test \"`echo '$''{'ac_cv_func_pam_authenticate'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2747 "configure"
+#line 2827 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char pam_authenticate(); below. */
@@ -2766,7 +2846,7 @@ pam_authenticate();
; return 0; }
EOF
-if { (eval echo configure:2770: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:2850: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
rm -rf conftest*
eval "ac_cv_func_pam_authenticate=yes"
else
@@ -2789,7 +2869,7 @@ else
case "$LIBS" in
*-lpam*) ;;
*) echo $ac_n "checking for pam_authenticate in -lpam""... $ac_c" 1>&6
-echo "configure:2793: checking for pam_authenticate in -lpam" >&5
+echo "configure:2873: checking for pam_authenticate in -lpam" >&5
ac_lib_var=`echo pam'_'pam_authenticate | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -2797,7 +2877,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lpam $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 2801 "configure"
+#line 2881 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -2808,7 +2888,7 @@ int main() {
pam_authenticate()
; return 0; }
EOF
-if { (eval echo configure:2812: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:2892: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -2854,12 +2934,12 @@ fi
# only looks in /etc/hosts), so we only look for -lsocket if we need
# it.
echo $ac_n "checking for connect""... $ac_c" 1>&6
-echo "configure:2858: checking for connect" >&5
+echo "configure:2938: checking for connect" >&5
if eval "test \"`echo '$''{'ac_cv_func_connect'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 2863 "configure"
+#line 2943 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char connect(); below. */
@@ -2882,7 +2962,7 @@ connect();
; return 0; }
EOF
-if { (eval echo configure:2886: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:2966: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
rm -rf conftest*
eval "ac_cv_func_connect=yes"
else
@@ -2902,7 +2982,7 @@ else
case "$LIBS" in
*-lnsl*) ;;
*) echo $ac_n "checking for printf in -lnsl_s""... $ac_c" 1>&6
-echo "configure:2906: checking for printf in -lnsl_s" >&5
+echo "configure:2986: checking for printf in -lnsl_s" >&5
ac_lib_var=`echo nsl_s'_'printf | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -2910,7 +2990,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lnsl_s $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 2914 "configure"
+#line 2994 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -2921,7 +3001,7 @@ int main() {
printf()
; return 0; }
EOF
-if { (eval echo configure:2925: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:3005: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -2952,7 +3032,7 @@ esac
case "$LIBS" in
*-lnsl*) ;;
*) echo $ac_n "checking for printf in -lnsl""... $ac_c" 1>&6
-echo "configure:2956: checking for printf in -lnsl" >&5
+echo "configure:3036: checking for printf in -lnsl" >&5
ac_lib_var=`echo nsl'_'printf | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -2960,7 +3040,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lnsl $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 2964 "configure"
+#line 3044 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -2971,7 +3051,7 @@ int main() {
printf()
; return 0; }
EOF
-if { (eval echo configure:2975: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:3055: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -3002,7 +3082,7 @@ esac
case "$LIBS" in
*-lsocket*) ;;
*) echo $ac_n "checking for connect in -lsocket""... $ac_c" 1>&6
-echo "configure:3006: checking for connect in -lsocket" >&5
+echo "configure:3086: checking for connect in -lsocket" >&5
ac_lib_var=`echo socket'_'connect | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -3010,7 +3090,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lsocket $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 3014 "configure"
+#line 3094 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -3021,7 +3101,7 @@ int main() {
connect()
; return 0; }
EOF
-if { (eval echo configure:3025: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:3105: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -3052,7 +3132,7 @@ esac
case "$LIBS" in
*-linet*) ;;
*) echo $ac_n "checking for connect in -linet""... $ac_c" 1>&6
-echo "configure:3056: checking for connect in -linet" >&5
+echo "configure:3136: checking for connect in -linet" >&5
ac_lib_var=`echo inet'_'connect | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
@@ -3060,7 +3140,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-linet $LIBS"
cat > conftest.$ac_ext <<EOF
-#line 3064 "configure"
+#line 3144 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
@@ -3071,7 +3151,7 @@ int main() {
connect()
; return 0; }
EOF
-if { (eval echo configure:3075: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:3155: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
@@ -3114,12 +3194,12 @@ fi
for ac_func in waitpid getcwd strdup strerror chown chmod chroot
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3118: checking for $ac_func" >&5
+echo "configure:3198: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3123 "configure"
+#line 3203 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -3142,7 +3222,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:3146: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:3226: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -3169,12 +3249,12 @@ done
for ac_func in fstat strchr utime utimes getrlimit fsync execl bzero memset
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3173: checking for $ac_func" >&5
+echo "configure:3253: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3178 "configure"
+#line 3258 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -3197,7 +3277,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:3201: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:3281: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -3224,12 +3304,12 @@ done
for ac_func in memmove vsnprintf setsid glob strpbrk pipe crypt16 getauthuid
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3228: checking for $ac_func" >&5
+echo "configure:3308: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3233 "configure"
+#line 3313 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -3252,7 +3332,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:3256: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:3336: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -3279,12 +3359,12 @@ done
for ac_func in strftime sigprocmask sigblock sigaction innetgr
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3283: checking for $ac_func" >&5
+echo "configure:3363: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3288 "configure"
+#line 3368 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -3307,7 +3387,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:3311: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:3391: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -3334,12 +3414,12 @@ done
for ac_func in initgroups select rdchk getgrnam pathconf putprpwnam
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3338: checking for $ac_func" >&5
+echo "configure:3418: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3343 "configure"
+#line 3423 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -3362,7 +3442,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:3366: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:3446: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -3389,12 +3469,12 @@ done
for ac_func in setuidx setgroups mktime rename ftruncate
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3393: checking for $ac_func" >&5
+echo "configure:3473: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3398 "configure"
+#line 3478 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -3417,7 +3497,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:3421: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:3501: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -3444,12 +3524,12 @@ done
for ac_func in set_auth_parameters atexit grantpt getspnam dup2
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3448: checking for $ac_func" >&5
+echo "configure:3528: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3453 "configure"
+#line 3533 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -3472,7 +3552,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:3476: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:3556: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -3499,12 +3579,12 @@ done
for ac_func in bigcrypt getprpwnam setluid yp_get_default_domain getpwanam
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
-echo "configure:3503: checking for $ac_func" >&5
+echo "configure:3583: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 3508 "configure"
+#line 3588 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
@@ -3527,7 +3607,7 @@ $ac_func();
; return 0; }
EOF
-if { (eval echo configure:3531: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:3611: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
@@ -3557,12 +3637,12 @@ if test "$cross_compiling" = yes; then
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 3561 "configure"
+#line 3641 "configure"
#include "confdefs.h"
#include <stdio.h>
main() { long long x = 1000000; x *= x; exit(((x/1000000) == 1000000)? 0: 1); }
EOF
-if { (eval echo configure:3566: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:3646: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
then
echo yes;cat >> confdefs.h <<\EOF
#define HAVE_LONGLONG 1
@@ -3583,13 +3663,13 @@ if test "$cross_compiling" = yes; then
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 3587 "configure"
+#line 3667 "configure"
#include "confdefs.h"
#include <stdio.h>
#include <sys/stat.h>
main() { struct stat64 st; off64_t s; if (sizeof(off_t) == sizeof(off64_t)) exit(1); exit((lstat64("/dev/null", &st)==0)?0:1); }
EOF
-if { (eval echo configure:3593: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:3673: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
then
echo yes;cat >> confdefs.h <<\EOF
#define HAVE_OFF64_T 1
@@ -3610,7 +3690,7 @@ if test "$cross_compiling" = yes; then
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 3614 "configure"
+#line 3694 "configure"
#include "confdefs.h"
#include <sys/types.h>
@@ -3618,7 +3698,7 @@ else
#include <sys/sem.h>
main() { union semun ss; exit(0); }
EOF
-if { (eval echo configure:3622: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:3702: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
then
echo yes;cat >> confdefs.h <<\EOF
#define HAVE_UNION_SEMUN 1
@@ -3639,12 +3719,12 @@ if test "$cross_compiling" = yes; then
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 3643 "configure"
+#line 3723 "configure"
#include "confdefs.h"
#include <stdio.h>
main() { char c; c=250; exit((c > 0)?0:1); }
EOF
-if { (eval echo configure:3648: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:3728: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
then
echo yes;cat >> confdefs.h <<\EOF
#define HAVE_UNSIGNED_CHAR 1
@@ -3662,7 +3742,7 @@ fi
echo $ac_n "checking for sin_len in sock ... $ac_c"
cat > conftest.$ac_ext <<EOF
-#line 3666 "configure"
+#line 3746 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/socket.h>
@@ -3671,7 +3751,7 @@ int main() {
struct sockaddr_in sock; sock.sin_len = sizeof(sock);
; return 0; }
EOF
-if { (eval echo configure:3675: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:3755: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
echo yes;cat >> confdefs.h <<\EOF
#define HAVE_SOCK_SIN_LEN 1
@@ -3687,14 +3767,14 @@ rm -f conftest*
echo $ac_n "checking for __FILE__ macro ... $ac_c"
cat > conftest.$ac_ext <<EOF
-#line 3691 "configure"
+#line 3771 "configure"
#include "confdefs.h"
#include <stdio.h>
int main() {
printf("%s\n", __FILE__);
; return 0; }
EOF
-if { (eval echo configure:3698: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:3778: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
echo yes;cat >> confdefs.h <<\EOF
#define HAVE_FILE_MACRO 1
@@ -3710,14 +3790,14 @@ rm -f conftest*
echo $ac_n "checking for __FUNCTION__ macro ... $ac_c"
cat > conftest.$ac_ext <<EOF
-#line 3714 "configure"
+#line 3794 "configure"
#include "confdefs.h"
#include <stdio.h>
int main() {
printf("%s\n", __FUNCTION__);
; return 0; }
EOF
-if { (eval echo configure:3721: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:3801: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
echo yes;cat >> confdefs.h <<\EOF
#define HAVE_FUNCTION_MACRO 1
@@ -3736,14 +3816,14 @@ if test "$cross_compiling" = yes; then
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 3740 "configure"
+#line 3820 "configure"
#include "confdefs.h"
#include <sys/time.h>
#include <unistd.h>
main() { struct timeval tv; exit(gettimeofday(&tv, NULL));}
EOF
-if { (eval echo configure:3747: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:3827: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
then
echo yes;cat >> confdefs.h <<\EOF
#define HAVE_GETTIMEOFDAY_TZ 1
@@ -3765,7 +3845,7 @@ if test "$cross_compiling" = yes; then
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 3769 "configure"
+#line 3849 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <dirent.h>
@@ -3773,7 +3853,7 @@ main() { struct dirent *di; DIR *d = opendir("."); di = readdir(d);
if (di && di->d_name[-2] == '.' && di->d_name[-1] == 0 &&
di->d_name[0] == 0) exit(0); exit(1);}
EOF
-if { (eval echo configure:3777: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:3857: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
then
echo yes - you are using the broken /usr/ucb/cc;cat >> confdefs.h <<\EOF
#define HAVE_BROKEN_READDIR 1
@@ -3791,7 +3871,7 @@ fi
echo $ac_n "checking for utimbuf ... $ac_c"
cat > conftest.$ac_ext <<EOF
-#line 3795 "configure"
+#line 3875 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <utime.h>
@@ -3799,7 +3879,7 @@ int main() {
struct utimbuf tbuf; tbuf.actime = 0; tbuf.modtime = 1; exit(utime("foo.c",&tbuf));
; return 0; }
EOF
-if { (eval echo configure:3803: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
+if { (eval echo configure:3883: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
echo yes;cat >> confdefs.h <<\EOF
#define HAVE_UTIMBUF 1
@@ -3818,11 +3898,11 @@ if test "$cross_compiling" = yes; then
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 3822 "configure"
+#line 3902 "configure"
#include "confdefs.h"
#include "tests/ftruncate.c"
EOF
-if { (eval echo configure:3826: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:3906: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
then
echo yes;cat >> confdefs.h <<\EOF
#define HAVE_FTRUNCATE_EXTEND 1
@@ -3843,11 +3923,11 @@ if test "$cross_compiling" = yes; then
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 3847 "configure"
+#line 3927 "configure"
#include "confdefs.h"
#include "tests/getgroups.c"
EOF
-if { (eval echo configure:3851: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:3931: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
then
echo yes;cat >> confdefs.h <<\EOF
#define HAVE_BROKEN_GETGROUPS 1
@@ -3869,7 +3949,7 @@ if test "$cross_compiling" = yes; then
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 3873 "configure"
+#line 3953 "configure"
#include "confdefs.h"
#include <stdio.h>
@@ -3881,7 +3961,7 @@ if (strcmp(inet_ntoa(ip),"18.52.86.120") &&
strcmp(inet_ntoa(ip),"120.86.52.18")) { exit(0); }
exit(1);}
EOF
-if { (eval echo configure:3885: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:3965: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
then
echo yes;cat >> confdefs.h <<\EOF
#define REPLACE_INET_NTOA 1
@@ -3902,11 +3982,11 @@ if test "$cross_compiling" = yes; then
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 3906 "configure"
+#line 3986 "configure"
#include "confdefs.h"
main() { exit(getuid() != 0); }
EOF
-if { (eval echo configure:3910: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:3990: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
then
echo yes;cat >> confdefs.h <<\EOF
#define HAVE_ROOT 1
@@ -3928,14 +4008,14 @@ if test "$cross_compiling" = yes; then
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 3932 "configure"
+#line 4012 "configure"
#include "confdefs.h"
#define HAVE_NETMASK_IFCONF 1
#define AUTOCONF 1
#include "lib/netmask.c"
EOF
-if { (eval echo configure:3939: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4019: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
then
echo yes;netmask=yes;cat >> confdefs.h <<\EOF
#define HAVE_NETMASK_IFCONF 1
@@ -3957,14 +4037,14 @@ if test "$cross_compiling" = yes; then
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 3961 "configure"
+#line 4041 "configure"
#include "confdefs.h"
#define HAVE_NETMASK_IFREQ 1
#define AUTOCONF 1
#include "lib/netmask.c"
EOF
-if { (eval echo configure:3968: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4048: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
then
echo yes;netmask=yes;cat >> confdefs.h <<\EOF
#define HAVE_NETMASK_IFREQ 1
@@ -3987,14 +4067,14 @@ if test "$cross_compiling" = yes; then
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 3991 "configure"
+#line 4071 "configure"
#include "confdefs.h"
#define HAVE_NETMASK_AIX 1
#define AUTOCONF 1
#include "lib/netmask.c"
EOF
-if { (eval echo configure:3998: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4078: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
then
echo yes;netmask=yes;cat >> confdefs.h <<\EOF
#define HAVE_NETMASK_AIX 1
@@ -4016,11 +4096,11 @@ if test "$cross_compiling" = yes; then
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 4020 "configure"
+#line 4100 "configure"
#include "confdefs.h"
#include "tests/trapdoor.c"
EOF
-if { (eval echo configure:4024: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4104: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
then
echo no
else
@@ -4041,11 +4121,11 @@ if test "$cross_compiling" = yes; then
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 4045 "configure"
+#line 4125 "configure"
#include "confdefs.h"
#include "tests/shared_mmap.c"
EOF
-if { (eval echo configure:4049: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4129: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
then
echo yes;cat >> confdefs.h <<\EOF
#define HAVE_SHARED_MMAP 1
@@ -4066,11 +4146,11 @@ if test "$cross_compiling" = yes; then
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 4070 "configure"
+#line 4150 "configure"
#include "confdefs.h"
#include "tests/fcntl_lock.c"
EOF
-if { (eval echo configure:4074: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4154: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
then
echo yes;cat >> confdefs.h <<\EOF
#define HAVE_FCNTL_LOCK 1
@@ -4091,11 +4171,11 @@ if test "$cross_compiling" = yes; then
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
-#line 4095 "configure"
+#line 4175 "configure"
#include "confdefs.h"
#include "tests/sysv_ipc.c"
EOF
-if { (eval echo configure:4099: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4179: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
then
echo yes;cat >> confdefs.h <<\EOF
#define HAVE_SYSV_IPC 1
@@ -4114,7 +4194,7 @@ fi
#################################################
# check for the AFS filesystem
echo $ac_n "checking whether to use AFS""... $ac_c" 1>&6
-echo "configure:4118: checking whether to use AFS" >&5
+echo "configure:4198: checking whether to use AFS" >&5
# Check whether --with-afs or --without-afs was given.
if test "${with_afs+set}" = set; then
withval="$with_afs"
@@ -4140,7 +4220,7 @@ fi
#################################################
# check for the DFS auth system
echo $ac_n "checking whether to use DFS auth""... $ac_c" 1>&6
-echo "configure:4144: checking whether to use DFS auth" >&5
+echo "configure:4224: checking whether to use DFS auth" >&5
# Check whether --with-dfs or --without-dfs was given.
if test "${with_dfs+set}" = set; then
withval="$with_dfs"
@@ -4165,7 +4245,7 @@ fi
#################################################
# check for automount support
echo $ac_n "checking whether to use AUTOMOUNT""... $ac_c" 1>&6
-echo "configure:4169: checking whether to use AUTOMOUNT" >&5
+echo "configure:4249: checking whether to use AUTOMOUNT" >&5
# Check whether --with-automount or --without-automount was given.
if test "${with_automount+set}" = set; then
withval="$with_automount"
@@ -4190,7 +4270,7 @@ fi
#################################################
# check for a LDAP password database
echo $ac_n "checking whether to use LDAP password database""... $ac_c" 1>&6
-echo "configure:4194: checking whether to use LDAP password database" >&5
+echo "configure:4274: checking whether to use LDAP password database" >&5
# Check whether --with-ldap or --without-ldap was given.
if test "${with_ldap+set}" = set; then
withval="$with_ldap"
@@ -4215,7 +4295,7 @@ fi
#################################################
# check for a NISPLUS password database
echo $ac_n "checking whether to use NISPLUS password database""... $ac_c" 1>&6
-echo "configure:4219: checking whether to use NISPLUS password database" >&5
+echo "configure:4299: checking whether to use NISPLUS password database" >&5
# Check whether --with-nisplus or --without-nisplus was given.
if test "${with_nisplus+set}" = set; then
withval="$with_nisplus"
@@ -4240,7 +4320,7 @@ fi
#################################################
# check for a NISPLUS_HOME support
echo $ac_n "checking whether to use NISPLUS_HOME""... $ac_c" 1>&6
-echo "configure:4244: checking whether to use NISPLUS_HOME" >&5
+echo "configure:4324: checking whether to use NISPLUS_HOME" >&5
# Check whether --with-nisplus-home or --without-nisplus-home was given.
if test "${with_nisplus_home+set}" = set; then
withval="$with_nisplus_home"
@@ -4265,7 +4345,7 @@ fi
#################################################
# check for the secure socket layer
echo $ac_n "checking whether to use SSL""... $ac_c" 1>&6
-echo "configure:4269: checking whether to use SSL" >&5
+echo "configure:4349: checking whether to use SSL" >&5
# Check whether --with-ssl or --without-ssl was given.
if test "${with_ssl+set}" = set; then
withval="$with_ssl"
@@ -4290,7 +4370,7 @@ fi
#################################################
# check for experimental mmap support
echo $ac_n "checking whether to use MMAP""... $ac_c" 1>&6
-echo "configure:4294: checking whether to use MMAP" >&5
+echo "configure:4374: checking whether to use MMAP" >&5
# Check whether --with-mmap or --without-mmap was given.
if test "${with_mmap+set}" = set; then
withval="$with_mmap"
@@ -4315,7 +4395,7 @@ fi
#################################################
# check for syslog logging
echo $ac_n "checking whether to use syslog logging""... $ac_c" 1>&6
-echo "configure:4319: checking whether to use syslog logging" >&5
+echo "configure:4399: checking whether to use syslog logging" >&5
# Check whether --with-syslog or --without-syslog was given.
if test "${with_syslog+set}" = set; then
withval="$with_syslog"
@@ -4340,7 +4420,7 @@ fi
#################################################
# check for experimental netatalk resource fork support
echo $ac_n "checking whether to support netatalk""... $ac_c" 1>&6
-echo "configure:4344: checking whether to support netatalk" >&5
+echo "configure:4424: checking whether to support netatalk" >&5
# Check whether --with-netatalk or --without-netatalk was given.
if test "${with_netatalk+set}" = set; then
withval="$with_netatalk"
@@ -4366,7 +4446,7 @@ fi
#################################################
# these tests are taken from the GNU fileutils package
echo "checking how to get filesystem space usage" 1>&6
-echo "configure:4370: checking how to get filesystem space usage" >&5
+echo "configure:4450: checking how to get filesystem space usage" >&5
space=no
# Perform only the link test since it seems there are no variants of the
@@ -4378,12 +4458,12 @@ space=no
if test $space = no; then
# SVR4
echo $ac_n "checking statvfs function (SVR4)""... $ac_c" 1>&6
-echo "configure:4382: checking statvfs function (SVR4)" >&5
+echo "configure:4462: checking statvfs function (SVR4)" >&5
if eval "test \"`echo '$''{'fu_cv_sys_stat_statvfs'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
-#line 4387 "configure"
+#line 4467 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/statvfs.h>
@@ -4391,7 +4471,7 @@ int main() {
struct statvfs fsd; statvfs (0, &fsd);
; return 0; }
EOF
-if { (eval echo configure:4395: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
+if { (eval echo configure:4475: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest; then
rm -rf conftest*
fu_cv_sys_stat_statvfs=yes
else
@@ -4416,7 +4496,7 @@ fi
if test $space = no; then
# DEC Alpha running OSF/1
echo $ac_n "checking for 3-argument statfs function (DEC OSF/1)""... $ac_c" 1>&6
-echo "configure:4420: checking for 3-argument statfs function (DEC OSF/1)" >&5
+echo "configure:4500: checking for 3-argument statfs function (DEC OSF/1)" >&5
if eval "test \"`echo '$''{'fu_cv_sys_stat_statfs3_osf1'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4424,7 +4504,7 @@ else
fu_cv_sys_stat_statfs3_osf1=no
else
cat > conftest.$ac_ext <<EOF
-#line 4428 "configure"
+#line 4508 "configure"
#include "confdefs.h"
#include <sys/param.h>
@@ -4437,7 +4517,7 @@ else
exit (statfs (".", &fsd, sizeof (struct statfs)));
}
EOF
-if { (eval echo configure:4441: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4521: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
then
fu_cv_sys_stat_statfs3_osf1=yes
else
@@ -4464,7 +4544,7 @@ fi
if test $space = no; then
# AIX
echo $ac_n "checking for two-argument statfs with statfs.bsize member (AIX, 4.3BSD)""... $ac_c" 1>&6
-echo "configure:4468: checking for two-argument statfs with statfs.bsize member (AIX, 4.3BSD)" >&5
+echo "configure:4548: checking for two-argument statfs with statfs.bsize member (AIX, 4.3BSD)" >&5
if eval "test \"`echo '$''{'fu_cv_sys_stat_statfs2_bsize'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4472,7 +4552,7 @@ else
fu_cv_sys_stat_statfs2_bsize=no
else
cat > conftest.$ac_ext <<EOF
-#line 4476 "configure"
+#line 4556 "configure"
#include "confdefs.h"
#ifdef HAVE_SYS_PARAM_H
@@ -4491,7 +4571,7 @@ else
exit (statfs (".", &fsd));
}
EOF
-if { (eval echo configure:4495: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4575: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
then
fu_cv_sys_stat_statfs2_bsize=yes
else
@@ -4518,7 +4598,7 @@ fi
if test $space = no; then
# SVR3
echo $ac_n "checking for four-argument statfs (AIX-3.2.5, SVR3)""... $ac_c" 1>&6
-echo "configure:4522: checking for four-argument statfs (AIX-3.2.5, SVR3)" >&5
+echo "configure:4602: checking for four-argument statfs (AIX-3.2.5, SVR3)" >&5
if eval "test \"`echo '$''{'fu_cv_sys_stat_statfs4'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4526,7 +4606,7 @@ else
fu_cv_sys_stat_statfs4=no
else
cat > conftest.$ac_ext <<EOF
-#line 4530 "configure"
+#line 4610 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/statfs.h>
@@ -4536,7 +4616,7 @@ else
exit (statfs (".", &fsd, sizeof fsd, 0));
}
EOF
-if { (eval echo configure:4540: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4620: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
then
fu_cv_sys_stat_statfs4=yes
else
@@ -4563,7 +4643,7 @@ fi
if test $space = no; then
# 4.4BSD and NetBSD
echo $ac_n "checking for two-argument statfs with statfs.fsize member (4.4BSD and NetBSD)""... $ac_c" 1>&6
-echo "configure:4567: checking for two-argument statfs with statfs.fsize member (4.4BSD and NetBSD)" >&5
+echo "configure:4647: checking for two-argument statfs with statfs.fsize member (4.4BSD and NetBSD)" >&5
if eval "test \"`echo '$''{'fu_cv_sys_stat_statfs2_fsize'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4571,7 +4651,7 @@ else
fu_cv_sys_stat_statfs2_fsize=no
else
cat > conftest.$ac_ext <<EOF
-#line 4575 "configure"
+#line 4655 "configure"
#include "confdefs.h"
#include <sys/types.h>
#ifdef HAVE_SYS_PARAM_H
@@ -4587,7 +4667,7 @@ else
exit (statfs (".", &fsd));
}
EOF
-if { (eval echo configure:4591: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4671: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
then
fu_cv_sys_stat_statfs2_fsize=yes
else
@@ -4614,7 +4694,7 @@ fi
if test $space = no; then
# Ultrix
echo $ac_n "checking for two-argument statfs with struct fs_data (Ultrix)""... $ac_c" 1>&6
-echo "configure:4618: checking for two-argument statfs with struct fs_data (Ultrix)" >&5
+echo "configure:4698: checking for two-argument statfs with struct fs_data (Ultrix)" >&5
if eval "test \"`echo '$''{'fu_cv_sys_stat_fs_data'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
@@ -4622,7 +4702,7 @@ else
fu_cv_sys_stat_fs_data=no
else
cat > conftest.$ac_ext <<EOF
-#line 4626 "configure"
+#line 4706 "configure"
#include "confdefs.h"
#include <sys/types.h>
#ifdef HAVE_SYS_PARAM_H
@@ -4642,7 +4722,7 @@ else
exit (statfs (".", &fsd) != 1);
}
EOF
-if { (eval echo configure:4646: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
+if { (eval echo configure:4726: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest && (./conftest; exit) 2>/dev/null
then
fu_cv_sys_stat_fs_data=yes
else
diff --git a/source3/configure.in b/source3/configure.in
index dd2163fb70..e90cd13f4d 100644
--- a/source3/configure.in
+++ b/source3/configure.in
@@ -31,11 +31,12 @@ AC_CHECK_HEADERS(sys/fcntl.h sys/select.h fcntl.h sys/time.h sys/unistd.h)
AC_CHECK_HEADERS(unistd.h utime.h grp.h sys/id.h limits.h memory.h net/if.h)
AC_CHECK_HEADERS(compat.h rpc/types.h rpc/xdr.h rpc/auth.h rpc/clnt.h)
AC_CHECK_HEADERS(rpcsvc/yp_prot.h rpcsvc/ypclnt.h sys/param.h ctype.h )
-AC_CHECK_HEADERS(sys/wait.hsys/resource.h sys/ioctl.h sys/mode.h)
+AC_CHECK_HEADERS(sys/wait.h sys/resource.h sys/ioctl.h sys/mode.h)
AC_CHECK_HEADERS(sys/filio.h string.h strings.h stdlib.h sys/socket.h)
AC_CHECK_HEADERS(sys/mount.h sys/vfs.h sys/fs/s5param.h sys/filsys.h termios.h)
AC_CHECK_HEADERS(sys/statfs.h sys/dustat.h sys/statvfs.h stdarg.h sys/sockio.h)
AC_CHECK_HEADERS(shadow.h netinet/tcp.h sys/security.h security/pam_appl.h)
+AC_CHECK_HEADERS(stropts.h poll.h)
AC_CHECK_SIZEOF(int)
AC_CHECK_SIZEOF(long)
diff --git a/source3/include/config.h.in b/source3/include/config.h.in
index dd8e509fad..f67061a289 100644
--- a/source3/include/config.h.in
+++ b/source3/include/config.h.in
@@ -302,6 +302,9 @@
/* Define if you have the <netinet/tcp.h> header file. */
#undef HAVE_NETINET_TCP_H
+/* Define if you have the <poll.h> header file. */
+#undef HAVE_POLL_H
+
/* Define if you have the <rpc/types.h> header file. */
#undef HAVE_RPC_TYPES_H
@@ -338,6 +341,9 @@
/* Define if you have the <strings.h> header file. */
#undef HAVE_STRINGS_H
+/* Define if you have the <stropts.h> header file. */
+#undef HAVE_STROPTS_H
+
/* Define if you have the <sys/dir.h> header file. */
#undef HAVE_SYS_DIR_H
diff --git a/source3/include/includes.h b/source3/include/includes.h
index 4efa475424..8b7620e4f9 100644
--- a/source3/include/includes.h
+++ b/source3/include/includes.h
@@ -260,6 +260,14 @@
#include <compat.h>
#endif
+#ifdef HAVE_STROPTS_H
+#include <stropts.h>
+#endif
+
+#ifdef HAVE_POLL_H
+#include <poll.h>
+#endif
+
#ifndef uchar
#define uchar unsigned char
#endif
@@ -270,6 +278,31 @@
#define schar char
#endif
+/*
+ Samba needs type definitions for int16, int32, uint16 and uint32.
+
+ Normally these are signed and unsigned 16 and 32 bit integers, but
+ they actually only need to be at least 16 and 32 bits
+ respectively. Thus if your word size is 8 bytes just defining them
+ as signed and unsigned int will work.
+*/
+
+#ifndef uint8
+#define uint8 unsigned char
+#endif
+
+#ifndef int16
+#if (SIZEOF_SHORT == 4)
+#define int16 __ERROR___CANNOT_DETERMINE_TYPE_FOR_INT16;
+#else /* SIZEOF_SHORT != 4 */
+#define int16 short
+#endif /* SIZEOF_SHORT != 4 */
+#endif
+
+#ifndef uint16
+#define uint16 unsigned int16
+#endif
+
#ifndef int32
#if (SIZEOF_INT == 4)
#define int32 int
@@ -284,6 +317,18 @@
#define uint32 unsigned int32
#endif
+/*
+ * Type for device and inodes.
+ */
+
+#ifndef SMB_DEV_T
+#define SMB_DEV_T uint32
+#endif
+
+#ifndef SMB_INO_T
+#define SMB_INO_T uint32
+#endif
+
#ifndef MIN
#define MIN(a,b) ((a)<(b)?(a):(b))
#endif
diff --git a/source3/include/proto.h b/source3/include/proto.h
index 8ee95483c5..3bc2a132a0 100644
--- a/source3/include/proto.h
+++ b/source3/include/proto.h
@@ -498,11 +498,11 @@ BOOL do_unlock(files_struct *fsp,connection_struct *conn,
BOOL locking_init(int read_only);
BOOL locking_end(void);
BOOL lock_share_entry(connection_struct *conn,
- uint32 dev, uint32 inode, int *ptok);
+ SMB_DEV_T dev, SMB_INO_T inode, int *ptok);
BOOL unlock_share_entry(connection_struct *conn,
- uint32 dev, uint32 inode, int token);
+ SMB_DEV_T dev, SMB_INO_T inode, int token);
int get_share_modes(connection_struct *conn,
- int token, uint32 dev, uint32 inode,
+ int token, SMB_DEV_T dev, SMB_INO_T inode,
share_mode_entry **shares);
void del_share_mode(int token, files_struct *fsp);
BOOL set_share_mode(int token, files_struct *fsp, uint16 port, uint16 op_type);
@@ -2027,7 +2027,7 @@ file_fd_struct *fd_get_new(void);
void file_close_conn(connection_struct *conn);
void file_init(void);
void file_close_user(int vuid);
-files_struct *file_find_dit(int dev, int inode, struct timeval *tval);
+files_struct *file_find_dit(SMB_DEV_T dev, SMB_INO_T inode, struct timeval *tval);
files_struct *file_find_print(void);
void file_sync_all(connection_struct *conn);
void file_free(files_struct *fsp);
@@ -2102,9 +2102,9 @@ int check_share_mode( share_mode_entry *share, int deny_mode, char *fname,
BOOL open_oplock_ipc(void);
BOOL process_local_message(int sock, char *buffer, int buf_size);
-BOOL oplock_break(uint32 dev, uint32 inode, struct timeval *tval);
+BOOL oplock_break(SMB_DEV_T dev, SMB_INO_T inode, struct timeval *tval);
BOOL request_oplock_break(share_mode_entry *share_entry,
- uint32 dev, uint32 inode);
+ SMB_DEV_T dev, SMB_INO_T inode);
BOOL attempt_close_oplocked_file(files_struct *fsp);
/*The following definitions come from smbd/password.c */
diff --git a/source3/include/smb.h b/source3/include/smb.h
index 90435b208e..b27c531937 100644
--- a/source3/include/smb.h
+++ b/source3/include/smb.h
@@ -48,35 +48,6 @@ typedef int BOOL;
/* limiting size of ipc replies */
#define REALLOC(ptr,size) Realloc(ptr,MAX((size),4*1024))
-/*
- Samba needs type definitions for int16, int32, uint16 and uint32.
-
- Normally these are signed and unsigned 16 and 32 bit integers, but
- they actually only need to be at least 16 and 32 bits
- respectively. Thus if your word size is 8 bytes just defining them
- as signed and unsigned int will work.
-*/
-
-#ifndef uint8
-typedef unsigned char uint8;
-#endif
-
-#ifndef uint16
-typedef unsigned short uint16;
-#endif
-
-#ifndef uchar
-#define uchar unsigned char
-#endif
-
-#ifndef int16
-#define int16 short
-#endif
-
-#ifndef uint16
-#define uint16 unsigned short
-#endif
-
#define SIZEOFWORD 2
#ifndef DEF_CREATE_MASK
@@ -507,8 +478,8 @@ typedef struct file_fd_struct
uint16 ref_count;
uint16 uid_cache_count;
uid_t uid_users_cache[10];
- uint32 dev;
- uint32 inode;
+ SMB_DEV_T dev;
+ SMB_INO_T inode;
int fd;
int fdnum;
int fd_readonly;
@@ -701,9 +672,9 @@ typedef struct
to support the following operations */
struct share_ops {
BOOL (*stop_mgmt)(void);
- BOOL (*lock_entry)(connection_struct *, uint32 , uint32 , int *);
- BOOL (*unlock_entry)(connection_struct *, uint32 , uint32 , int );
- int (*get_entries)(connection_struct *, int , uint32 , uint32 , share_mode_entry **);
+ BOOL (*lock_entry)(connection_struct *, SMB_DEV_T , SMB_INO_T , int *);
+ BOOL (*unlock_entry)(connection_struct *, SMB_DEV_T , SMB_INO_T , int );
+ int (*get_entries)(connection_struct *, int , SMB_DEV_T , SMB_INO_T , share_mode_entry **);
void (*del_entry)(int , files_struct *);
BOOL (*set_entry)(int, files_struct *, uint16 , uint16 );
BOOL (*remove_oplock)(files_struct *, int);
@@ -1551,19 +1522,19 @@ extern int unix_ERR_code;
*
* Form of this is :
*
- * 0 2 6 10 14 18 22
+ * 0 2 6 10 14 14+devsize 14+devsize+inodesize
* +----+--------+--------+--------+-------+--------+
- * | cmd| pid | dev | inode | sec | usec |
+ * | cmd| pid | sec | usec | dev | inode |
* +----+--------+--------+--------+-------+--------+
*/
#define OPLOCK_BREAK_CMD 0x1
#define OPLOCK_BREAK_PID_OFFSET 2
-#define OPLOCK_BREAK_DEV_OFFSET 6
-#define OPLOCK_BREAK_INODE_OFFSET 10
-#define OPLOCK_BREAK_SEC_OFFSET 14
-#define OPLOCK_BREAK_USEC_OFFSET 18
-#define OPLOCK_BREAK_MSG_LEN 22
+#define OPLOCK_BREAK_SEC_OFFSET 6
+#define OPLOCK_BREAK_USEC_OFFSET 10
+#define OPLOCK_BREAK_DEV_OFFSET 14
+#define OPLOCK_BREAK_INODE_OFFSET (OPLOCK_BREAK_DEV_OFFSET + sizeof(SMB_DEV_T))
+#define OPLOCK_BREAK_MSG_LEN (OPLOCK_BREAK_INODE_OFFSET + sizeof(SMB_INO_T))
#define CMD_REPLY 0x8000
diff --git a/source3/lib/util.c b/source3/lib/util.c
index a52228c997..619d474d6d 100644
--- a/source3/lib/util.c
+++ b/source3/lib/util.c
@@ -1216,8 +1216,8 @@ int ChDir(char *path)
struct
{
- ino_t inode;
- dev_t dev;
+ SMB_DEV_T dev; /* These *must* be compatible with the types returned in a stat() call. */
+ SMB_INO_T inode; /* These *must* be compatible with the types returned in a stat() call. */
char *text;
BOOL valid;
} ino_list[MAX_GETWDCACHE];
@@ -1226,6 +1226,8 @@ BOOL use_getwd_cache=True;
/*******************************************************************
return the absolute current directory path
+ Note that this path is returned in UNIX format, not DOS
+ format.
********************************************************************/
char *GetWd(char *str)
{
@@ -1241,59 +1243,59 @@ char *GetWd(char *str)
/* init the cache */
if (!getwd_cache_init)
+ {
+ getwd_cache_init = True;
+ for (i=0;i<MAX_GETWDCACHE;i++)
{
- getwd_cache_init = True;
- for (i=0;i<MAX_GETWDCACHE;i++)
- {
- string_init(&ino_list[i].text,"");
- ino_list[i].valid = False;
- }
+ string_init(&ino_list[i].text,"");
+ ino_list[i].valid = False;
}
+ }
/* Get the inode of the current directory, if this doesn't work we're
in trouble :-) */
if (stat(".",&st) == -1)
- {
- DEBUG(0,("Very strange, couldn't stat \".\"\n"));
- return(sys_getwd(str));
- }
+ {
+ DEBUG(0,("Very strange, couldn't stat \".\"\n"));
+ return(sys_getwd(str));
+ }
for (i=0; i<MAX_GETWDCACHE; i++)
if (ino_list[i].valid)
- {
+ {
- /* If we have found an entry with a matching inode and dev number
- then find the inode number for the directory in the cached string.
- If this agrees with that returned by the stat for the current
- directory then all is o.k. (but make sure it is a directory all
- the same...) */
+ /* If we have found an entry with a matching inode and dev number
+ then find the inode number for the directory in the cached string.
+ If this agrees with that returned by the stat for the current
+ directory then all is o.k. (but make sure it is a directory all
+ the same...) */
- if (st.st_ino == ino_list[i].inode &&
- st.st_dev == ino_list[i].dev)
- {
- if (stat(ino_list[i].text,&st2) == 0)
- {
- if (st.st_ino == st2.st_ino &&
- st.st_dev == st2.st_dev &&
- (st2.st_mode & S_IFMT) == S_IFDIR)
- {
- pstrcpy (str, ino_list[i].text);
-
- /* promote it for future use */
- array_promote((char *)&ino_list[0],sizeof(ino_list[0]),i);
- return (str);
- }
- else
- {
- /* If the inode is different then something's changed,
- scrub the entry and start from scratch. */
- ino_list[i].valid = False;
- }
- }
- }
+ if (st.st_ino == ino_list[i].inode &&
+ st.st_dev == ino_list[i].dev)
+ {
+ if (stat(ino_list[i].text,&st2) == 0)
+ {
+ if (st.st_ino == st2.st_ino &&
+ st.st_dev == st2.st_dev &&
+ (st2.st_mode & S_IFMT) == S_IFDIR)
+ {
+ pstrcpy (str, ino_list[i].text);
+
+ /* promote it for future use */
+ array_promote((char *)&ino_list[0],sizeof(ino_list[0]),i);
+ return (str);
+ }
+ else
+ {
+ /* If the inode is different then something's changed,
+ scrub the entry and start from scratch. */
+ ino_list[i].valid = False;
+ }
+ }
}
+ }
/* We don't have the information to hand so rely on traditional methods.
@@ -1301,10 +1303,10 @@ char *GetWd(char *str)
not quite so bad getwd. */
if (!sys_getwd(s))
- {
- DEBUG(0,("Getwd failed, errno %s\n",strerror(errno)));
- return (NULL);
- }
+ {
+ DEBUG(0,("Getwd failed, errno %s\n",strerror(errno)));
+ return (NULL);
+ }
pstrcpy(str,s);
@@ -4334,7 +4336,6 @@ void smb_panic(char *why)
/*******************************************************************
a readdir wrapper which just returns the file name
-also return the inode number if requested
********************************************************************/
char *readdirname(void *p)
{
diff --git a/source3/locking/locking.c b/source3/locking/locking.c
index 4f2c9ab345..856b7cfcf6 100644
--- a/source3/locking/locking.c
+++ b/source3/locking/locking.c
@@ -190,7 +190,7 @@ BOOL locking_end(void)
Lock a hash bucket entry.
******************************************************************/
BOOL lock_share_entry(connection_struct *conn,
- uint32 dev, uint32 inode, int *ptok)
+ SMB_DEV_T dev, SMB_INO_T inode, int *ptok)
{
return share_ops->lock_entry(conn, dev, inode, ptok);
}
@@ -199,7 +199,7 @@ BOOL lock_share_entry(connection_struct *conn,
Unlock a hash bucket entry.
******************************************************************/
BOOL unlock_share_entry(connection_struct *conn,
- uint32 dev, uint32 inode, int token)
+ SMB_DEV_T dev, SMB_INO_T inode, int token)
{
return share_ops->unlock_entry(conn, dev, inode, token);
}
@@ -208,7 +208,7 @@ BOOL unlock_share_entry(connection_struct *conn,
Get all share mode entries for a dev/inode pair.
********************************************************************/
int get_share_modes(connection_struct *conn,
- int token, uint32 dev, uint32 inode,
+ int token, SMB_DEV_T dev, SMB_INO_T inode,
share_mode_entry **shares)
{
return share_ops->get_entries(conn, token, dev, inode, shares);
diff --git a/source3/locking/locking_shm.c b/source3/locking/locking_shm.c
index cded5e628d..909bdb78e4 100644
--- a/source3/locking/locking_shm.c
+++ b/source3/locking/locking_shm.c
@@ -45,8 +45,8 @@ typedef struct
{
int next_offset; /* offset of next record in chain from hash bucket */
int locking_version;
- int32 st_dev;
- int32 st_ino;
+ SMB_DEV_T st_dev;
+ SMB_INO_T st_ino;
int num_share_mode_entries;
int share_mode_entries; /* Chain of share mode entries for this file */
char file_name[1];
@@ -63,7 +63,7 @@ static int read_only;
/* Conversion to hash entry index from device and inode numbers. */
-#define HASH_ENTRY(dev,ino) ((((uint32)(dev)) ^ ((uint32)(ino))) % shmops->hash_size())
+#define HASH_ENTRY(dev,ino) ((unsigned int)(((dev) ^ (ino)) % shmops->hash_size()))
/*******************************************************************
@@ -78,7 +78,7 @@ static BOOL shm_stop_share_mode_mgmt(void)
lock a hash bucket entry in shared memory for share_mode management
******************************************************************/
static BOOL shm_lock_share_entry(connection_struct *conn,
- uint32 dev, uint32 inode, int *ptok)
+ SMB_DEV_T dev, SMB_INO_T inode, int *ptok)
{
return shmops->lock_hash_entry(HASH_ENTRY(dev, inode));
}
@@ -87,7 +87,7 @@ static BOOL shm_lock_share_entry(connection_struct *conn,
unlock a hash bucket entry in shared memory for share_mode management
******************************************************************/
static BOOL shm_unlock_share_entry(connection_struct *conn,
- uint32 dev, uint32 inode, int token)
+ SMB_DEV_T dev, SMB_INO_T inode, int token)
{
return shmops->unlock_hash_entry(HASH_ENTRY(dev, inode));
}
@@ -96,7 +96,7 @@ static BOOL shm_unlock_share_entry(connection_struct *conn,
get all share mode entries in shared memory for a dev/inode pair.
********************************************************************/
static int shm_get_share_modes(connection_struct *conn,
- int token, uint32 dev, uint32 inode,
+ int token, SMB_DEV_T dev, SMB_INO_T inode,
share_mode_entry **old_shares)
{
int *mode_array;
@@ -259,7 +259,8 @@ del the share mode of a file.
********************************************************************/
static void shm_del_share_mode(int token, files_struct *fsp)
{
- uint32 dev, inode;
+ SMB_DEV_T dev;
+ SMB_INO_T inode;
int *mode_array;
unsigned int hash_entry;
share_mode_record *file_scanner_p;
@@ -387,7 +388,8 @@ set the share mode of a file. Return False on fail, True on success.
********************************************************************/
static BOOL shm_set_share_mode(int token, files_struct *fsp, uint16 port, uint16 op_type)
{
- int32 dev, inode;
+ SMB_DEV_T dev;
+ SMB_INO_T inode;
int *mode_array;
unsigned int hash_entry;
share_mode_record *file_scanner_p;
@@ -495,7 +497,8 @@ Remove an oplock port and mode entry from a share mode.
********************************************************************/
static BOOL shm_remove_share_oplock(files_struct *fsp, int token)
{
- uint32 dev, inode;
+ SMB_DEV_T dev;
+ SMB_INO_T inode;
int *mode_array;
unsigned int hash_entry;
share_mode_record *file_scanner_p;
@@ -696,6 +699,3 @@ struct share_ops *locking_shm_init(int ronly)
int locking_shm_dummy_procedure(void)
{return 0;}
#endif /* FAST_SHARE_MODES */
-
-
-
diff --git a/source3/locking/locking_slow.c b/source3/locking/locking_slow.c
index 2017f09289..0a766c9ab9 100644
--- a/source3/locking/locking_slow.c
+++ b/source3/locking/locking_slow.c
@@ -81,7 +81,7 @@ static BOOL slow_stop_share_mode_mgmt(void)
name a share file
******************************************************************/
static BOOL share_name(connection_struct *conn,
- uint32 dev, uint32 inode, char *name)
+ SMB_DEV_T dev, SMB_INO_T inode, char *name)
{
int len;
pstrcpy(name,lp_lockdir());
@@ -124,7 +124,7 @@ static int delete_share_file(connection_struct *conn, char *fname )
lock a share mode file.
******************************************************************/
static BOOL slow_lock_share_entry(connection_struct *conn,
- uint32 dev, uint32 inode, int *ptok)
+ SMB_DEV_T dev, SMB_INO_T inode, int *ptok)
{
pstring fname;
int fd;
@@ -217,9 +217,9 @@ static BOOL slow_lock_share_entry(connection_struct *conn,
unlock a share mode file.
******************************************************************/
static BOOL slow_unlock_share_entry(connection_struct *conn,
- uint32 dev, uint32 inode, int token)
+ SMB_DEV_T dev, SMB_INO_T inode, int token)
{
- int fd = (int)token;
+ int fd = token;
int ret = True;
struct stat sb;
pstring fname;
@@ -348,10 +348,11 @@ deleting it.\n", fname));
/*******************************************************************
get all share mode entries in a share file for a dev/inode pair.
********************************************************************/
-static int slow_get_share_modes(connection_struct *conn, int token, uint32 dev, uint32 inode,
+static int slow_get_share_modes(connection_struct *conn, int token,
+ SMB_DEV_T dev, SMB_INO_T inode,
share_mode_entry **old_shares)
{
- int fd = (int)token;
+ int fd = token;
pstring fname;
int i;
int num_entries;
@@ -960,7 +961,8 @@ static int slow_share_forall(void (*fn)(share_mode_entry *, char *))
char *base;
int fd;
pstring lname;
- uint32 dev,inode;
+ SMB_DEV_T dev;
+ SMB_INO_T inode;
BOOL new_file;
pstring fname;
diff --git a/source3/smbd/close.c b/source3/smbd/close.c
index 07b000d7ad..42b16bc7ac 100644
--- a/source3/smbd/close.c
+++ b/source3/smbd/close.c
@@ -99,8 +99,8 @@ static void close_filestruct(files_struct *fsp)
****************************************************************************/
void close_file(files_struct *fsp, BOOL normal_close)
{
- uint32 dev = fsp->fd_ptr->dev;
- uint32 inode = fsp->fd_ptr->inode;
+ SMB_DEV_T dev = fsp->fd_ptr->dev;
+ SMB_INO_T inode = fsp->fd_ptr->inode;
int token;
connection_struct *conn = fsp->conn;
diff --git a/source3/smbd/files.c b/source3/smbd/files.c
index 00de8dfffa..d098677fba 100644
--- a/source3/smbd/files.c
+++ b/source3/smbd/files.c
@@ -125,8 +125,8 @@ file_fd_struct *fd_get_already_open(struct stat *sbuf)
for (fd_ptr=FileFd;fd_ptr;fd_ptr=fd_ptr->next) {
if ((fd_ptr->ref_count > 0) &&
- (((uint32)sbuf->st_dev) == fd_ptr->dev) &&
- (((uint32)sbuf->st_ino) == fd_ptr->inode)) {
+ (sbuf->st_dev == fd_ptr->dev) &&
+ (sbuf->st_ino == fd_ptr->inode)) {
fd_ptr->ref_count++;
DEBUG(3,("Re-used file_fd_struct dev = %x, inode = %x, ref_count = %d\n",
fd_ptr->dev, fd_ptr->inode,
@@ -162,8 +162,8 @@ file_fd_struct *fd_get_new(void)
memset(fd_ptr, 0, sizeof(*fd_ptr));
fd_ptr->fdnum = i;
- fd_ptr->dev = (uint32)-1;
- fd_ptr->inode = (uint32)-1;
+ fd_ptr->dev = (SMB_DEV_T)-1;
+ fd_ptr->inode = (SMB_INO_T)-1;
fd_ptr->fd = -1;
fd_ptr->fd_readonly = -1;
fd_ptr->fd_writeonly = -1;
@@ -254,7 +254,7 @@ void file_close_user(int vuid)
/****************************************************************************
find a fsp given a device, inode and timevalue
****************************************************************************/
-files_struct *file_find_dit(int dev, int inode, struct timeval *tval)
+files_struct *file_find_dit(SMB_DEV_T dev, SMB_INO_T inode, struct timeval *tval)
{
int count=0;
files_struct *fsp;
diff --git a/source3/smbd/open.c b/source3/smbd/open.c
index e54a456092..1a16a25c0a 100644
--- a/source3/smbd/open.c
+++ b/source3/smbd/open.c
@@ -166,8 +166,8 @@ int fd_attempt_close(file_fd_struct *fd_ptr)
fd_ptr->fd_readonly = -1;
fd_ptr->fd_writeonly = -1;
fd_ptr->real_open_flags = -1;
- fd_ptr->dev = (uint32)-1;
- fd_ptr->inode = (uint32)-1;
+ fd_ptr->dev = (SMB_DEV_T)-1;
+ fd_ptr->inode = (SMB_INO_T)-1;
fd_ptr->uid_cache_count = 0;
} else {
fd_remove_from_uid_cache(fd_ptr, (uid_t)current_user.uid);
@@ -484,8 +484,8 @@ static void open_file(files_struct *fsp,connection_struct *conn,
}
/* Set the correct entries in fd_ptr. */
- fd_ptr->dev = (uint32)sbuf->st_dev;
- fd_ptr->inode = (uint32)sbuf->st_ino;
+ fd_ptr->dev = sbuf->st_dev;
+ fd_ptr->inode = sbuf->st_ino;
fsp->fd_ptr = fd_ptr;
conn->num_files_open++;
@@ -596,8 +596,8 @@ void open_file_shared(files_struct *fsp,connection_struct *conn,char *fname,int
BOOL share_locked = False;
BOOL fcbopen = False;
int token;
- uint32 dev = 0;
- uint32 inode = 0;
+ SMB_DEV_T dev = 0;
+ SMB_INO_T inode = 0;
int num_share_modes = 0;
fsp->open = False;
@@ -681,8 +681,8 @@ void open_file_shared(files_struct *fsp,connection_struct *conn,char *fname,int
if (file_existed)
{
- dev = (uint32)sbuf.st_dev;
- inode = (uint32)sbuf.st_ino;
+ dev = sbuf.st_dev;
+ inode = sbuf.st_ino;
lock_share_entry(conn, dev, inode, &token);
share_locked = True;
num_share_modes = get_share_modes(conn, token, dev, inode, &old_shares);
@@ -994,15 +994,16 @@ BOOL check_file_sharing(connection_struct *conn,char *fname, BOOL rename_op)
struct stat sbuf;
int token;
int pid = getpid();
- uint32 dev, inode;
+ SMB_DEV_T dev;
+ SMB_INO_T inode;
if(!lp_share_modes(SNUM(conn)))
return True;
if (sys_stat(fname,&sbuf) == -1) return(True);
- dev = (uint32)sbuf.st_dev;
- inode = (uint32)sbuf.st_ino;
+ dev = sbuf.st_dev;
+ inode = sbuf.st_ino;
lock_share_entry(conn, dev, inode, &token);
num_share_modes = get_share_modes(conn, token, dev, inode, &old_shares);
diff --git a/source3/smbd/oplock.c b/source3/smbd/oplock.c
index d9df308a35..ab88b82953 100644
--- a/source3/smbd/oplock.c
+++ b/source3/smbd/oplock.c
@@ -105,8 +105,11 @@ should be %d).\n", msg_len, OPLOCK_BREAK_MSG_LEN));
}
{
uint32 remotepid = IVAL(msg_start,OPLOCK_BREAK_PID_OFFSET);
- uint32 dev = IVAL(msg_start,OPLOCK_BREAK_DEV_OFFSET);
- uint32 inode = IVAL(msg_start, OPLOCK_BREAK_INODE_OFFSET);
+ /*
+ * Warning - this will need to be changed if SMB_DEV_T/SMB_INO_T <> 4 bytes. !!
+ */
+ SMB_DEV_T dev = IVAL(msg_start,OPLOCK_BREAK_DEV_OFFSET);
+ SMB_INO_T inode = IVAL(msg_start, OPLOCK_BREAK_INODE_OFFSET);
struct timeval tval;
struct sockaddr_in toaddr;
@@ -176,8 +179,11 @@ reply - dumping info.\n"));
{
uint32 remotepid = IVAL(msg_start,OPLOCK_BREAK_PID_OFFSET);
- uint32 dev = IVAL(msg_start,OPLOCK_BREAK_DEV_OFFSET);
- uint32 inode = IVAL(msg_start, OPLOCK_BREAK_INODE_OFFSET);
+ /*
+ * Warning - this will need to be changed if SMB_DEV_T/SMB_INO_T <> 4 bytes. !!
+ */
+ SMB_DEV_T dev = IVAL(msg_start,OPLOCK_BREAK_DEV_OFFSET);
+ SMB_INO_T inode = IVAL(msg_start, OPLOCK_BREAK_INODE_OFFSET);
DEBUG(0,("process_local_message: unsolicited oplock break reply from \
pid %d, port %d, dev = %x, inode = %x\n", remotepid, from_port, dev, inode));
@@ -196,7 +202,7 @@ pid %d, port %d, dev = %x, inode = %x\n", remotepid, from_port, dev, inode));
/****************************************************************************
Process an oplock break directly.
****************************************************************************/
-BOOL oplock_break(uint32 dev, uint32 inode, struct timeval *tval)
+BOOL oplock_break(SMB_DEV_T dev, SMB_INO_T inode, struct timeval *tval)
{
extern struct current_user current_user;
extern int Client;
@@ -458,7 +464,7 @@ by the local smbd then call the oplock break function directly.
****************************************************************************/
BOOL request_oplock_break(share_mode_entry *share_entry,
- uint32 dev, uint32 inode)
+ SMB_DEV_T dev, SMB_INO_T inode)
{
char op_break_msg[OPLOCK_BREAK_MSG_LEN];
struct sockaddr_in addr_out;
@@ -487,10 +493,13 @@ should be %d\n", pid, share_entry->op_port, oplock_port));
SSVAL(op_break_msg,UDP_MESSAGE_CMD_OFFSET,OPLOCK_BREAK_CMD);
SIVAL(op_break_msg,OPLOCK_BREAK_PID_OFFSET,pid);
- SIVAL(op_break_msg,OPLOCK_BREAK_DEV_OFFSET,dev);
- SIVAL(op_break_msg,OPLOCK_BREAK_INODE_OFFSET,inode);
SIVAL(op_break_msg,OPLOCK_BREAK_SEC_OFFSET,(uint32)share_entry->time.tv_sec);
SIVAL(op_break_msg,OPLOCK_BREAK_USEC_OFFSET,(uint32)share_entry->time.tv_usec);
+ /*
+ * WARNING - this will need to be changed if SMB_DEV_T/SMB_INO_T <> 4 bytes.
+ */
+ SIVAL(op_break_msg,OPLOCK_BREAK_DEV_OFFSET,dev);
+ SIVAL(op_break_msg,OPLOCK_BREAK_INODE_OFFSET,inode);
/* set the address and port */
bzero((char *)&addr_out,sizeof(addr_out));
diff --git a/source3/smbd/reply.c b/source3/smbd/reply.c
index 3052bd730c..e30c31776c 100644
--- a/source3/smbd/reply.c
+++ b/source3/smbd/reply.c
@@ -3544,8 +3544,8 @@ int reply_lockingX(connection_struct *conn, char *inbuf,char *outbuf,int length,
if ((locktype & LOCKING_ANDX_OPLOCK_RELEASE))
{
int token;
- uint32 dev = fsp->fd_ptr->dev;
- uint32 inode = fsp->fd_ptr->inode;
+ SMB_DEV_T dev = fsp->fd_ptr->dev;
+ SMB_INO_T inode = fsp->fd_ptr->inode;
DEBUG(5,("reply_lockingX: oplock break reply from client for fnum = %d\n",
fsp->fnum));
diff --git a/source3/smbd/trans2.c b/source3/smbd/trans2.c
index da11dbcb29..3a851cfa8b 100644
--- a/source3/smbd/trans2.c
+++ b/source3/smbd/trans2.c
@@ -201,7 +201,7 @@ static int call_trans2open(connection_struct *conn, char *inbuf, char *outbuf,
pstring fname;
int unixmode;
int size=0,fmode=0,mtime=0,rmode;
- int32 inode = 0;
+ SMB_INO_T inode = 0;
struct stat sbuf;
int smb_action = 0;
BOOL bad_path = False;
@@ -278,6 +278,9 @@ static int call_trans2open(connection_struct *conn, char *inbuf, char *outbuf,
}
SSVAL(params,18,smb_action);
+ /*
+ * WARNING - this may need to be changed if SMB_INO_T <> 4 bytes.
+ */
SIVAL(params,20,inode);
/* Send the required number of replies */