From a70e19a51423b855b9da8d7f9ed40d396a534c67 Mon Sep 17 00:00:00 2001 From: rbuj Date: Mon, 20 Jan 2020 16:00:37 +0100 Subject: 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. --- libdocument/ev-attachment.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'libdocument/ev-attachment.c') diff --git a/libdocument/ev-attachment.c b/libdocument/ev-attachment.c index c0fb46f7..f87cfc13 100644 --- a/libdocument/ev-attachment.c +++ b/libdocument/ev-attachment.c @@ -38,8 +38,8 @@ enum struct _EvAttachmentPrivate { gchar *name; gchar *description; - GTime mtime; - GTime ctime; + gint64 mtime; + gint64 ctime; gsize size; gchar *data; gchar *mime_type; @@ -217,8 +217,8 @@ ev_attachment_init (EvAttachment *attachment) EvAttachment * ev_attachment_new (const gchar *name, const gchar *description, - GTime mtime, - GTime ctime, + gint64 mtime, + gint64 ctime, gsize size, gpointer data) { @@ -252,7 +252,7 @@ ev_attachment_get_description (EvAttachment *attachment) return attachment->priv->description; } -GTime +gint64 ev_attachment_get_modification_date (EvAttachment *attachment) { g_return_val_if_fail (EV_IS_ATTACHMENT (attachment), 0); @@ -260,7 +260,7 @@ ev_attachment_get_modification_date (EvAttachment *attachment) return attachment->priv->mtime; } -GTime +gint64 ev_attachment_get_creation_date (EvAttachment *attachment) { g_return_val_if_fail (EV_IS_ATTACHMENT (attachment), 0); -- cgit v1.2.1