diff options
author | 2017-12-15 17:12:41 -0800 | |
---|---|---|
committer | 2017-12-15 17:16:29 -0800 | |
commit | d55f532867a3670d66460c5ee3b774519542adc1 (patch) | |
tree | 7de4d85bcd61e93401459276b4d371ab0be23c1f /tensorflow/core/lib/io/snappy | |
parent | 32d5048ae96116202f2aa0fa739ef37514ee8a54 (diff) |
Merge changes from github.
PiperOrigin-RevId: 179258973
Diffstat (limited to 'tensorflow/core/lib/io/snappy')
-rw-r--r-- | tensorflow/core/lib/io/snappy/snappy_outputbuffer.cc | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/tensorflow/core/lib/io/snappy/snappy_outputbuffer.cc b/tensorflow/core/lib/io/snappy/snappy_outputbuffer.cc index be1fa22c69..3c31016732 100644 --- a/tensorflow/core/lib/io/snappy/snappy_outputbuffer.cc +++ b/tensorflow/core/lib/io/snappy/snappy_outputbuffer.cc @@ -161,7 +161,7 @@ Status SnappyOutputBuffer::Deflate() { } // Write length of compressed block to output buffer. - char* compressed_length_array = new char[4]; + char compressed_length_array[4]; std::fill(compressed_length_array, compressed_length_array + 4, 0); for (int i = 0; i < 4; i++) { // Little endian. @@ -173,7 +173,6 @@ Status SnappyOutputBuffer::Deflate() { TF_RETURN_IF_ERROR(AddToOutputBuffer(output.data(), output.size())); next_in_ += avail_in_; avail_in_ = 0; - delete[] compressed_length_array; return Status::OK(); } |