diff options
author | Derrell Lipman <derrell.lipman@unwireduniverse.com> | 2009-02-14 16:00:51 -0500 |
---|---|---|
committer | Derrell Lipman <derrell.lipman@unwireduniverse.com> | 2009-02-14 16:01:05 -0500 |
commit | 2b097cbb4e83291ffaea0c8904891f031caba898 (patch) | |
tree | a81e8bba3707d0d5b26d0f756c2eb1887d75a3dc /source3/libsmb | |
parent | b222de4eb3abab618f740a89279af2a7dc0985a7 (diff) | |
download | samba-2b097cbb4e83291ffaea0c8904891f031caba898.tar.gz samba-2b097cbb4e83291ffaea0c8904891f031caba898.tar.bz2 samba-2b097cbb4e83291ffaea0c8904891f031caba898.zip |
It seems some systems use f_flags instead of f_flag. Use the appropriate one.
Diffstat (limited to 'source3/libsmb')
-rw-r--r-- | source3/libsmb/libsmb_stat.c | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/source3/libsmb/libsmb_stat.c b/source3/libsmb/libsmb_stat.c index 8987c2e38b..8a950b6077 100644 --- a/source3/libsmb/libsmb_stat.c +++ b/source3/libsmb/libsmb_stat.c @@ -363,6 +363,7 @@ SMBC_fstatvfs_ctx(SMBCCTX *context, SMBCFILE *file, struct statvfs *st) { + unsigned long flags = 0; uint32 fs_attrs = 0; struct cli_state *cli = file->srv->cli; @@ -410,7 +411,7 @@ SMBC_fstatvfs_ctx(SMBCCTX *context, (fsblkcnt_t) actual_allocation_units; } - st->f_flag |= SMBC_VFS_FEATURE_NO_UNIXCIFS; + flags |= SMBC_VFS_FEATURE_NO_UNIXCIFS; } else { uint32 optimal_transfer_size; uint32 block_size; @@ -464,18 +465,24 @@ SMBC_fstatvfs_ctx(SMBCCTX *context, * user-specified case sensitivity setting. */ if (! smbc_getOptionCaseSensitive(context)) { - st->f_flag |= SMBC_VFS_FEATURE_CASE_INSENSITIVE; + flags |= SMBC_VFS_FEATURE_CASE_INSENSITIVE; } } else { if (! (fs_attrs & FILE_CASE_SENSITIVE_SEARCH)) { - st->f_flag |= SMBC_VFS_FEATURE_CASE_INSENSITIVE; + flags |= SMBC_VFS_FEATURE_CASE_INSENSITIVE; } } /* See if DFS is supported */ if ((cli->capabilities & CAP_DFS) && cli->dfsroot) { - st->f_flag |= SMBC_VFS_FEATURE_DFS; + flags |= SMBC_VFS_FEATURE_DFS; } +#if HAVE_STATVFS_F_FLAG + st->f_flag = flags; +#elif HAVE_STATVFS_F_FLAGS + st->f_flags = flags; +#endif + return 0; } |