doc: Clarify documentation regarding g_file_replace and etags

Clarify that with g_file_replace, a non-NULL etag is only checked if the
file already exists.

https://bugzilla.gnome.org/show_bug.cgi?id=736286
This commit is contained in:
Ross Lagerwall 2014-09-08 21:09:08 +01:00
parent 226c292b6a
commit 0728e62be8

View File

@ -1724,14 +1724,14 @@ g_file_create (GFile *file,
* operation was cancelled, the error %G_IO_ERROR_CANCELLED will be
* returned.
*
* If you pass in a non-%NULL @etag value, then this value is
* compared to the current entity tag of the file, and if they differ
* an %G_IO_ERROR_WRONG_ETAG error is returned. This generally means
* that the file has been changed since you last read it. You can get
* the new etag from g_file_output_stream_get_etag() after you've
* finished writing and closed the #GFileOutputStream. When you load
* a new file you can use g_file_input_stream_query_info() to get
* the etag of the file.
* If you pass in a non-%NULL @etag value and @file already exists, then
* this value is compared to the current entity tag of the file, and if
* they differ an %G_IO_ERROR_WRONG_ETAG error is returned. This
* generally means that the file has been changed since you last read
* it. You can get the new etag from g_file_output_stream_get_etag()
* after you've finished writing and closed the #GFileOutputStream. When
* you load a new file you can use g_file_input_stream_query_info() to
* get the etag of the file.
*
* If @make_backup is %TRUE, this function will attempt to make a
* backup of the current file before overwriting it. If this fails