the repository which powers this website
ui-repolist: do not return unsigned (negative) value
The function read_agefile() returns time_t, which is a signed datatime. We should not return unsigned (negative) value here. Reported-by: Johannes Stezenbach <[email protected]> Signed-off-by: Christian Hesse <[email protected]>
Christian Hesse 2019-11-22
parent bfabd45 · commit 583aa5d
-rw-r--r--ui-repolist.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/ui-repolist.c b/ui-repolist.c
index 7cf76389..529a2038 100644
--- a/ui-repolist.c
+++ b/ui-repolist.c
@@ -20,7 +20,7 @@ static time_t read_agefile(const char *path)
if (readfile(path, &buf, &size)) {
free(buf);
- return -1;
+ return 0;
}
if (parse_date(buf, &date_buf) == 0)