Skip to content

Use io instead of ioutil (deprecated) #40 #4

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 1 addition & 2 deletions chunk.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ import (
"errors"
"fmt"
"io"
"io/ioutil"
"sync"
)

Expand Down Expand Up @@ -122,7 +121,7 @@ func (ch *Chunk) Drain() {
for bytesAhead > 0 {
readSize := int64(bytesAhead)

if _, err := io.CopyN(ioutil.Discard, ch.R, readSize); err != nil {
if _, err := io.CopyN(io.Discard, ch.R, readSize); err != nil {
return
}
bytesAhead -= int(readSize)
Expand Down
2 changes: 0 additions & 2 deletions doc.go
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
/*

Package riff is package implementing a simple Resource Interchange File Format
(RIFF) parser with basic support for sub formats such as WAV.
The goal of this package is to give all the tools needed for a developer
Expand All @@ -10,6 +9,5 @@ of a wav file can be easily accessed (See the examples below) .

For more information about RIFF:
https://en.wikipedia.org/wiki/Resource_Interchange_File_Format

*/
package riff