Poster of Linux kernelThe best gift for a Linux geek
GFS_RENAME

GFS_RENAME

Section: (3) Updated: 13 November 2006
Local index Up

 

NAME

gfs_rename - change the name or location of a file  

SYNOPSIS

#include <gfarm/gfarm.h>

char *gfs_rename (char * gfarm_url_from, char * gfarm_url_to);  

DESCRIPTION

gfs_rename renames a file or directory gfarm_url_from to gfarm_url_to.

If gfarm_url_to already exists, it will be replaced. In this case, when gfarm_url_from is a file gfarm_url_to also must be a file, when gfarm_url_from is a directory, gfarm_url_to must be a empty directory.

Gfs_rename() can't rename a directory to a subdirectory of itself.  

RETURN VALUES

NULL
The function terminated successfully.
GFARM_ERR_NO_MEMORY
Insufficient memory was available.
GFARM_ERR_AUTHENTICATION
User authentication failed when connecting to gfmd(8).
GFARM_ERR_PERMISSION_DENIED
The parent directory of gfarm_url_from or gfarm_url_to did not allow write permission.
GFARM_ERR_INVALID_ARGUMENT
A attempt was made to rename the directory gfarm_url_from to a subdirectory of itself.
GFARM_ERR_NO_SUCH_OBJECT
gfarm_url_from does not exist.
GFARM_ERR_IS_A_DIRECTORY
gfarm_url_to is a existing directory, though gfarm_url_from is not a directory.
GFARM_NOT_IS_A_DIRECTORY
gfarm_url_to is not a directory. though gfarm_url_from is a directory.
Others
An error except the above occurred. The reason is shown by its pointed strings.


 

Index

NAME
SYNOPSIS
DESCRIPTION
RETURN VALUES

This document was created by man2html, using the manual pages.
Time: 21:46:49 GMT, April 16, 2011