GNOME Bugzilla – Bug 733528
g_file_enumerate_children does not automatically include file name attribues on windows, but it does on linux
Last modified: 2018-05-24 16:47:19 UTC
If you call g_file_enumerate_children like this: g_file_enumerate_children (dir, G_FILE_ATTRIBUTE_STANDARD_IS_HIDDEN "," G_FILE_ATTRIBUTE_STANDARD_TYPE, G_FILE_QUERY_INFO_NONE, NULL, NULL); then the GFileInfos in the returned enumerator will have their name attribute available on linux, but not on windows. (Note that the original call did not include G_FILE_ATTRIBUTE_STANDARD_NAME) In other words, calling g_file_info_get_name will return null on windows, but will return the correct filename on linux, whenever G_FILE_ATTRIBUTE_STANDARD_NAME is not requested. I'm not sure what the desired behavior is, but linux and windows should probably behave the same. (When G_FILE_ATTRIBUTE_STANDARD_NAME is passed to g_file_enumerate_children, both platforms behave identically and will return the file name.)
-- GitLab Migration Automatic Message -- This bug has been migrated to GNOME's GitLab instance and has been closed from further activity. You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.gnome.org/GNOME/glib/issues/902.