eventfs: Fix failure path in eventfs_create_events_dir()
authorSteven Rostedt (Google) <rostedt@goodmis.org>
Fri, 20 Oct 2023 00:41:32 +0000 (20:41 -0400)
committerSteven Rostedt (Google) <rostedt@goodmis.org>
Fri, 20 Oct 2023 14:04:01 +0000 (10:04 -0400)
commit7e8ad67c9b5c11e990c320ed7e7563f2301672a7
tree2e50d115c26d74b05b72d69a920b829342071c05
parentb8a555dc31e5aa18d976de0bc228006e398a2e7d
eventfs: Fix failure path in eventfs_create_events_dir()

The failure path of allocating ei goes to a path that dereferences ei.
Add another label that skips over the ei dereferences to do the rest of
the clean up.

Link: https://lore.kernel.org/all/70e7bace-561c-95f-1117-706c2c220bc@inria.fr/
Link: https://lore.kernel.org/linux-trace-kernel/20231019204132.6662fef0@gandalf.local.home
Cc: Masami Hiramatsu <mhiramat@kernel.org>
Cc: Mark Rutland <mark.rutland@arm.com>
Fixes: 5790b1fb3d67 ("eventfs: Remove eventfs_file and just use eventfs_inode")
Reported-by: Julia Lawall <julia.lawall@inria.fr>
Signed-off-by: Steven Rostedt (Google) <rostedt@goodmis.org>
fs/tracefs/event_inode.c