docs: Fix (nullable) (optional) annotations

There are a few places where commit 18a33f72 replaced valid (nullable)
(optional) annotations with just (optional). That has a different
meaning.

(nullable) (optional) can only be applied to gpointer* parameters, and
means that both the gpointer* and returned gpointer can be NULL. i.e.
The caller can pass in NULL to ignore the return value; and the returned
value can be NULL.

(optional) can be applied to anything* parameters, and means that the
anything* can be NULL. i.e. The caller can pass in NULL to ignore the
return value. The return value cannot be NULL.

Signed-off-by: Philip Withnall <withnall@endlessm.com>
This commit is contained in:
Philip Withnall
2017-04-28 12:29:44 +01:00
parent 88ad0dab21
commit b63469d726
6 changed files with 14 additions and 14 deletions

View File

@@ -5264,8 +5264,8 @@ g_socket_receive_messages_with_timeout (GSocket *socket,
* pointer, or %NULL
* @vectors: (array length=num_vectors): an array of #GInputVector structs
* @num_vectors: the number of elements in @vectors, or -1
* @messages: (array length=num_messages) (out) (optional): a pointer which
* may be filled with an array of #GSocketControlMessages, or %NULL
* @messages: (array length=num_messages) (out) (optional) (nullable): a pointer
* which may be filled with an array of #GSocketControlMessages, or %NULL
* @num_messages: (out): a pointer which will be filled with the number of
* elements in @messages, or %NULL
* @flags: (inout): a pointer to an int containing #GSocketMsgFlags flags