diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2014-06-19 14:57:48 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2014-06-19 14:57:48 +0200 |
commit | 7113db27f07ca03a468c94f1163a7aacd1e051e3 (patch) | |
tree | b6729ade3a91f2badc0b515bd629a4a097b4ae37 /sfx2 | |
parent | b85470bab1d3fbedc512e5a5c06a8642ee73ce1b (diff) |
GetFileTimeValue can produce a "null" DateTime
Change-Id: I96bf1aa2d889c4d0925d073d1d7b4be47c23b3ac
Diffstat (limited to 'sfx2')
-rw-r--r-- | sfx2/source/doc/docinf.cxx | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/sfx2/source/doc/docinf.cxx b/sfx2/source/doc/docinf.cxx index c540545a305b..5e494372ed85 100644 --- a/sfx2/source/doc/docinf.cxx +++ b/sfx2/source/doc/docinf.cxx @@ -108,7 +108,11 @@ sal_uInt32 SFX2_DLLPUBLIC LoadOlePropertySet( i_xDocProps->setEditingCycles( nRevision ); } - if( xGlobSect->GetFileTimeValue( aDateTime, PROPID_EDITTIME ) ) + if( xGlobSect->GetFileTimeValue( aDateTime, PROPID_EDITTIME ) + && !(aDateTime.NanoSeconds == 0 && aDateTime.Seconds == 0 + && aDateTime.Minutes == 0 && aDateTime.Hours == 0 + && aDateTime.Day == 0 && aDateTime.Month == 0 + && aDateTime.Year == 0) ) { // subtract offset 1601-01-01 aDateTime.Year -= 1601; |