aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Voss <mail@thomasvoss.com> 2024-06-21 23:59:24 +0200
committerThomas Voss <mail@thomasvoss.com> 2024-06-21 23:59:24 +0200
commit3d771ae059fde300345158d74a7e602ab45399db (patch)
tree502434502552bf05cf4c5ea98be79bf95bc33feb
parent8ecd0620e459473d09043871c500e639067e8152 (diff)
Reset errno to 0
-rw-r--r--cbs.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/cbs.h b/cbs.h
index 9220ed1..858982b 100644
--- a/cbs.h
+++ b/cbs.h
@@ -214,6 +214,7 @@ fmdcmp(const char *lhs, const char *rhs)
struct stat sbl, sbr;
stat(lhs, &sbl); errnol = errno;
+ errno = 0;
stat(rhs, &sbr); errnor = errno;
assert(errnol == 0 || errnol == ENOENT);