Repository: spark Updated Branches: refs/heads/branch-1.2 f4beb77f0 -> 6844e7a82
SPARK-4222 [CORE] use readFully in FixedLengthBinaryRecordReader replaces the existing read() call with readFully(). Author: industrial-sloth <[email protected]> Closes #3093 from industrial-sloth/branch-1.2-fixedLenRecRdr and squashes the following commits: a245c8a [industrial-sloth] use readFully in FixedLengthBinaryRecordReader Project: http://git-wip-us.apache.org/repos/asf/spark/repo Commit: http://git-wip-us.apache.org/repos/asf/spark/commit/6844e7a8 Tree: http://git-wip-us.apache.org/repos/asf/spark/tree/6844e7a8 Diff: http://git-wip-us.apache.org/repos/asf/spark/diff/6844e7a8 Branch: refs/heads/branch-1.2 Commit: 6844e7a8219ac78790a422ffd5054924e7d2bea1 Parents: f4beb77 Author: industrial-sloth <[email protected]> Authored: Wed Nov 5 15:38:48 2014 -0800 Committer: Matei Zaharia <[email protected]> Committed: Wed Nov 5 15:38:48 2014 -0800 ---------------------------------------------------------------------- .../org/apache/spark/input/FixedLengthBinaryRecordReader.scala | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/spark/blob/6844e7a8/core/src/main/scala/org/apache/spark/input/FixedLengthBinaryRecordReader.scala ---------------------------------------------------------------------- diff --git a/core/src/main/scala/org/apache/spark/input/FixedLengthBinaryRecordReader.scala b/core/src/main/scala/org/apache/spark/input/FixedLengthBinaryRecordReader.scala index 5164a74..36a1e5d 100644 --- a/core/src/main/scala/org/apache/spark/input/FixedLengthBinaryRecordReader.scala +++ b/core/src/main/scala/org/apache/spark/input/FixedLengthBinaryRecordReader.scala @@ -115,7 +115,7 @@ private[spark] class FixedLengthBinaryRecordReader if (currentPosition < splitEnd) { // setup a buffer to store the record val buffer = recordValue.getBytes - fileInputStream.read(buffer, 0, recordLength) + fileInputStream.readFully(buffer) // update our current position currentPosition = currentPosition + recordLength // return true --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
