Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
There is a race window between f_count reaches 0 and we set f_count to INT_MIN. This race would result in multiple call to fp->close() and rcu_dispose(fp) if we call them in fdrop(). To fix, we set f_count to INT_MIN using CAS, this way, we make sure fp->close() and rcu_dispose(fp) won't be called twice. Fixes cloudius-systems#293. Signed-off-by: Asias He <[email protected]>
- Loading branch information