#include "gsimpleasyncresult.h"
-#include "gioalias.h"
G_DEFINE_ABSTRACT_TYPE (GSocketAddressEnumerator, g_socket_address_enumerator, G_TYPE_OBJECT);
* internal errors (other than @cancellable being triggered) will be
* ignored.
*
- * Return value: a #GSocketAddress (owned by the caller), or %NULL on
+ * Return value: (transfer full): a #GSocketAddress (owned by the caller), or %NULL on
* error (in which case *@error will be set) or if there are no
* more addresses.
*/
if (address)
g_simple_async_result_set_op_res_gpointer (result, address, NULL);
else if (error)
- {
- g_simple_async_result_set_from_error (result, error);
- g_error_free (error);
- }
+ g_simple_async_result_take_error (result, error);
+
g_simple_async_result_complete_in_idle (result);
g_object_unref (result);
}
* g_socket_address_enumerator_next() for more information about
* error handling.
*
- * Return value: a #GSocketAddress (owned by the caller), or %NULL on
+ * Return value: (transfer full): a #GSocketAddress (owned by the caller), or %NULL on
* error (in which case *@error will be set) or if there are no
* more addresses.
*/
return (* klass->next_finish) (enumerator, result, error);
}
-
-#define __G_SOCKET_ADDRESS_ENUMERATOR_C__
-#include "gioaliasdef.c"