Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

rbd-fuse: implement mv operation #6938

Merged
merged 3 commits into from Dec 21, 2015
Merged

rbd-fuse: implement mv operation #6938

merged 3 commits into from Dec 21, 2015

Conversation

wuxiangwei
Copy link

implement mv operation for rbd-fuse to rename image.

Signed-off-by: Xiangwei Wu wuxiangwei@h3c.com

implement mv operation for rbd-fuse to rename image.

Signed-off-by: Xiangwei Wu wuxiangwei@h3c.com
@ghost ghost added rbd feature labels Dec 15, 2015
@dillaman
Copy link

@wuxiangwei Can you add some validation for the destination image name? It shouldn't be blank and shouldn't contain "/" nor "@" characters.

add validation for destination image name to
avoid image name contains invalid characters, such as "/" and "@".

Signed-off-by: Xiangwei Wu wuxiangwei@h3c.com
@wuxiangwei
Copy link
Author

@dillaman i have add validation for destination image name, please take a look. thank you.

@dillaman dillaman changed the title rbd: implement mv operation for rbd-fuse rbd-fuse: implement mv operation Dec 16, 2015
int rbdfs_rename(const char *path, const char *destname)
{
const char *srcname = NULL;
const char *extra[] = {" ", "@", "/"};

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think there is any restriction for spaces in the image name -- at least the rbd CLI doesn't restrict it.

discard space restriction for destination image name of
the mv operation.

Signed-off-by: Xiangwei Wu wuxiangwei@h3c.com
@wuxiangwei
Copy link
Author

@dillaman hi, i have remove the restriction for spaces in the image name , please check again, thank you .

dillaman pushed a commit that referenced this pull request Dec 21, 2015
rbd-fuse: implement mv operation

Reviewed-by: Jason Dillaman <dillaman@redhat.com>
@dillaman dillaman merged commit fbac817 into ceph:master Dec 21, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants