Skip to contentSkip to conversation

can't boot with reiserfs on linux-4.6.0+

DISCUSSION Hillf Danton 2 participants 2 messages May 26, 2016 1 message not in the archive VFS

lore
Share & tools
lore
#1 lore raw
In reply to a message not in the archive
Quoted 10 lines
Quoted 10 lines

See if this fixes your reproducer.

fs/xattr.c +0 -0
index b11945e..49b8eab 100644
@@ -667,6 +667,9 @@ xattr_resolve_name(const struct xattr_handler **handlers, const char **name)
 {
        const struct xattr_handler *handler;
 
Quoted 9 lines

fs/xattr.c xattr_resolve_name(const struct xattr_handler **handlers, const char **name) · line 675

Quoted 6 lines
fs/xattr.c +3 -0
+       if (!handlers)
+               return NULL;
+
        if (!*name)
                return NULL;
 

Tried, but doesn't work.

See if this fixes your reproducer.

fs/xattr.c +2 -2
@@ -667,8 +667,8 @@ xattr_resolve_name(const struct xattr_ha
 {
 	const struct xattr_handler *handler;
 
-	if (!*name)
-		return NULL;
+	if (!handlers || !*name)
+		return ERR_PTR(-EINVAL);
 
 	for_each_xattr_handler(handlers, handler) {
 		const char *n;

--

#2 lore raw
Quoted 25 lines · Hillf Danton
Quoted 10 lines
Quoted 10 lines

See if this fixes your reproducer.

fs/xattr.c +0 -0
index b11945e..49b8eab 100644
@@ -667,6 +667,9 @@ xattr_resolve_name(const struct xattr_handler **handlers, const char **name)
 {
        const struct xattr_handler *handler;
 
Quoted 9 lines

fs/xattr.c xattr_resolve_name(const struct xattr_handler **handlers, const char **name) · line 675

Quoted 6 lines
fs/xattr.c +3 -0
+       if (!handlers)
+               return NULL;
+
        if (!*name)
                return NULL;
 

Tried, but doesn't work.

See if this fixes your reproducer.

fs/xattr.c Thu May 26 15:36:14 2016 renamed from fs/xattr.c Mon May 16 06:43:13 2016 +0 -0
@@ -667,8 +667,8 @@ xattr_resolve_name(const struct xattr_ha
 {

fs/xattr.c Thu May 26 15:36:14 2016 xattr_resolve_name(const struct xattr_ha

Quoted 10 lines
fs/xattr.c Thu May 26 15:36:14 2016 renamed from fs/xattr.c Mon May 16 06:43:13 2016 +2 -3
        const struct xattr_handler *handler;
 
-       if (!*name)
-               return NULL;
+       if (!handlers || !*name)
+               return ERR_PTR(-EINVAL);
 
        for_each_xattr_handler(handlers, handler) {
                const char *n;
--

Hillf,

That worked and it's already in Linus's latest tree.

Thanks for sharing.

Jeff