Improve g_file_set_contents docs
authorMatthias Clasen <mclasen@redhat.com>
Thu, 26 Aug 2010 04:00:56 +0000 (00:00 -0400)
committerMatthias Clasen <mclasen@redhat.com>
Thu, 26 Aug 2010 04:00:56 +0000 (00:00 -0400)
Mention that the temporary filename is longer than the passed-in
filename, so people can avoid passing a name that is already
NAME_MAX long.

glib/gfileutils.c

index bfd6bb6..820ed95 100644 (file)
@@ -1056,6 +1056,9 @@ write_to_temp_file (const gchar  *contents,
  * it returns %FALSE and sets @error. The error domain is #G_FILE_ERROR.
  * Possible error codes are those in the #GFileError enumeration.
  *
+ * Note that the name for the temporary file is constructed by appending up
+ * to 7 characters to @filename.
+ *
  * Return value: %TRUE on success, %FALSE if an error occurred
  *
  * Since: 2.8