Skip to content

Commit

Permalink
cifs: remove redundant assignment to the variable match
Browse files Browse the repository at this point in the history
The variable match is being assigned a value that is never read, it
is being re-assigned a new value later on. The assignment is redundant
and can be removed.

Cleans up clang scan-build warning:
fs/cifs/dfs_cache.c:1302:2: warning: Value stored to 'match' is never read

Signed-off-by: Colin Ian King <colin.i.king@gmail.com>
Reviewed-by: Paulo Alcantara (SUSE) <pc@cjr.nz>
Signed-off-by: Steve French <stfrench@microsoft.com>
  • Loading branch information
Colin Ian King authored and Steve French committed Jan 10, 2023
1 parent ba5d4c1 commit 2f57e44
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion fs/cifs/dfs_cache.c
Original file line number Diff line number Diff line change
Expand Up @@ -1299,7 +1299,6 @@ static bool target_share_equal(struct TCP_Server_Info *server, const char *s1, c
* Resolve share's hostname and check if server address matches. Otherwise just ignore it
* as we could not have upcall to resolve hostname or failed to convert ip address.
*/
match = true;
extract_unc_hostname(s1, &host, &hostlen);
scnprintf(unc, sizeof(unc), "\\\\%.*s", (int)hostlen, host);

Expand Down

0 comments on commit 2f57e44

Please sign in to comment.