Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
DebugFS : more file/directory creation error handling
Correct dentry count to handle creation errors. This patch puts a dput at the file creation instead of the file removal : lookup_one_len already returns a dentry with reference count of 1. Then, the dget() in simple_mknod increments it when the dentry is associated with a file. In a scenario where simple_create or simple_mkdir returns an error, this would lead to an unwanted increment of the reference counter, therefore making file removal impossible. Signed-off-by: Mathieu Desnoyers <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
- Loading branch information