f2fs: don't let the orphan inode counter underflow
authorRuss W. Knize <russ@knizefamily.net>
Tue, 24 Sep 2013 14:35:40 +0000 (09:35 -0500)
committerJaegeuk Kim <jaegeuk.kim@samsung.com>
Wed, 25 Sep 2013 08:49:12 +0000 (17:49 +0900)
Accounting errors from buggy code calling the acquire/release/remove
orphan inode interfaces can cause n_orphans to underflow, which will
then cause acquire_orphan_inode() to return -ENOSPC on the next
operation.  This commit guards against that condition.

Signed-off-by: Russ Knize <rknize@motorola.com>
Signed-off-by: Jaegeuk Kim <jaegeuk.kim@samsung.com>

No differences found