diff options
author | Colomban Wendling <[email protected]> | 2025-06-25 11:29:04 +0200 |
---|---|---|
committer | Luke from DC <[email protected]> | 2025-07-02 20:12:54 +0000 |
commit | ab1324372b8d9ba7f11a7b5f5d35da7e3f4c3924 (patch) | |
tree | 8d446909bc4d26307227a061fc27fe203ad67a98 /src/dlg-prop.c | |
parent | bfad4da5b243c6353b21e499813c0a80790d3f98 (diff) | |
download | engrampa-ab1324372b8d9ba7f11a7b5f5d35da7e3f4c3924.tar.bz2 engrampa-ab1324372b8d9ba7f11a7b5f5d35da7e3f4c3924.tar.xz |
This likely should not happen with valid dates, but can if a archiver
reports invalid ones for whatever reason (legitimate weird dates, or
parser failures for example).
Diffstat (limited to 'src/dlg-prop.c')
-rw-r--r-- | src/dlg-prop.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/dlg-prop.c b/src/dlg-prop.c index cb8ed87..e82d5f1 100644 --- a/src/dlg-prop.c +++ b/src/dlg-prop.c @@ -101,10 +101,12 @@ dlg_prop (FrWindow *window) GDateTime *date_time; date_time = g_date_time_new_from_unix_local (get_file_mtime (fr_window_get_archive_uri (window))); - s = g_date_time_format (date_time, _("%d %B %Y, %H:%M")); - g_date_time_unref (date_time); - gtk_label_set_text (GET_LABEL ("p_date_label"), s); - g_free (s); + if (date_time) { + s = g_date_time_format (date_time, _("%d %B %Y, %H:%M")); + g_date_time_unref (date_time); + gtk_label_set_text (GET_LABEL ("p_date_label"), s); + g_free (s); + } /**/ |