diff options
-rw-r--r-- | cmd-line-utils/readline/complete.c | 3 | ||||
-rw-r--r-- | cmd-line-utils/readline/terminal.c | 3 | ||||
-rw-r--r-- | extra/yassl/taocrypt/include/file.hpp | 2 | ||||
-rw-r--r-- | extra/yassl/taocrypt/src/file.cpp | 4 | ||||
-rw-r--r-- | storage/xtradb/ut/ut0ut.c | 4 |
5 files changed, 8 insertions, 8 deletions
diff --git a/cmd-line-utils/readline/complete.c b/cmd-line-utils/readline/complete.c index d11ea2493a6..a51375cd2b7 100644 --- a/cmd-line-utils/readline/complete.c +++ b/cmd-line-utils/readline/complete.c @@ -673,8 +673,7 @@ fnprint (to_print) w = wcwidth (wc); width = (w >= 0) ? w : 1; } - fwrite (s, 1, tlen, rl_outstream); - s += tlen; + s+= fwrite (s, 1, tlen, rl_outstream); printed_len += width; #else putc (*s, rl_outstream); diff --git a/cmd-line-utils/readline/terminal.c b/cmd-line-utils/readline/terminal.c index e2785908160..cc30f50cf3c 100644 --- a/cmd-line-utils/readline/terminal.c +++ b/cmd-line-utils/readline/terminal.c @@ -621,7 +621,8 @@ _rl_output_some_chars (string, count) const char *string; int count; { - fwrite (string, 1, count, _rl_out_stream); + if (fwrite (string, 1, count, _rl_out_stream) != count) + fprintf(stderr, "Write failed\n"); } /* Move the cursor back. */ diff --git a/extra/yassl/taocrypt/include/file.hpp b/extra/yassl/taocrypt/include/file.hpp index 0f85b46fdb2..e22040f60f0 100644 --- a/extra/yassl/taocrypt/include/file.hpp +++ b/extra/yassl/taocrypt/include/file.hpp @@ -110,7 +110,7 @@ public: word32 size(bool use_current = false); private: - void put(Source&); + size_t put(Source&); FileSink(const FileSink&); // hide FileSink& operator=(const FileSink&); // hide diff --git a/extra/yassl/taocrypt/src/file.cpp b/extra/yassl/taocrypt/src/file.cpp index 0498038a04b..88ead8e550e 100644 --- a/extra/yassl/taocrypt/src/file.cpp +++ b/extra/yassl/taocrypt/src/file.cpp @@ -98,9 +98,9 @@ FileSink::~FileSink() // fill source from file sink -void FileSink::put(Source& source) +size_t FileSink::put(Source& source) { - fwrite(source.get_buffer(), 1, source.size(), file_); + return fwrite(source.get_buffer(), 1, source.size(), file_); } diff --git a/storage/xtradb/ut/ut0ut.c b/storage/xtradb/ut/ut0ut.c index 498873e290a..fc1bdffcf38 100644 --- a/storage/xtradb/ut/ut0ut.c +++ b/storage/xtradb/ut/ut0ut.c @@ -553,7 +553,7 @@ ut_print_namel( trx ? trx->mysql_thd : NULL, table_id); - fwrite(buf, 1, bufend - buf, f); + (void) fwrite(buf, 1, bufend - buf, f); } /**********************************************************************//** @@ -574,7 +574,7 @@ ut_copy_file( ? (size_t) len : sizeof buf; size_t size = fread(buf, 1, maxs, src); - fwrite(buf, 1, size, dest); + (void) fwrite(buf, 1, size, dest); len -= (long) size; if (size < maxs) { break; |