mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2024-11-11 03:46:17 +01:00
Merge branch '2227-more-annotations' into 'master'
Add more missing nullable annotations See merge request GNOME/glib!1811
This commit is contained in:
commit
7d96944c98
@ -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
|
||||
*/
|
||||
@ -507,7 +507,7 @@ g_credentials_set_native (GCredentials *credentials,
|
||||
* OS or if the native credentials type does not contain information
|
||||
* about the UNIX user.
|
||||
*
|
||||
* Returns: The UNIX user identifier or -1 if @error is set.
|
||||
* Returns: The UNIX user identifier or `-1` if @error is set.
|
||||
*
|
||||
* Since: 2.26
|
||||
*/
|
||||
@ -572,7 +572,7 @@ g_credentials_get_unix_user (GCredentials *credentials,
|
||||
* about the UNIX process ID (for example this is the case for
|
||||
* %G_CREDENTIALS_TYPE_APPLE_XUCRED).
|
||||
*
|
||||
* Returns: The UNIX process ID, or -1 if @error is set.
|
||||
* Returns: The UNIX process ID, or `-1` if @error is set.
|
||||
*
|
||||
* Since: 2.36
|
||||
*/
|
||||
|
@ -903,11 +903,14 @@ g_dbus_address_get_stream (const gchar *address,
|
||||
/**
|
||||
* g_dbus_address_get_stream_finish:
|
||||
* @res: A #GAsyncResult obtained from the GAsyncReadyCallback passed to g_dbus_address_get_stream().
|
||||
* @out_guid: (optional) (out): %NULL or return location to store the GUID extracted from @address, if any.
|
||||
* @out_guid: (optional) (out) (nullable): %NULL or return location to store the GUID extracted from @address, if any.
|
||||
* @error: Return location for error or %NULL.
|
||||
*
|
||||
* Finishes an operation started with g_dbus_address_get_stream().
|
||||
*
|
||||
* A server is not required to set a GUID, so @out_guid may be set to %NULL
|
||||
* even on success.
|
||||
*
|
||||
* Returns: (transfer full): A #GIOStream or %NULL if @error is set.
|
||||
*
|
||||
* Since: 2.26
|
||||
@ -940,7 +943,7 @@ g_dbus_address_get_stream_finish (GAsyncResult *res,
|
||||
/**
|
||||
* g_dbus_address_get_stream_sync:
|
||||
* @address: A valid D-Bus address.
|
||||
* @out_guid: (optional) (out): %NULL or return location to store the GUID extracted from @address, if any.
|
||||
* @out_guid: (optional) (out) (nullable): %NULL or return location to store the GUID extracted from @address, if any.
|
||||
* @cancellable: (nullable): A #GCancellable or %NULL.
|
||||
* @error: Return location for error or %NULL.
|
||||
*
|
||||
@ -949,6 +952,9 @@ g_dbus_address_get_stream_finish (GAsyncResult *res,
|
||||
* of the D-Bus authentication conversation. @address must be in the
|
||||
* [D-Bus address format](https://dbus.freedesktop.org/doc/dbus-specification.html#addresses).
|
||||
*
|
||||
* A server is not required to set a GUID, so @out_guid may be set to %NULL
|
||||
* even on success.
|
||||
*
|
||||
* This is a synchronous failable function. See
|
||||
* g_dbus_address_get_stream() for the asynchronous version.
|
||||
*
|
||||
|
@ -885,7 +885,7 @@ g_dbus_connection_class_init (GDBusConnectionClass *klass)
|
||||
*
|
||||
* If you are constructing a #GDBusConnection and pass
|
||||
* %G_DBUS_CONNECTION_FLAGS_AUTHENTICATION_SERVER in the
|
||||
* #GDBusConnection:flags property then you MUST also set this
|
||||
* #GDBusConnection:flags property then you **must** also set this
|
||||
* property to a valid guid.
|
||||
*
|
||||
* If you are constructing a #GDBusConnection and pass
|
||||
@ -1102,7 +1102,7 @@ g_dbus_connection_init (GDBusConnection *connection)
|
||||
* stream from a worker thread, so it is not safe to interact with
|
||||
* the stream directly.
|
||||
*
|
||||
* Returns: (transfer none): the stream used for IO
|
||||
* Returns: (transfer none) (not nullable): the stream used for IO
|
||||
*
|
||||
* Since: 2.26
|
||||
*/
|
||||
@ -2732,7 +2732,7 @@ g_dbus_connection_new (GIOStream *stream,
|
||||
*
|
||||
* Finishes an operation started with g_dbus_connection_new().
|
||||
*
|
||||
* Returns: a #GDBusConnection or %NULL if @error is set. Free
|
||||
* Returns: (transfer full): a #GDBusConnection or %NULL if @error is set. Free
|
||||
* with g_object_unref().
|
||||
*
|
||||
* Since: 2.26
|
||||
@ -2784,7 +2784,8 @@ g_dbus_connection_new_finish (GAsyncResult *res,
|
||||
* This is a synchronous failable constructor. See
|
||||
* g_dbus_connection_new() for the asynchronous version.
|
||||
*
|
||||
* Returns: a #GDBusConnection or %NULL if @error is set. Free with g_object_unref().
|
||||
* Returns: (transfer full): a #GDBusConnection or %NULL if @error is set.
|
||||
* Free with g_object_unref().
|
||||
*
|
||||
* Since: 2.26
|
||||
*/
|
||||
@ -2875,8 +2876,8 @@ g_dbus_connection_new_for_address (const gchar *address,
|
||||
*
|
||||
* Finishes an operation started with g_dbus_connection_new_for_address().
|
||||
*
|
||||
* Returns: a #GDBusConnection or %NULL if @error is set. Free with
|
||||
* g_object_unref().
|
||||
* Returns: (transfer full): a #GDBusConnection or %NULL if @error is set.
|
||||
* Free with g_object_unref().
|
||||
*
|
||||
* Since: 2.26
|
||||
*/
|
||||
@ -2927,8 +2928,8 @@ g_dbus_connection_new_for_address_finish (GAsyncResult *res,
|
||||
* If @observer is not %NULL it may be used to control the
|
||||
* authentication process.
|
||||
*
|
||||
* Returns: a #GDBusConnection or %NULL if @error is set. Free with
|
||||
* g_object_unref().
|
||||
* Returns: (transfer full): a #GDBusConnection or %NULL if @error is set.
|
||||
* Free with g_object_unref().
|
||||
*
|
||||
* Since: 2.26
|
||||
*/
|
||||
@ -3017,7 +3018,7 @@ g_dbus_connection_get_exit_on_close (GDBusConnection *connection)
|
||||
* The GUID of the peer performing the role of server when
|
||||
* authenticating. See #GDBusConnection:guid for more details.
|
||||
*
|
||||
* Returns: The GUID. Do not free this string, it is owned by
|
||||
* Returns: (not nullable): The GUID. Do not free this string, it is owned by
|
||||
* @connection.
|
||||
*
|
||||
* Since: 2.26
|
||||
@ -5510,7 +5511,7 @@ register_with_closures_on_set_property (GDBusConnection *connection,
|
||||
* Version of g_dbus_connection_register_object() using closures instead of a
|
||||
* #GDBusInterfaceVTable for easier binding in other languages.
|
||||
*
|
||||
* Returns: 0 if @error is set, otherwise a registration id (never 0)
|
||||
* Returns: 0 if @error is set, otherwise a registration ID (never 0)
|
||||
* that can be used with g_dbus_connection_unregister_object() .
|
||||
*
|
||||
* Since: 2.46
|
||||
@ -6139,8 +6140,8 @@ g_dbus_connection_call (GDBusConnection *connection,
|
||||
*
|
||||
* Finishes an operation started with g_dbus_connection_call().
|
||||
*
|
||||
* Returns: %NULL if @error is set. Otherwise a #GVariant tuple with
|
||||
* return values. Free with g_variant_unref().
|
||||
* Returns: (transfer full): %NULL if @error is set. Otherwise a non-floating
|
||||
* #GVariant tuple with return values. Free with g_variant_unref().
|
||||
*
|
||||
* Since: 2.26
|
||||
*/
|
||||
@ -6206,8 +6207,8 @@ g_dbus_connection_call_finish (GDBusConnection *connection,
|
||||
* g_dbus_connection_call() for the asynchronous version of
|
||||
* this method.
|
||||
*
|
||||
* Returns: %NULL if @error is set. Otherwise a #GVariant tuple with
|
||||
* return values. Free with g_variant_unref().
|
||||
* Returns: (transfer full): %NULL if @error is set. Otherwise a non-floating
|
||||
* #GVariant tuple with return values. Free with g_variant_unref().
|
||||
*
|
||||
* Since: 2.26
|
||||
*/
|
||||
@ -6309,8 +6310,8 @@ g_dbus_connection_call_with_unix_fd_list (GDBusConnection *connection,
|
||||
* access file descriptors if they are referenced in this way by a
|
||||
* value of type %G_VARIANT_TYPE_HANDLE in the body of the message.
|
||||
*
|
||||
* Returns: %NULL if @error is set. Otherwise a #GVariant tuple with
|
||||
* return values. Free with g_variant_unref().
|
||||
* Returns: (transfer full): %NULL if @error is set. Otherwise a non-floating
|
||||
* #GVariant tuple with return values. Free with g_variant_unref().
|
||||
*
|
||||
* Since: 2.30
|
||||
*/
|
||||
@ -6348,8 +6349,8 @@ g_dbus_connection_call_with_unix_fd_list_finish (GDBusConnection *connection,
|
||||
*
|
||||
* This method is only available on UNIX.
|
||||
*
|
||||
* Returns: %NULL if @error is set. Otherwise a #GVariant tuple with
|
||||
* return values. Free with g_variant_unref().
|
||||
* Returns: (transfer full): %NULL if @error is set. Otherwise a non-floating
|
||||
* #GVariant tuple with return values. Free with g_variant_unref().
|
||||
*
|
||||
* Since: 2.30
|
||||
*/
|
||||
@ -6859,8 +6860,8 @@ subtree_message_func (GDBusConnection *connection,
|
||||
* See this [server][gdbus-subtree-server] for an example of how to use
|
||||
* this method.
|
||||
*
|
||||
* Returns: 0 if @error is set, otherwise a subtree registration id (never 0)
|
||||
* that can be used with g_dbus_connection_unregister_subtree() .
|
||||
* Returns: 0 if @error is set, otherwise a subtree registration ID (never 0)
|
||||
* that can be used with g_dbus_connection_unregister_subtree()
|
||||
*
|
||||
* Since: 2.26
|
||||
*/
|
||||
|
@ -432,11 +432,11 @@ gboolean g_dbus_connection_unregister_object (GDBusConnection
|
||||
* specified (ie: to verify that the object path is valid).
|
||||
*
|
||||
* Hierarchies are not supported; the items that you return should not
|
||||
* contain the '/' character.
|
||||
* contain the `/` character.
|
||||
*
|
||||
* The return value will be freed with g_strfreev().
|
||||
*
|
||||
* Returns: A newly allocated array of strings for node names that are children of @object_path.
|
||||
* Returns: (array zero-terminated=1) (transfer full): A newly allocated array of strings for node names that are children of @object_path.
|
||||
*
|
||||
* Since: 2.26
|
||||
*/
|
||||
@ -472,7 +472,7 @@ typedef gchar** (*GDBusSubtreeEnumerateFunc) (GDBusConnection *connection,
|
||||
* remote introspector in the empty array case, but not in the %NULL
|
||||
* case.
|
||||
*
|
||||
* Returns: A %NULL-terminated array of pointers to #GDBusInterfaceInfo, or %NULL.
|
||||
* Returns: (array zero-terminated=1) (nullable) (transfer full): A %NULL-terminated array of pointers to #GDBusInterfaceInfo, or %NULL.
|
||||
*
|
||||
* Since: 2.26
|
||||
*/
|
||||
@ -497,7 +497,7 @@ typedef GDBusInterfaceInfo ** (*GDBusSubtreeIntrospectFunc) (GDBusConnection
|
||||
* Subtrees are flat. @node, if non-%NULL, is always exactly one
|
||||
* segment of the object path (ie: it never contains a slash).
|
||||
*
|
||||
* Returns: A #GDBusInterfaceVTable or %NULL if you don't want to handle the methods.
|
||||
* Returns: (nullable): A #GDBusInterfaceVTable or %NULL if you don't want to handle the methods.
|
||||
*
|
||||
* Since: 2.26
|
||||
*/
|
||||
|
@ -512,8 +512,8 @@ g_dbus_error_is_remote_error (const GError *error)
|
||||
* (e.g. g_dbus_connection_call_finish()) unless
|
||||
* g_dbus_error_strip_remote_error() has been used on @error.
|
||||
*
|
||||
* Returns: an allocated string or %NULL if the D-Bus error name
|
||||
* could not be found. Free with g_free().
|
||||
* Returns: (nullable) (transfer full): an allocated string or %NULL if the
|
||||
* D-Bus error name could not be found. Free with g_free().
|
||||
*
|
||||
* Since: 2.26
|
||||
*/
|
||||
@ -600,7 +600,7 @@ g_dbus_error_get_remote_error (const GError *error)
|
||||
* #GError instances for applications. Regular applications should not use
|
||||
* it.
|
||||
*
|
||||
* Returns: An allocated #GError. Free with g_error_free().
|
||||
* Returns: (transfer full): An allocated #GError. Free with g_error_free().
|
||||
*
|
||||
* Since: 2.26
|
||||
*/
|
||||
@ -810,7 +810,8 @@ g_dbus_error_strip_remote_error (GError *error)
|
||||
* This function is typically only used in object mappings to put a
|
||||
* #GError on the wire. Regular applications should not use it.
|
||||
*
|
||||
* Returns: A D-Bus error name (never %NULL). Free with g_free().
|
||||
* Returns: (transfer full) (not nullable): A D-Bus error name (never %NULL).
|
||||
* Free with g_free().
|
||||
*
|
||||
* Since: 2.26
|
||||
*/
|
||||
|
Loading…
Reference in New Issue
Block a user