[PATCH] fs: don't leak the parent path when openat() fails after the lookup
Sascha Hauer
s.hauer at pengutronix.de
Fri Aug 28 06:01:31 PDT 2026
On Wed, 26 Aug 2026 11:40:32 +0200, Ahmad Fatoum wrote:
> openat() jumps to out1 on three errors that happen after the lookup has
> succeeded, and none of them drops what the lookup took:
>
> - create() failing leaves both the negative dentry that filename_create()
> returned and the parent path it filled in.
> - The -ENOENT branch dputs the dentry, which is path.dentry here, but not
> the vfsmount reference held alongside it.
> - The -EISDIR branch drops nothing at all.
>
> [...]
Applied, thanks!
[1/1] fs: don't leak the parent path when openat() fails after the lookup
https://git.pengutronix.de/cgit/barebox/commit/?id=d1fc63ad66c4 (link may not be stable)
Best regards,
--
Sascha Hauer <s.hauer at pengutronix.de>
More information about the barebox
mailing list