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
gboolean g_file_make_symbolic_link(GFile* file, const char* symlink_value,
                                   GCancellable* cancellable, GError** error)
{
    GFileIface* iface;

    g_return_val_if_fail(G_IS_FILE(file), FALSE);
    g_return_val_if_fail(symlink_value != NULL, FALSE);

    if (g_cancellable_set_error_if_cancelled(cancellable, error))
        return FALSE;

    if (*symlink_value == '\0')
    {
        g_set_error_literal(error, G_IO_ERROR, G_IO_ERROR_INVALID_ARGUMENT,
                            _("Invalid symlink value given"));
        return FALSE;
    }

    iface = G_FILE_GET_IFACE(file);

    if (iface->make_symbolic_link == NULL)
    {
        g_set_error_literal(error, G_IO_ERROR, G_IO_ERROR_NOT_SUPPORTED,
                            _("Operation not supported"));
        return FALSE;
    }

    return (*iface->make_symbolic_link)(file, symlink_value, cancellable,
                                        error);
}
/**
 * g_file_make_symbolic_link:
 * @file: a #GFile with the name of the symlink to create
 * @symlink_value: (type filename): a string with the path for the target
 *     of the new symlink
 * @cancellable: (nullable): optional #GCancellable object,
 *     %NULL to ignore
 * @error: a #GError
 *
 * Creates a symbolic link named @file which contains the string
 * @symlink_value.
 *
 * 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.
 *
 * Returns: %TRUE on the creation of a new symlink, %FALSE otherwise.
 */


Creates a symbolic link named @file which contains the string
@symlink_value.

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.

%TRUE on the creation of a new symlink, %FALSE otherwise.
Creates a symbolic link named @file which contains the string @symlink_value . 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 . %TRUE on the creation of a new symlink %FALSE otherwise .
gboolean g_file_make_symbolic_link(GFile* file, const char* symlink_value,
                                   GCancellable* cancellable, GError** error)
{
    GFileIface* iface;
    g_return_val_if_fail(G_IS_FILE(file), FALSE);
    g_return_val_if_fail(symlink_value != NULL, FALSE);
    if (g_cancellable_set_error_if_cancelled(cancellable, error))
        return FALSE;
    if (*symlink_value == '\0')
    {
        g_set_error_literal(error, G_IO_ERROR, G_IO_ERROR_INVALID_ARGUMENT,
                            _("Invalid symlink value given"));
        return FALSE;
    }
    iface = G_FILE_GET_IFACE(file);
    if (iface->make_symbolic_link == NULL)
    {
        g_set_error_literal(error, G_IO_ERROR, G_IO_ERROR_NOT_SUPPORTED,
                            _("Operation not supported"));
        return FALSE;
    }
    return (*iface->make_symbolic_link)(file, symlink_value, cancellable,
                                        error);
}
gboolean g_file_make_symbolic_link ( GFile * file , const char * symlink_value , GCancellable * cancellable , GError * * error ) { GFileIface * iface ; g_return_val_if_fail ( G_IS_FILE ( file ) , FALSE ) ; g_return_val_if_fail ( symlink_value != NULL , FALSE ) ; if ( g_cancellable_set_error_if_cancelled ( cancellable , error ) ) return FALSE ; if ( * symlink_value == ' \0 ' ) { g_set_error_literal ( error , G_IO_ERROR , G_IO_ERROR_INVALID_ARGUMENT , _ ( " " ) ) ; return FALSE ; } iface = G_FILE_GET_IFACE ( file ) ; if ( iface -> make_symbolic_link == NULL ) { g_set_error_literal ( error , G_IO_ERROR , G_IO_ERROR_NOT_SUPPORTED , _ ( " " ) ) ; return FALSE ; } return ( * iface -> make_symbolic_link ) ( file , symlink_value , cancellable , error ) ; }
g_file_make_symbolic_link:
 @file: a #GFile with the name of the symlink to create
 @symlink_value: (type filename): a string with the path for the target
     of the new symlink
 @cancellable: (nullable): optional #GCancellable object,
     %NULL to ignore
 @error: a #GError
g_file_make_symbolic_link : @file : a #GFile with the name of the symlink to create @symlink_value : ( type filename ) : a string with the path for the target of the new symlink @cancellable : ( nullable ) : optional #GCancellable object %NULL to ignore @error : a #GError