Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(533)

Unified Diff: util/file/file_reader.h

Issue 1416493006: Change file op |ssize_t|s to FileOperationResult (Closed) Base URL: https://chromium.googlesource.com/crashpad/crashpad@master
Patch Set: fixes Created 5 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « util/file/file_io.cc ('k') | util/file/file_reader.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: util/file/file_reader.h
diff --git a/util/file/file_reader.h b/util/file/file_reader.h
index 58f58651ad10cb5ffb8c51e06e5b5d5309b22d41..5d77b87569ab03bdbe606e0ca7801be1e741a7f1 100644
--- a/util/file/file_reader.h
+++ b/util/file/file_reader.h
@@ -37,7 +37,7 @@ class FileReaderInterface : public virtual FileSeekerInterface {
//! \return The number of bytes actually read if the operation succeeded,
//! which may be `0` or any positive value less than or equal to \a size.
//! `-1` if the operation failed, with an error message logged.
- virtual ssize_t Read(void* data, size_t size) = 0;
+ virtual FileOperationResult Read(void* data, size_t size) = 0;
//! \brief Wraps Read(), ensuring that the read succeeded and exactly \a size
//! bytes were read.
@@ -69,7 +69,7 @@ class WeakFileHandleFileReader : public FileReaderInterface {
~WeakFileHandleFileReader() override;
// FileReaderInterface:
- ssize_t Read(void* data, size_t size) override;
+ FileOperationResult Read(void* data, size_t size) override;
// FileSeekerInterface:
@@ -125,7 +125,7 @@ class FileReader : public FileReaderInterface {
//!
//! \note It is only valid to call this method between a successful Open() and
//! a Close().
- ssize_t Read(void* data, size_t size) override;
+ FileOperationResult Read(void* data, size_t size) override;
// FileSeekerInterface:
@@ -160,7 +160,7 @@ class WeakStdioFileReader : public FileReaderInterface {
~WeakStdioFileReader() override;
// FileReaderInterface:
- ssize_t Read(void* data, size_t size) override;
+ FileOperationResult Read(void* data, size_t size) override;
// FileSeekerInterface:
« no previous file with comments | « util/file/file_io.cc ('k') | util/file/file_reader.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698