Fix use-after-free with log and quotas
Destroying the quota stuff on unmount can access the log - ie XFS_QM_DONE()
ends up in xfs_dqunlock() which calls xfs_trans_unlocked_item() and then
xfs_log_move_tail(). By this time the log has already been destroyed.
Just move the cleanup of the quota code earlier in xfs_unmountfs() before
the call to xfs_log_unmount(). Moving XFS_QM_DONE() up near
XFS_QM_DQPURGEALL() seems like a good spot.
Date: Thu Sep 18 17:35:23 AEST 2008
The following file(s) were checked into:
fs/xfs/xfs_mount.c - 1.446 - changed
- Fix use-after-free with log and quotas