# \[PATCH RESEND\] ext4: remove 'error' variable in ext4\_xattr\_check\_block() function

- From: Zheng Liu \<hidden\>
- Date: 2012-01-16 09:12:32 
- List: linux-ext4
- Page: https://ratatoskr.run/linux-ext4/2012/01/13413982
- Thread: https://ratatoskr.run/linux-ext4/2012/01/13413982/t.md

```text
We can return from ext4_xattr_check_block() directly. Thus, we don't
need to define a 'error' variable.

CC: "Theodore Ts'o" <tytso@mit.edu>
Signed-off-by: Zheng Liu <redacted>
---
 fs/ext4/xattr.c |    5 +----
 1 files changed, 1 insertions(+), 4 deletions(-)

diff --git a/fs/ext4/xattr.c b/fs/ext4/xattr.c
index 93a00d8..1bff752 100644
--- a/fs/ext4/xattr.c
+++ b/fs/ext4/xattr.c
@@ -158,13 +158,10 @@ ext4_xattr_check_names(struct ext4_xattr_entry *entry, void *end)
 static inline int
 ext4_xattr_check_block(struct buffer_head *bh)
 {
-	int error;
```
