aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Voss <mail@thomasvoss.com> 2024-06-21 23:59:52 +0200
committerThomas Voss <mail@thomasvoss.com> 2024-06-21 23:59:52 +0200
commitf97372e74a360eaef1fd86fd9968f62ebcbca709 (patch)
treefea5272f3fd3d7bef27a3859e0d466ca28a55677
parentaa66c30435ec9e76dad78b8b126ee51d00f4d429 (diff)
Reset errno to 0
-rw-r--r--cbs.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/cbs.h b/cbs.h
index 433c767..668db72 100644
--- a/cbs.h
+++ b/cbs.h
@@ -233,7 +233,7 @@ fmdcmp(const char *lhs, const char *rhs)
int errnol, errnor;
struct stat sbl, sbr;
- stat(lhs, &sbl); errnol = errno;
+ stat(lhs, &sbl); errnol = errno; errno = 0;
stat(rhs, &sbr); errnor = errno;
assert(errnol == 0 || errnol == ENOENT);