square/tape — pull request #30 by mfurtak (2013-06-27 00:48:21+00:00)
Title: Changes QueueFile#ringRead to use the offset parameter in all cases

When trying to use `forEach` and an `ElementReader` to read data into offset positions of a single byte array, I noticed that the bytes starting at offset 0 would be repeatedly overwritten, rather than subsequent elements' data being read into the expected offsets of my byte array.

I believe the culprit is the use of the constant offset `0` in the first branch of the conditional logic in `QueueFile#ringRead`. I've included a test that should fail against the current logic in master, and pass with my changes.

Thanks for your time and consideration!