summaryrefslogtreecommitdiffstats
path: root/defines.h
diff options
context:
space:
mode:
authorDarren Tucker <dtucker@zip.com.au>2008-06-09 06:17:53 +1000
committerDarren Tucker <dtucker@zip.com.au>2008-06-09 06:17:53 +1000
commit77001384cc067a4613dd6d7a07b9a786f7d7f1bb (patch)
tree5f1eb47742ba656c70a291af95f442539e99d104 /defines.h
parent598eaa6c0c36c3169963c7e6505d53b4073590f5 (diff)
- (dtucker) [configure.ac defines.h sftp-client.c M sftp-server.c] Add a
macro to convert fsid to unsigned long for platforms where fsid is a 2-member array.
Diffstat (limited to 'defines.h')
-rw-r--r--defines.h11
1 files changed, 10 insertions, 1 deletions
diff --git a/defines.h b/defines.h
index 7bb3a55e..0665d2b5 100644
--- a/defines.h
+++ b/defines.h
@@ -25,7 +25,7 @@
#ifndef _DEFINES_H
#define _DEFINES_H
-/* $Id: defines.h,v 1.148 2008/06/08 17:32:29 dtucker Exp $ */
+/* $Id: defines.h,v 1.149 2008/06/08 20:17:53 dtucker Exp $ */
/* Constants */
@@ -590,6 +590,15 @@ struct winsize {
# define SSH_SYSFDMAX 10000
#endif
+#ifdef FSID_HAS_VAL
+/* encode f_fsid into a 64 bit value */
+#define FSID_TO_ULONG(f) \
+ ((((u_int64_t)(f).val[0] & 0xffffffffUL) << 32) | \
+ ((f).val[1] & 0xffffffffUL))
+#else
+# define FSID_TO_ULONG(f) ((f))
+#endif
+
#if defined(__Lynx__)
/*
* LynxOS defines these in param.h which we do not want to include since