mirror of
https://github.com/s3fs-fuse/s3fs-fuse.git
synced 2024-11-09 22:30:57 +00:00
set uid/gid
git-svn-id: http://s3fs.googlecode.com/svn/trunk@128 df820570-a93a-0410-bd06-b72b767a4274
This commit is contained in:
parent
02896f886f
commit
54764721a1
@ -721,6 +721,9 @@ s3fs_getattr(const char *path, struct stat *stbuf) {
|
||||
if (S_ISREG(stbuf->st_mode))
|
||||
stbuf->st_blocks = stbuf->st_size / 512 + 1;
|
||||
|
||||
stbuf->st_uid = getuid();
|
||||
stbuf->st_gid = getgid();
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
@ -1226,6 +1229,9 @@ s3fs_readdir(const char *path, void *buf, fuse_fill_dir_t filler, off_t offset,
|
||||
if (S_ISREG(st.st_mode))
|
||||
st.st_blocks = st.st_size / 512 + 1;
|
||||
|
||||
st.st_uid = getuid();
|
||||
st.st_gid = getgid();
|
||||
|
||||
auto_lock lock(stat_cache_lock);
|
||||
stat_cache[stuff.path] = st;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user