public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] smb: client: Omit one redundant variable assignment in cifs_xattr_set()
@ 2025-10-10 12:56 Markus Elfring
  2025-10-11 20:02 ` Steve French
  0 siblings, 1 reply; 2+ messages in thread
From: Markus Elfring @ 2025-10-10 12:56 UTC (permalink / raw)
  To: linux-cifs, samba-technical, Bharath SM, Boris Protopopov,
	Paulo Alcantara, Ronnie Sahlberg, Shyam Prasad N, Steve French,
	Tom Talpey
  Cc: LKML, kernel-janitors

From: Markus Elfring <elfring@users.sourceforge.net>
Date: Fri, 10 Oct 2025 14:48:13 +0200

The local variable “rc” is assigned a value in an if branch without
using it before it is reassigned there.
Thus delete this assignment statement.

Signed-off-by: Markus Elfring <elfring@users.sourceforge.net>
---
 fs/smb/client/xattr.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/fs/smb/client/xattr.c b/fs/smb/client/xattr.c
index b88fa04f5792..029910d56c22 100644
--- a/fs/smb/client/xattr.c
+++ b/fs/smb/client/xattr.c
@@ -178,7 +178,6 @@ static int cifs_xattr_set(const struct xattr_handler *handler,
 			memcpy(pacl, value, size);
 			if (pTcon->ses->server->ops->set_acl) {
 				int aclflags = 0;
-				rc = 0;
 
 				switch (handler->flags) {
 				case XATTR_CIFS_NTSD_FULL:
-- 
2.51.0


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] smb: client: Omit one redundant variable assignment in cifs_xattr_set()
  2025-10-10 12:56 [PATCH] smb: client: Omit one redundant variable assignment in cifs_xattr_set() Markus Elfring
@ 2025-10-11 20:02 ` Steve French
  0 siblings, 0 replies; 2+ messages in thread
From: Steve French @ 2025-10-11 20:02 UTC (permalink / raw)
  To: Markus Elfring
  Cc: linux-cifs, samba-technical, Bharath SM, Boris Protopopov,
	Paulo Alcantara, Ronnie Sahlberg, Shyam Prasad N, Steve French,
	Tom Talpey, LKML, kernel-janitors

merged into cifs-2.6.git for-next

On Fri, Oct 10, 2025 at 7:56 AM Markus Elfring <Markus.Elfring@web.de> wrote:
>
> From: Markus Elfring <elfring@users.sourceforge.net>
> Date: Fri, 10 Oct 2025 14:48:13 +0200
>
> The local variable “rc” is assigned a value in an if branch without
> using it before it is reassigned there.
> Thus delete this assignment statement.
>
> Signed-off-by: Markus Elfring <elfring@users.sourceforge.net>
> ---
>  fs/smb/client/xattr.c | 1 -
>  1 file changed, 1 deletion(-)
>
> diff --git a/fs/smb/client/xattr.c b/fs/smb/client/xattr.c
> index b88fa04f5792..029910d56c22 100644
> --- a/fs/smb/client/xattr.c
> +++ b/fs/smb/client/xattr.c
> @@ -178,7 +178,6 @@ static int cifs_xattr_set(const struct xattr_handler *handler,
>                         memcpy(pacl, value, size);
>                         if (pTcon->ses->server->ops->set_acl) {
>                                 int aclflags = 0;
> -                               rc = 0;
>
>                                 switch (handler->flags) {
>                                 case XATTR_CIFS_NTSD_FULL:
> --
> 2.51.0
>
>


-- 
Thanks,

Steve

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2025-10-11 20:02 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-10-10 12:56 [PATCH] smb: client: Omit one redundant variable assignment in cifs_xattr_set() Markus Elfring
2025-10-11 20:02 ` Steve French

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox