From: Steve French <smfrench@gmail.com>
To: SF Markus Elfring <elfring@users.sourceforge.net>
Cc: CIFS <linux-cifs@vger.kernel.org>,
samba-technical <samba-technical@lists.samba.org>,
Steve French <sfrench@samba.org>,
LKML <linux-kernel@vger.kernel.org>,
kernel-janitors <kernel-janitors@vger.kernel.org>
Subject: Re: [PATCH 6/8] CIFS: Return directly after a failed build_path_from_dentry() in cifs_do_create()
Date: Wed, 6 Nov 2019 21:34:30 -0600 [thread overview]
Message-ID: <CAH2r5msOyZXi6msPOPNnM4pF_YJEEOkxFk=dScUW0ZMuEvHFaQ@mail.gmail.com> (raw)
In-Reply-To: <24a10b1a-3b4a-da70-1670-23b4ec9abff8@users.sourceforge.net>
merged into cifs-2.6.git for-next
On Sun, Aug 20, 2017 at 11:40 AM SF Markus Elfring
<elfring@users.sourceforge.net> wrote:
>
> From: Markus Elfring <elfring@users.sourceforge.net>
> Date: Sun, 20 Aug 2017 17:17:30 +0200
>
> Return directly after a call of the function "build_path_from_dentry"
> failed at the beginning.
>
> Signed-off-by: Markus Elfring <elfring@users.sourceforge.net>
> ---
> fs/cifs/dir.c | 6 ++----
> 1 file changed, 2 insertions(+), 4 deletions(-)
>
> diff --git a/fs/cifs/dir.c b/fs/cifs/dir.c
> index 2c9cbd8393d6..248aead1f3f4 100644
> --- a/fs/cifs/dir.c
> +++ b/fs/cifs/dir.c
> @@ -239,10 +239,8 @@ cifs_do_create(struct inode *inode, struct dentry *direntry, unsigned int xid,
> *oplock = REQ_OPLOCK;
>
> full_path = build_path_from_dentry(direntry);
> - if (full_path == NULL) {
> - rc = -ENOMEM;
> - goto out;
> - }
> + if (!full_path)
> + return -ENOMEM;
>
> if (tcon->unix_ext && cap_unix(tcon->ses) && !tcon->broken_posix_open &&
> (CIFS_UNIX_POSIX_PATH_OPS_CAP &
> --
> 2.14.0
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-cifs" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
--
Thanks,
Steve
next prev parent reply other threads:[~2019-11-07 3:34 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-08-20 16:32 [PATCH 0/8] CIFS: Adjustments for several function implementations SF Markus Elfring
2017-08-20 16:33 ` [PATCH 1/8] CIFS: Delete 11 error messages for a failed memory allocation SF Markus Elfring
2017-08-20 16:38 ` [PATCH 4/8] CIFS: Use common error handling code in cifs_mknod() SF Markus Elfring
2017-08-20 16:39 ` [PATCH 5/8] CIFS: Less function calls in cifs_mknod() after error detection SF Markus Elfring
[not found] ` <826310e5-e01c-38af-90df-c5630f761a4d-Rn4VEauK+AKRv+LV9MX5uipxlwaOVQ5f@public.gmane.org>
2017-08-20 16:35 ` [PATCH 2/8] CIFS: Improve 27 size determinations SF Markus Elfring
2017-08-20 16:36 ` [PATCH 3/8] CIFS: One function call less in cifs_lookup() after error detection SF Markus Elfring
2017-08-20 16:40 ` [PATCH 6/8] CIFS: Return directly after a failed build_path_from_dentry() in cifs_do_create() SF Markus Elfring
2019-11-07 3:34 ` Steve French [this message]
2017-08-20 16:41 ` [PATCH 7/8] CIFS: Delete an unnecessary variable initialisation " SF Markus Elfring
2017-08-20 16:42 ` [PATCH 8/8] CIFS: One function call less in cifs_do_create() after error detection SF Markus Elfring
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CAH2r5msOyZXi6msPOPNnM4pF_YJEEOkxFk=dScUW0ZMuEvHFaQ@mail.gmail.com' \
--to=smfrench@gmail.com \
--cc=elfring@users.sourceforge.net \
--cc=kernel-janitors@vger.kernel.org \
--cc=linux-cifs@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=samba-technical@lists.samba.org \
--cc=sfrench@samba.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).