nfs4: Notify listeners when file grows
This commit is contained in:
parent
90213f44ac
commit
b637b72e15
@ -75,7 +75,13 @@ void
|
|||||||
MetadataCache::GrowFile(size_t newSize)
|
MetadataCache::GrowFile(size_t newSize)
|
||||||
{
|
{
|
||||||
MutexLocker _(fLock);
|
MutexLocker _(fLock);
|
||||||
|
off_t oldSize = fStatCache.st_size;
|
||||||
fStatCache.st_size = max_c((off_t)newSize, fStatCache.st_size);
|
fStatCache.st_size = max_c((off_t)newSize, fStatCache.st_size);
|
||||||
|
|
||||||
|
if (oldSize != fStatCache.st_size) {
|
||||||
|
notify_stat_changed(fInode->GetFileSystem()->DevId(), fInode->ID(),
|
||||||
|
B_STAT_SIZE);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user