Skip to content

Commit

Permalink
Merge pull request #9404: hammer: mds: wrongly treat symlink inode as…
Browse files Browse the repository at this point in the history
… normal file/dir when symlink inode is stale on kcephfs

Reviewed-by: Nathan Cutler <ncutler@suse.com>
  • Loading branch information
smithfarm committed Jun 27, 2016
2 parents 7880209 + f6076dd commit 91466e1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/mds/Server.cc
Expand Up @@ -2747,7 +2747,7 @@ void Server::handle_client_open(MDRequestRef& mdr)
respond_to_request(mdr, -ENXIO); // FIXME what error do we want?
return;
}*/
if ((req->head.args.open.flags & O_DIRECTORY) && !cur->inode.is_dir()) {
if ((req->head.args.open.flags & O_DIRECTORY) && !cur->inode.is_dir() && !cur->inode.is_symlink()) {
dout(7) << "specified O_DIRECTORY on non-directory " << *cur << dendl;
respond_to_request(mdr, -EINVAL);
return;
Expand Down

0 comments on commit 91466e1

Please sign in to comment.