* [PATCH] CIFS: Fix error code in smb311_posix_mkdir()
@ 2018-06-21 15:01 Dan Carpenter
2018-06-21 16:59 ` Steve French
0 siblings, 1 reply; 2+ messages in thread
From: Dan Carpenter @ 2018-06-21 15:01 UTC (permalink / raw)
To: kernel-janitors
The error assignment needs to go before the goto.
Fixes: 5539e9b24a38 ("CIFS: fix memory leak and remove dead code")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
diff --git a/fs/cifs/smb2pdu.c b/fs/cifs/smb2pdu.c
index 062a2a59beb3..c9489b1160f0 100644
--- a/fs/cifs/smb2pdu.c
+++ b/fs/cifs/smb2pdu.c
@@ -1946,8 +1946,8 @@ int smb311_posix_mkdir(const unsigned int xid, struct inode *inode,
if (ses && (ses->server))
server = ses->server;
else {
- goto err_free_path;
rc = -EIO;
+ goto err_free_path;
}
/* resource #2: request */
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] CIFS: Fix error code in smb311_posix_mkdir()
2018-06-21 15:01 [PATCH] CIFS: Fix error code in smb311_posix_mkdir() Dan Carpenter
@ 2018-06-21 16:59 ` Steve French
0 siblings, 0 replies; 2+ messages in thread
From: Steve French @ 2018-06-21 16:59 UTC (permalink / raw)
To: kernel-janitors
merged the patches together
On Thu, Jun 21, 2018 at 10:01 AM, Dan Carpenter
<dan.carpenter@oracle.com> wrote:
> The error assignment needs to go before the goto.
>
> Fixes: 5539e9b24a38 ("CIFS: fix memory leak and remove dead code")
> Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
>
> diff --git a/fs/cifs/smb2pdu.c b/fs/cifs/smb2pdu.c
> index 062a2a59beb3..c9489b1160f0 100644
> --- a/fs/cifs/smb2pdu.c
> +++ b/fs/cifs/smb2pdu.c
> @@ -1946,8 +1946,8 @@ int smb311_posix_mkdir(const unsigned int xid, struct inode *inode,
> if (ses && (ses->server))
> server = ses->server;
> else {
> - goto err_free_path;
> rc = -EIO;
> + goto err_free_path;
> }
>
> /* resource #2: request */
> --
> 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
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2018-06-21 16:59 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-06-21 15:01 [PATCH] CIFS: Fix error code in smb311_posix_mkdir() Dan Carpenter
2018-06-21 16:59 ` Steve French
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.