mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-08-05 00:43:40 +02:00
filenumerator: Add g_file_enumerator_iterate()
This is *significantly* more pleasant to use from C (while handling errors and memory cleanup). While we're here, change some ugly, leaky code in tests/desktop-app-info.c to use it, in addition to a test case in tests/file.c. https://bugzilla.gnome.org/show_bug.cgi?id=661554
This commit is contained in:
@@ -139,6 +139,14 @@ GLIB_AVAILABLE_IN_2_36
|
||||
GFile * g_file_enumerator_get_child (GFileEnumerator *enumerator,
|
||||
GFileInfo *info);
|
||||
|
||||
GLIB_AVAILABLE_IN_2_44
|
||||
gboolean g_file_enumerator_iterate (GFileEnumerator *direnum,
|
||||
GFileInfo **out_info,
|
||||
GFile **out_child,
|
||||
GCancellable *cancellable,
|
||||
GError **error);
|
||||
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __G_FILE_ENUMERATOR_H__ */
|
||||
|
Reference in New Issue
Block a user