summaryrefslogtreecommitdiff
path: root/vendor/github.com/onsi/gomega/gbytes/buffer.go
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/github.com/onsi/gomega/gbytes/buffer.go')
-rw-r--r--vendor/github.com/onsi/gomega/gbytes/buffer.go6
1 files changed, 0 insertions, 6 deletions
diff --git a/vendor/github.com/onsi/gomega/gbytes/buffer.go b/vendor/github.com/onsi/gomega/gbytes/buffer.go
index 809f3c543..6f77b2371 100644
--- a/vendor/github.com/onsi/gomega/gbytes/buffer.go
+++ b/vendor/github.com/onsi/gomega/gbytes/buffer.go
@@ -87,17 +87,11 @@ func (b *Buffer) Write(p []byte) (n int, err error) {
/*
Read implements the io.Reader interface. It advances the
cursor as it reads.
-
-Returns an error if called after Close.
*/
func (b *Buffer) Read(d []byte) (int, error) {
b.lock.Lock()
defer b.lock.Unlock()
- if b.closed {
- return 0, errors.New("attempt to read from closed buffer")
- }
-
if uint64(len(b.contents)) <= b.readCursor {
return 0, io.EOF
}