Merge from develop
This commit is contained in:
commit
d84e65ad76
@ -7,7 +7,12 @@ New Features:
|
|||||||
Improvements:
|
Improvements:
|
||||||
* Performance improvements
|
* Performance improvements
|
||||||
|
|
||||||
Version 0.9.7 (unreleased)
|
Version 0.9.8 (unreleased)
|
||||||
|
--------------
|
||||||
|
Fixed bugs:
|
||||||
|
* `du` shows correct file system size
|
||||||
|
|
||||||
|
Version 0.9.7
|
||||||
--------------
|
--------------
|
||||||
Compatibility:
|
Compatibility:
|
||||||
* Runs on FreeBSD
|
* Runs on FreeBSD
|
||||||
|
@ -163,10 +163,10 @@ void CryNode::stat(struct ::stat *result) const {
|
|||||||
device()->callFsActionCallbacks();
|
device()->callFsActionCallbacks();
|
||||||
if(_parent == none) {
|
if(_parent == none) {
|
||||||
//We are the root directory.
|
//We are the root directory.
|
||||||
//TODO What should we do?
|
//TODO What should we do?
|
||||||
result->st_uid = getuid();
|
result->st_uid = getuid();
|
||||||
result->st_gid = getgid();
|
result->st_gid = getgid();
|
||||||
result->st_mode = S_IFDIR | S_IRUSR | S_IWUSR | S_IXUSR;
|
result->st_mode = S_IFDIR | S_IRUSR | S_IWUSR | S_IXUSR;
|
||||||
result->st_size = fsblobstore::DirBlob::DIR_LSTAT_SIZE;
|
result->st_size = fsblobstore::DirBlob::DIR_LSTAT_SIZE;
|
||||||
//TODO If possible without performance loss, then for a directory, st_nlink should return number of dir entries (including "." and "..")
|
//TODO If possible without performance loss, then for a directory, st_nlink should return number of dir entries (including "." and "..")
|
||||||
result->st_nlink = 1;
|
result->st_nlink = 1;
|
||||||
|
@ -35,8 +35,8 @@ void CryOpenFile::flush() {
|
|||||||
|
|
||||||
void CryOpenFile::stat(struct ::stat *result) const {
|
void CryOpenFile::stat(struct ::stat *result) const {
|
||||||
_device->callFsActionCallbacks();
|
_device->callFsActionCallbacks();
|
||||||
_parent->statChildExceptSize(_fileBlob->key(), result);
|
|
||||||
result->st_size = _fileBlob->size();
|
result->st_size = _fileBlob->size();
|
||||||
|
_parent->statChildWithSizeAlreadySet(_fileBlob->key(), result);
|
||||||
}
|
}
|
||||||
|
|
||||||
void CryOpenFile::truncate(off_t size) const {
|
void CryOpenFile::truncate(off_t size) const {
|
||||||
|
@ -56,8 +56,8 @@ public:
|
|||||||
return _base->statChild(key, result);
|
return _base->statChild(key, result);
|
||||||
}
|
}
|
||||||
|
|
||||||
void statChildExceptSize(const blockstore::Key &key, struct ::stat *result) const {
|
void statChildWithSizeAlreadySet(const blockstore::Key &key, struct ::stat *result) const {
|
||||||
return _base->statChildExceptSize(key, result);
|
return _base->statChildWithSizeAlreadySet(key, result);
|
||||||
}
|
}
|
||||||
|
|
||||||
void updateAccessTimestampForChild(const blockstore::Key &key) {
|
void updateAccessTimestampForChild(const blockstore::Key &key) {
|
||||||
|
@ -135,11 +135,11 @@ off_t DirBlob::lstat_size() const {
|
|||||||
}
|
}
|
||||||
|
|
||||||
void DirBlob::statChild(const Key &key, struct ::stat *result) const {
|
void DirBlob::statChild(const Key &key, struct ::stat *result) const {
|
||||||
statChildExceptSize(key, result);
|
|
||||||
result->st_size = _getLstatSize(key);
|
result->st_size = _getLstatSize(key);
|
||||||
|
statChildWithSizeAlreadySet(key, result);
|
||||||
}
|
}
|
||||||
|
|
||||||
void DirBlob::statChildExceptSize(const Key &key, struct ::stat *result) const {
|
void DirBlob::statChildWithSizeAlreadySet(const Key &key, struct ::stat *result) const {
|
||||||
auto childOpt = GetChild(key);
|
auto childOpt = GetChild(key);
|
||||||
if (childOpt == boost::none) {
|
if (childOpt == boost::none) {
|
||||||
throw fspp::fuse::FuseErrnoException(ENOENT);
|
throw fspp::fuse::FuseErrnoException(ENOENT);
|
||||||
|
@ -58,7 +58,7 @@ namespace cryfs {
|
|||||||
|
|
||||||
void statChild(const blockstore::Key &key, struct ::stat *result) const;
|
void statChild(const blockstore::Key &key, struct ::stat *result) const;
|
||||||
|
|
||||||
void statChildExceptSize(const blockstore::Key &key, struct ::stat *result) const;
|
void statChildWithSizeAlreadySet(const blockstore::Key &key, struct ::stat *result) const;
|
||||||
|
|
||||||
void updateAccessTimestampForChild(const blockstore::Key &key);
|
void updateAccessTimestampForChild(const blockstore::Key &key);
|
||||||
|
|
||||||
|
@ -52,8 +52,8 @@ public:
|
|||||||
return _base->statChild(key, result);
|
return _base->statChild(key, result);
|
||||||
}
|
}
|
||||||
|
|
||||||
void statChildExceptSize(const blockstore::Key &key, struct ::stat *result) const {
|
void statChildWithSizeAlreadySet(const blockstore::Key &key, struct ::stat *result) const {
|
||||||
return _base->statChildExceptSize(key, result);
|
return _base->statChildWithSizeAlreadySet(key, result);
|
||||||
}
|
}
|
||||||
|
|
||||||
void updateAccessTimestampForChild(const blockstore::Key &key) {
|
void updateAccessTimestampForChild(const blockstore::Key &key) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user