You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@avro.apache.org by dk...@apache.org on 2020/05/21 13:45:04 UTC
[avro] 02/02: [AVRO-2486] Don't ignore fwrite error
This is an automated email from the ASF dual-hosted git repository.
dkulp pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/avro.git
commit 5e8537c3363a8fe3076295e5c8f3ae229991314f
Author: Daniel Kulp <dk...@apache.org>
AuthorDate: Thu May 21 09:42:28 2020 -0400
[AVRO-2486] Don't ignore fwrite error
---
lang/c/src/io.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lang/c/src/io.c b/lang/c/src/io.c
index 00c6857..c1e2f5d 100644
--- a/lang/c/src/io.c
+++ b/lang/c/src/io.c
@@ -345,7 +345,7 @@ avro_write_file(struct _avro_writer_file_t *writer, void *buf, int64_t len)
if (len > 0) {
rval = fwrite(buf, len, 1, writer->fp);
if (rval == 0) {
- return feof(writer->fp) ? EOF : 0;
+ return EIO;
}
}
return 0;