From affed015e1d885c16743b483e2993c819d73dc79 Mon Sep 17 00:00:00 2001 From: FrankHB Date: Tue, 2 Jun 2015 00:34:49 +0800 Subject: [PATCH] Removed redundant check `size_t` is guaranteed to be not negative. --- source/fatfile.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/fatfile.c b/source/fatfile.c index a3ed1ea..eeef416 100644 --- a/source/fatfile.c +++ b/source/fatfile.c @@ -602,7 +602,7 @@ static bool _FAT_check_position_for_next_cluster(struct _reent *r, // do nothing if no more data to write if (remain == 0) return true; if (flagNoError && *flagNoError == false) return false; - if ((remain < 0) || (position->sector > partition->sectorsPerCluster)) { + if (position->sector > partition->sectorsPerCluster) { // invalid arguments - internal error r->_errno = EINVAL; goto err;