summaryrefslogtreecommitdiff
path: root/source3/smbwrapper/smbw.c
diff options
context:
space:
mode:
authorTim Potter <tpot@samba.org>2003-10-14 03:56:42 +0000
committerTim Potter <tpot@samba.org>2003-10-14 03:56:42 +0000
commitec890d5c0fcb0ac9b3680d3c930614c726535d0a (patch)
treec5657792d5cc939223709a83740c1ed5c2396db2 /source3/smbwrapper/smbw.c
parentbde2b4a8ec725229584125a054c2c169bc9bd1aa (diff)
downloadsamba-ec890d5c0fcb0ac9b3680d3c930614c726535d0a.tar.gz
samba-ec890d5c0fcb0ac9b3680d3c930614c726535d0a.tar.bz2
samba-ec890d5c0fcb0ac9b3680d3c930614c726535d0a.zip
Enclose usage of st_blksize and st_blocks struct stat members in
#ifdef HAVE_STAT_ST_BLKSIZE and #ifdef HAVE_STAT_ST_BLOCKS, respectively. Fixes bug 550 reported by Joachim Schmitz <schmitz@hp.com>. (This used to be commit 18adfdbe0c6ed79ba8ac07956b1e7abc226556c3)
Diffstat (limited to 'source3/smbwrapper/smbw.c')
-rw-r--r--source3/smbwrapper/smbw.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/source3/smbwrapper/smbw.c b/source3/smbwrapper/smbw.c
index 7eb01c7da3..0ddacdf8ba 100644
--- a/source3/smbwrapper/smbw.c
+++ b/source3/smbwrapper/smbw.c
@@ -1480,8 +1480,12 @@ say no to acls
st64->st_atime = st->st_atime;
st64->st_mtime = st->st_mtime;
st64->st_ctime = st->st_ctime;
+#ifdef HAVE_STAT_ST_BLKSIZE
st64->st_blksize = st->st_blksize;
+#endif
+#ifdef HAVE_STAT_ST_BLOCKS
st64->st_blocks = st->st_blocks;
+#endif
}
#endif
@@ -1545,8 +1549,12 @@ struct kernel_stat {
st->st_gid = kbuf->st_gid;
st->st_rdev = kbuf->st_rdev;
st->st_size = kbuf->st_size;
+#ifdef HAVE_STAT_ST_BLKSIZE
st->st_blksize = kbuf->st_blksize;
+#endif
+#ifdef HAVE_STAT_ST_BLOCKS
st->st_blocks = kbuf->st_blocks;
+#endif
st->st_atime = kbuf->st_atime_;
st->st_mtime = kbuf->st_mtime_;
st->st_ctime = kbuf->st_ctime_;