diff options
author | Přemysl Eric Janouch <p@janouch.name> | 2024-01-22 12:42:14 +0100 |
---|---|---|
committer | Přemysl Eric Janouch <p@janouch.name> | 2024-01-22 12:45:26 +0100 |
commit | f196b03e97ce6bc4dd18f8896be2fea5086c221d (patch) | |
tree | b79775ad6dd831f9a0a4e9a47e67badf1ef3e706 | |
parent | ee08565389f0e0f3a5861887d0a0322b59213f98 (diff) | |
download | fiv-f196b03e97ce6bc4dd18f8896be2fea5086c221d.tar.gz fiv-f196b03e97ce6bc4dd18f8896be2fea5086c221d.tar.xz fiv-f196b03e97ce6bc4dd18f8896be2fea5086c221d.zip |
Resolve warnings resulting from GLib #2907
-rw-r--r-- | fiv-collection.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/fiv-collection.c b/fiv-collection.c index 13548b9..6878898 100644 --- a/fiv-collection.c +++ b/fiv-collection.c @@ -528,12 +528,16 @@ fiv_collection_file_query_info(GFile *file, const char *attributes, g_file_info_set_name(info, basename); g_free(basename); - if ((name = g_file_info_get_display_name(info))) { + if (g_file_info_has_attribute( + info, G_FILE_ATTRIBUTE_STANDARD_DISPLAY_NAME) && + (name = g_file_info_get_display_name(info))) { gchar *prefixed = get_prefixed_name(self, name); g_file_info_set_display_name(info, prefixed); g_free(prefixed); } - if ((name = g_file_info_get_edit_name(info))) { + if (g_file_info_has_attribute( + info, G_FILE_ATTRIBUTE_STANDARD_EDIT_NAME) && + (name = g_file_info_get_edit_name(info))) { gchar *prefixed = get_prefixed_name(self, name); g_file_info_set_edit_name(info, prefixed); g_free(prefixed); |