diff options
author | Jonathan Hseu <jhseu@google.com> | 2017-05-18 11:02:51 -0700 |
---|---|---|
committer | TensorFlower Gardener <gardener@tensorflow.org> | 2017-05-18 11:10:00 -0700 |
commit | febbec41771c96b30309807e6396890cc54e3f76 (patch) | |
tree | 1e7669d7c5627cf276f98d293f4c12158c47af7d /tensorflow/core/lib/io/buffered_inputstream.h | |
parent | b67991767187668682f9f18ff6e9e236b5fa0e03 (diff) |
Fix WholeFileReader for named pipes (or any file with incorrect or non-fixed sizes).
PiperOrigin-RevId: 156452522
Diffstat (limited to 'tensorflow/core/lib/io/buffered_inputstream.h')
-rw-r--r-- | tensorflow/core/lib/io/buffered_inputstream.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/tensorflow/core/lib/io/buffered_inputstream.h b/tensorflow/core/lib/io/buffered_inputstream.h index d55dd5cdaf..b37766005a 100644 --- a/tensorflow/core/lib/io/buffered_inputstream.h +++ b/tensorflow/core/lib/io/buffered_inputstream.h @@ -75,6 +75,12 @@ class BufferedInputStream : public InputStreamInterface { // no special treatment. string ReadLineAsString(); + // Reads the entire contents of the file into *result. + // + // Note: the amount of memory used by this function call is unbounded, so only + // use in ops that expect that behavior. + Status ReadAll(string* result); + Status Reset() override; private: |