diff options
author | rbuj <[email protected]> | 2020-01-20 16:00:37 +0100 |
---|---|---|
committer | raveit65 <[email protected]> | 2020-01-31 18:52:19 +0100 |
commit | a70e19a51423b855b9da8d7f9ed40d396a534c67 (patch) | |
tree | 1fe5414f810a3fadd3fbd88673987cad60d62aac /properties | |
parent | e388b7032dda81917b05583c306a4b9690dcaa46 (diff) | |
download | atril-a70e19a51423b855b9da8d7f9ed40d396a534c67.tar.bz2 atril-a70e19a51423b855b9da8d7f9ed40d396a534c67.tar.xz |
Fix year 2038 issue with signed 32-bit integers
GTime is defined to always be a signed 32-bit integer, it will
overflow in the year 2038.
Diffstat (limited to 'properties')
-rw-r--r-- | properties/ev-properties-view.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/properties/ev-properties-view.c b/properties/ev-properties-view.c index 709b7c27..e6d703c7 100644 --- a/properties/ev-properties-view.c +++ b/properties/ev-properties-view.c @@ -342,12 +342,12 @@ ev_properties_view_set_info (EvPropertiesView *properties, const EvDocumentInfo if (info->fields_mask & EV_DOCUMENT_INFO_CREATOR) { set_property (properties, GTK_GRID (grid), CREATOR_PROPERTY, info->creator, &row); } - if (info->fields_mask & EV_DOCUMENT_INFO_CREATION_DATE) { + if ((info->fields_mask & EV_DOCUMENT_INFO_CREATION_DATE) && (info->creation_date > 0)) { text = ev_document_misc_format_date (info->creation_date); set_property (properties, GTK_GRID (grid), CREATION_DATE_PROPERTY, text, &row); g_free (text); } - if (info->fields_mask & EV_DOCUMENT_INFO_MOD_DATE) { + if ((info->fields_mask & EV_DOCUMENT_INFO_MOD_DATE) && (info->modified_date > 0)) { text = ev_document_misc_format_date (info->modified_date); set_property (properties, GTK_GRID (grid), MOD_DATE_PROPERTY, text, &row); g_free (text); |