mirror of
https://github.com/hajimehoshi/ebiten.git
synced 2025-01-11 19:48:54 +01:00
audio: Bug fix: wav.Decoder.Seek's returning value was wrong
This commit is contained in:
parent
9620c4efb2
commit
f78f4002fa
@ -57,7 +57,7 @@ func (s *Stream) Seek(offset int64, whence int) (int64, error) {
|
|||||||
return 0, fmt.Errorf("wav: invalid offset")
|
return 0, fmt.Errorf("wav: invalid offset")
|
||||||
}
|
}
|
||||||
s.remaining = s.dataSize - (n - s.headerSize)
|
s.remaining = s.dataSize - (n - s.headerSize)
|
||||||
return n, nil
|
return n - s.headerSize, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// Read is implementation of io.Closer's Close.
|
// Read is implementation of io.Closer's Close.
|
||||||
|
Loading…
Reference in New Issue
Block a user