[SCM] Samba Shared Repository - branch v3-2-test updated -
release-3-2-0pre2-2969-g4876e4f
Jeremy Allison
jra at samba.org
Fri Aug 29 16:29:58 GMT 2008
The branch, v3-2-test has been updated
via 4876e4ffe9f5142bf90dc14b105436eaca35d3f4 (commit)
from 10f036829aca0b6b4cde03893f71effbf4d30a91 (commit)
http://gitweb.samba.org/?p=samba.git;a=shortlog;h=v3-2-test
- Log -----------------------------------------------------------------
commit 4876e4ffe9f5142bf90dc14b105436eaca35d3f4
Author: Jeremy Allison <jra at samba.org>
Date: Fri Aug 29 09:29:35 2008 -0700
Deal with systems that don't initialize birthtime correctly.
Pointed out by SATOH Fumiyasu <fumiyas at osstech.jp>.
Jeremy.
-----------------------------------------------------------------------
Summary of changes:
source/lib/time.c | 14 ++++++++++----
1 files changed, 10 insertions(+), 4 deletions(-)
Changeset truncated at 500 lines:
diff --git a/source/lib/time.c b/source/lib/time.c
index 8ab001e..425539c 100644
--- a/source/lib/time.c
+++ b/source/lib/time.c
@@ -860,20 +860,26 @@ struct timespec get_create_timespec(const SMB_STRUCT_STAT *pst,bool fake_dirs)
}
#if defined(HAVE_STAT_ST_BIRTHTIMESPEC)
- return pst->st_birthtimespec;
+ ret = pst->st_birthtimespec;
#elif defined(HAVE_STAT_ST_BIRTHTIMENSEC)
ret.tv_sec = pst->st_birthtime;
ret.tv_nsec = pst->st_birthtimenspec;
- return ret;
#elif defined(HAVE_STAT_ST_BIRTHTIME)
ret.tv_sec = pst->st_birthtime;
ret.tv_nsec = 0;
- return ret;
#else
ret.tv_sec = calc_create_time(pst);
ret.tv_nsec = 0;
- return ret;
#endif
+
+ /* Deal with systems that don't initialize birthtime correctly.
+ * Pointed out by SATOH Fumiyasu <fumiyas at osstech.jp>.
+ */
+ if (null_timespec(ret)) {
+ ret.tv_sec = calc_create_time(pst);
+ ret.tv_nsec = 0;
+ }
+ return ret;
}
/****************************************************************************
--
Samba Shared Repository
More information about the samba-cvs
mailing list