Actions
Bug #3257
openzfs_get_data has unsafe access to znode in debug build
Start date:
2012-10-04
Due date:
% Done:
0%
Estimated time:
Difficulty:
Bite-size
Tags:
needs-triage
Gerrit CR:
Description
In zfs_vnops.c, in the zfs_get_data() function, there is an unsafe access to a znode after dropping its vnode reference.
error = dmu_sync(zio, lr->lr_common.lrc_txg, zfs_get_done, zgd);
ASSERT(error || lr->lr_length <= zp->z_blksz);
The assertion is referencing zp but in zfs_get_done() callback the vnode reference was dropped. Upon return from dmu_sync() the znode could have already been recycled and changed type (no longer a file!) and the test "lr->lr_length <= zp->z_blksz" could fail!
Found running fstorture against a debug build of zfs.
Updated by Christopher Siden over 9 years ago
- Assignee set to Christopher Siden
Looking in to getting fstorture working on illumos.
Actions