Merge pull request #106 from MRWITEK/main

Fix out of bounds access
This commit is contained in:
mhx 2022-10-20 17:04:46 +02:00 committed by GitHub
commit e86a44e3dd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -380,7 +380,7 @@ void op_readdir(fuse_req_t req, fuse_ino_t ino, size_t size, off_t off,
std::vector<char> buf(size);
size_t written = 0;
while (off < lastoff) {
while (off < lastoff && written < size) {
auto res = userdata->fs.readdir(*dir, off);
assert(res);