mirror of
https://github.com/trapexit/mergerfs.git
synced 2026-11-25 17:36:25 -05:00
checkpoint
This commit is contained in:
parent
2ae212ae81
commit
cba7433166
35 changed files with 115 additions and 108 deletions
|
|
@ -22,16 +22,12 @@
|
|||
#include "fs_path.hpp"
|
||||
#include "fuse_getattr.hpp"
|
||||
#include "fuse_symlink.hpp"
|
||||
#include "ghc/filesystem.hpp"
|
||||
#include "state.hpp"
|
||||
#include "ugid.hpp"
|
||||
|
||||
#include "fuse.h"
|
||||
|
||||
|
||||
namespace gfs = ghc::filesystem;
|
||||
|
||||
|
||||
namespace l
|
||||
{
|
||||
static
|
||||
|
|
@ -151,13 +147,17 @@ namespace FUSE::LINK
|
|||
{
|
||||
int rv;
|
||||
State s;
|
||||
gfs::path oldpath;
|
||||
gfs::path newpath;
|
||||
const fuse_context *fc = fuse_get_context();
|
||||
const ugid::Set ugid(fc->uid,fc->gid);
|
||||
|
||||
rv = s->link(oldpath_,newpath_);
|
||||
oldpath = &oldpath_[1];
|
||||
newpath = &newpath_[1];
|
||||
rv = s->link(oldpath,newpath);
|
||||
if(rv == -EXDEV)
|
||||
return l::link_exdev(s,oldpath_,newpath_,st_,timeouts_);
|
||||
|
||||
return s->getattr(newpath_,st_,timeouts_);
|
||||
return s->getattr(newpath,st_,timeouts_);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue