fs: Fix error checking for d_hash_and_lookup()
authorWang Ming <machel@vivo.com>
Thu, 13 Jul 2023 12:05:42 +0000 (20:05 +0800)
committerChristian Brauner <brauner@kernel.org>
Fri, 14 Jul 2023 15:01:23 +0000 (17:01 +0200)
commit0d5a4f8f775ff990142cdc810a84eae078589d27
tree592c7d3664dc4bbfcca7943ac49577c8408b4c33
parent5d1f903f75a80daa4dfb3d84e114ec8ecbf29956
fs: Fix error checking for d_hash_and_lookup()

The d_hash_and_lookup() function returns error pointers or NULL.
Most incorrect error checks were fixed, but the one in int path_pts()
was forgotten.

Fixes: eedf265aa003 ("devpts: Make each mount of devpts an independent filesystem.")
Signed-off-by: Wang Ming <machel@vivo.com>
Message-Id: <20230713120555.7025-1-machel@vivo.com>
Signed-off-by: Christian Brauner <brauner@kernel.org>
fs/namei.c