Fix "if false" debugging left in rac's readAt

This commit is contained in:
Nigel Tao committed 2019-08-24 07:04:11 +10:00
1 parent 31bdd08ce6
commit 62211056f8
2 files changed
+2 -2

No files matched your search

+1 -1
View File
@@ -30,7 +30,7 @@ func u48LE(b []byte) int64 {
// Seek and then ReadFull. Calling ReadAt is presumably slightly more
// efficient, e.g. one syscall instead of two.
func readAt(r io.ReadSeeker, p []byte, offset int64) error {
if a, ok := r.(io.ReaderAt); ok && false {
if a, ok := r.(io.ReaderAt); ok {
n, err := a.ReadAt(p, offset)
if (n == len(p)) && (err == io.EOF) {
err = nil
+1 -1
View File
@@ -46,7 +46,7 @@ func u32BE(b []byte) uint32 {
// Seek and then ReadFull. Calling ReadAt is presumably slightly more
// efficient, e.g. one syscall instead of two.
func readAt(r io.ReadSeeker, p []byte, offset int64) error {
if a, ok := r.(io.ReaderAt); ok && false {
if a, ok := r.(io.ReaderAt); ok {
n, err := a.ReadAt(p, offset)
if (n == len(p)) && (err == io.EOF) {
err = nil