Commit 95dd3730 authored by Sébastien Wilmet's avatar Sébastien Wilmet

docs: better documentation for g_file_info_copy_into()

The documentation of g_file_info_copy_into() was misleading. The
attributes are not just copied, @dest_info is also cleared at the
beginning. So any previously set attributes in @dest_info are lost.

There was a bug in gedit about this function, where some metadata were
not saved. So it might make sense to change the implementation to not
clear @dest_info, and copy one by one the attributes from @src_info to
parent f1405246
......@@ -365,8 +365,8 @@ g_file_info_new (void)
* @src_info: source to copy attributes from.
* @dest_info: destination to copy attributes to.
* Copies all of the [GFileAttribute][gio-GFileAttribute]
* from @src_info to @dest_info.
* First clears all of the [GFileAttribute][gio-GFileAttribute] of @dest_info,
* and then copies all of the file attributes from @src_info to @dest_info.
g_file_info_copy_into (GFileInfo *src_info,
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment