From d9ad59c0cdda160aaef6995cce387961ce8939ce Mon Sep 17 00:00:00 2001 From: Kotresh HR Date: Tue, 17 Sep 2019 15:35:21 +0530 Subject: posix/ctime: Fix coverity issue posix-metadata.c: 462 in posix_set_mdata_xattr() ... 460 GF_VALIDATE_OR_GOTO(this->name, time, out); 461 >>> CID 1405665: Control flow issues (DEADCODE) >>> Execution cannot reach the expression "flag->atime" inside this >>> statement: "if (update_utime && (flag->...". 462 if (update_utime && (flag->ctime && !time) && (flag->atime && !u_atime) && Change-Id: Id31d81d04ea2785a669eafe0dc1307303cb2271b updates: bz#789278 Signed-off-by: Kotresh HR --- xlators/storage/posix/src/posix-metadata.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'xlators/storage/posix') diff --git a/xlators/storage/posix/src/posix-metadata.c b/xlators/storage/posix/src/posix-metadata.c index 9efaf999402..63967cf3ade 100644 --- a/xlators/storage/posix/src/posix-metadata.c +++ b/xlators/storage/posix/src/posix-metadata.c @@ -459,7 +459,7 @@ posix_set_mdata_xattr(xlator_t *this, const char *real_path, int fd, GF_VALIDATE_OR_GOTO(this->name, inode, out); GF_VALIDATE_OR_GOTO(this->name, time, out); - if (update_utime && (flag->ctime && !time) && (flag->atime && !u_atime) && + if (update_utime && (flag->atime && !u_atime) && (flag->mtime && !u_mtime)) { goto out; } -- cgit