Use Seek instead of discardN

This commit is contained in:
David Howden
2015-04-15 00:12:30 +10:00
parent 1fc6cacf34
commit 8aff503453
2 changed files with 5 additions and 8 deletions
-6
View File
@@ -6,14 +6,8 @@ package tag
import (
"io"
"io/ioutil"
)
func discardN(r io.Reader, n int64) error {
_, err := io.CopyN(ioutil.Discard, r, n)
return err
}
func getBit(b byte, n uint) bool {
x := byte(1 << n)
return (b & x) == x