openbmc/build/tmp/deploy/sdk/witherspoon-2019-08-08/sysroots/armv6-openbmc-linux-gnueabi/usr/src/debug/glib-2.0/1_2.60.3-r0/glib-2.60.3/gio/gfile.c
void g_file_load_partial_contents_async(
    GFile* file, GCancellable* cancellable,
    GFileReadMoreCallback read_more_callback, GAsyncReadyCallback callback,
    gpointer user_data)
{
    LoadContentsData* data;

    g_return_if_fail(G_IS_FILE(file));

    data = g_new0(LoadContentsData, 1);
    data->read_more_callback = read_more_callback;
    data->content = g_byte_array_new();

    data->task = g_task_new(file, cancellable, callback, user_data);
    g_task_set_source_tag(data->task, g_file_load_partial_contents_async);
    g_task_set_task_data(data->task, data,
                         (GDestroyNotify)load_contents_data_free);

    g_file_read_async(file, 0, g_task_get_cancellable(data->task),
                      load_contents_open_callback, data);
}
/**
 * g_file_load_partial_contents_async: (skip)
 * @file: input #GFile
 * @cancellable: optional #GCancellable object, %NULL to ignore
 * @read_more_callback: (scope call) (closure user_data): a
 *     #GFileReadMoreCallback to receive partial data
 *     and to specify whether further data should be read
 * @callback: (scope async) (closure user_data): a #GAsyncReadyCallback to call
 *     when the request is satisfied
 * @user_data: the data to pass to the callback functions
 *
 * Reads the partial contents of a file. A #GFileReadMoreCallback should
 * be used to stop reading from the file when appropriate, else this
 * function will behave exactly as g_file_load_contents_async(). This
 * operation can be finished by g_file_load_partial_contents_finish().
 *
 * Users of this function should be aware that @user_data is passed to
 * both the @read_more_callback and the @callback.
 *
 * If @cancellable is not %NULL, then the operation can be cancelled by
 * triggering the cancellable object from another thread. If the operation
 * was cancelled, the error %G_IO_ERROR_CANCELLED will be returned.
 */


Reads the partial contents of a file. A #GFileReadMoreCallback should
be used to stop reading from the file when appropriate, else this
function will behave exactly as g_file_load_contents_async(). This
operation can be finished by g_file_load_partial_contents_finish().

Users of this function should be aware that @user_data is passed to
both the @read_more_callback and the @callback.

If @cancellable is not %NULL, then the operation can be cancelled by
triggering the cancellable object from another thread. If the operation
was cancelled, the error %G_IO_ERROR_CANCELLED will be returned.
Reads the partial contents of a file . A #GFileReadMoreCallback should be used to stop reading from the file when appropriate else this function will behave exactly as g_file_load_contents_async () . This operation can be finished by g_file_load_partial_contents_finish () . Users of this function should be aware that @user_data is passed to both the @read_more_callback and the @callback . If @cancellable is not %NULL then the operation can be cancelled by triggering the cancellable object from another thread . If the operation was cancelled the error %G_IO_ERROR_CANCELLED will be returned .
void g_file_load_partial_contents_async(
    GFile* file, GCancellable* cancellable,
    GFileReadMoreCallback read_more_callback, GAsyncReadyCallback callback,
    gpointer user_data)
{
    LoadContentsData* data;
    g_return_if_fail(G_IS_FILE(file));
    data = g_new0(LoadContentsData, 1);
    data->read_more_callback = read_more_callback;
    data->content = g_byte_array_new();
    data->task = g_task_new(file, cancellable, callback, user_data);
    g_task_set_source_tag(data->task, g_file_load_partial_contents_async);
    g_task_set_task_data(data->task, data,
                         (GDestroyNotify)load_contents_data_free);
    g_file_read_async(file, 0, g_task_get_cancellable(data->task),
                      load_contents_open_callback, data);
}
void g_file_load_partial_contents_async ( GFile * file , GCancellable * cancellable , GFileReadMoreCallback read_more_callback , GAsyncReadyCallback callback , gpointer user_data ) { LoadContentsData * data ; g_return_if_fail ( G_IS_FILE ( file ) ) ; data = g_new0 ( LoadContentsData , 1 ) ; data -> read_more_callback = read_more_callback ; data -> content = g_byte_array_new ( ) ; data -> task = g_task_new ( file , cancellable , callback , user_data ) ; g_task_set_source_tag ( data -> task , g_file_load_partial_contents_async ) ; g_task_set_task_data ( data -> task , data , ( GDestroyNotify ) load_contents_data_free ) ; g_file_read_async ( file , 0 , g_task_get_cancellable ( data -> task ) , load_contents_open_callback , data ) ; }
g_file_load_partial_contents_async: (skip)
 @file: input #GFile
 @cancellable: optional #GCancellable object, %NULL to ignore
 @read_more_callback: (scope call) (closure user_data): a
     #GFileReadMoreCallback to receive partial data
     and to specify whether further data should be read
 @callback: (scope async) (closure user_data): a #GAsyncReadyCallback to call
     when the request is satisfied
 @user_data: the data to pass to the callback functions
g_file_load_partial_contents_async : ( skip ) @file : input #GFile @cancellable : optional #GCancellable object %NULL to ignore @read_more_callback : ( scope call ) ( closure user_data ) : a #GFileReadMoreCallback to receive partial data and to specify whether further data should be read @callback : ( scope async ) ( closure user_data ) : a #GAsyncReadyCallback to call when the request is satisfied @user_data : the data to pass to the callback functions