From: Markus Elfring <elfring@xxxxxxxxxxxxxxxxxxxxx> Date: Tue, 15 Aug 2017 10:07:22 +0200 Replace a variable assignment by a goto statement so that an extra check will be avoided at the end of this function. Signed-off-by: Markus Elfring <elfring@xxxxxxxxxxxxxxxxxxxxx> --- net/9p/client.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/net/9p/client.c b/net/9p/client.c index 2ca55d4b0b7d..6c2fc796edfb 100644 --- a/net/9p/client.c +++ b/net/9p/client.c @@ -1237,12 +1237,11 @@ struct p9_fid *p9_client_walk(struct p9_fid *oldfid, uint16_t nwname, clunk_fid: kfree(wqids); p9_client_clunk(fid); - fid = NULL; - + goto exit; error: if (fid && (fid != oldfid)) p9_fid_destroy(fid); - +exit: return ERR_PTR(err); } EXPORT_SYMBOL(p9_client_walk); -- 2.14.0 -- To unsubscribe from this list: send the line "unsubscribe kernel-janitors" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html