diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2015-05-12 18:27:37 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2015-05-12 18:27:54 +0200 |
commit | 0bfc98e63b062bc847fd0f37308c050ac618c56f (patch) | |
tree | 0b20885e7bb84fcc7932e5b6488a6efec1716ade /shell/source/unix | |
parent | 4e871a9b225c0d21ed703b45400b4e8476214bce (diff) |
loplugin:redundantcast: reinterpret_cast to void*
Change-Id: I947b49cfb15f0e7d6ddfaae386656c70e4bd48ba
Diffstat (limited to 'shell/source/unix')
-rw-r--r-- | shell/source/unix/sysshell/recently_used_file.cxx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/shell/source/unix/sysshell/recently_used_file.cxx b/shell/source/unix/sysshell/recently_used_file.cxx index 08f96a389dbc..16b0a373ad1b 100644 --- a/shell/source/unix/sysshell/recently_used_file.cxx +++ b/shell/source/unix/sysshell/recently_used_file.cxx @@ -108,7 +108,7 @@ void recently_used_file::truncate(off_t length) size_t recently_used_file::read(char* buffer, size_t size) const { - size_t r = fread(reinterpret_cast<void*>(buffer), sizeof(char), size, file_); + size_t r = fread(buffer, sizeof(char), size, file_); if ((r < size) && ferror(file_)) throw "I/O error: read failed"; @@ -119,7 +119,7 @@ size_t recently_used_file::read(char* buffer, size_t size) const void recently_used_file::write(const char* buffer, size_t size) const { - if (size != fwrite(reinterpret_cast<const void*>(buffer), sizeof(char), size, file_)) + if (size != fwrite(buffer, sizeof(char), size, file_)) throw "I/O error: write failed"; } |