mirror of
https://github.com/MidnightCommander/mc
synced 2024-12-22 20:36:50 +03:00
(check_hardlinks): suspicious condition (assignment + comparison).
Clarify expression with parentheses. Found by cppcheck 1.81. Signed-off-by: Andreas Mohr <and@gmx.li> Signed-off-by: Andrew Borodin <aborodin@vmail.ru>
This commit is contained in:
parent
04e26ca78b
commit
371d69e8ba
@ -383,7 +383,7 @@ check_hardlinks (const vfs_path_t * src_vpath, const struct stat *src_stat,
|
||||
{
|
||||
gboolean ok;
|
||||
|
||||
while (!(ok = mc_stat (lnk->dst_vpath, &link_stat) == 0) && !*skip_all)
|
||||
while (!(ok = (mc_stat (lnk->dst_vpath, &link_stat) == 0)) && !*skip_all)
|
||||
{
|
||||
FileProgressStatus status;
|
||||
|
||||
@ -403,7 +403,7 @@ check_hardlinks (const vfs_path_t * src_vpath, const struct stat *src_stat,
|
||||
if (!ok)
|
||||
return HARDLINK_ERROR;
|
||||
|
||||
while (!(ok = mc_link (lnk->dst_vpath, dst_vpath) == 0) && !*skip_all)
|
||||
while (!(ok = (mc_link (lnk->dst_vpath, dst_vpath) == 0)) && !*skip_all)
|
||||
{
|
||||
FileProgressStatus status;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user