gcredentials: Add missing (transfer) and (nullable) return annotations

This commit only looks at the `Returns:` lines in the documentation, and
has examined all of them in the file. Function arguments have not been
checked.

Signed-off-by: Philip Withnall <pwithnall@endlessos.org>

Helps: #2227
This commit is contained in:
Philip Withnall 2020-12-15 09:09:59 +00:00
parent 784f968895
commit 2a76f01698

View File

@ -196,7 +196,7 @@ g_credentials_init (GCredentials *credentials)
* Creates a new #GCredentials object with credentials matching the
* the current process.
*
* Returns: A #GCredentials. Free with g_object_unref().
* Returns: (transfer full): A #GCredentials. Free with g_object_unref().
*
* Since: 2.26
*/
@ -216,7 +216,7 @@ g_credentials_new (void)
* that can be used in logging and debug messages. The format of the
* returned string may change in future GLib release.
*
* Returns: A string that should be freed with g_free().
* Returns: (transfer full): A string that should be freed with g_free().
*
* Since: 2.26
*/
@ -435,10 +435,10 @@ credentials_native_type_check (GCredentialsType requested_type,
* logged) to use this method if there is no #GCredentials support for
* the OS or if @native_type isn't supported by the OS.
*
* Returns: The pointer to native credentials or %NULL if the
* operation there is no #GCredentials support for the OS or if
* @native_type isn't supported by the OS. Do not free the returned
* data, it is owned by @credentials.
* Returns: (transfer none) (nullable): The pointer to native credentials or
* %NULL if there is no #GCredentials support for the OS or if @native_type
* isn't supported by the OS. Do not free the returned data, it is owned
* by @credentials.
*
* Since: 2.26
*/