From 0f8ef77e919ff21eea4353e95fce97cc5f693d1d Mon Sep 17 00:00:00 2001 From: Eugene Crosser Date: Fri, 15 Nov 2013 17:56:31 +0400 Subject: [PATCH] fix fstat error check --- authfile.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/authfile.c b/authfile.c index f1ac150..83477e4 100644 --- a/authfile.c +++ b/authfile.c @@ -43,7 +43,7 @@ int update_authfile(const char *fn, const char *tokenid, const char *id, struct stat st; int fd = fileno(fp); - if (!fstat(fd, &st)) { + if (fstat(fd, &st)) { eprint("fstat \"%s\" (fd %d) error: %s", fn, fd, strerror(errno)); st.st_size = 2047; -- 2.39.2