diff --git a/audio/internal/cbackend/player.go b/audio/internal/cbackend/player.go index 0dcca3181..e9a383885 100644 --- a/audio/internal/cbackend/player.go +++ b/audio/internal/cbackend/player.go @@ -272,12 +272,7 @@ func (p *playerImpl) Seek(offset int64, whence int) (int64, error) { if !ok { return 0, errors.New("cbackend: the source must implement io.Seeker") } - newOffset, err := s.Seek(offset, whence) - if err != nil { - return newOffset, err - } - - return newOffset, nil + return s.Seek(offset, whence) } func (p *Player) Reset() { diff --git a/go.mod b/go.mod index 3e2ae4392..365c30637 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/hajimehoshi/bitmapfont/v2 v2.2.0 github.com/hajimehoshi/file2byteslice v0.0.0-20210813153925-5340248a8f41 github.com/hajimehoshi/go-mp3 v0.3.3 - github.com/hajimehoshi/oto/v2 v2.2.0-alpha.3.0.20220630171212-19c3101d3014 + github.com/hajimehoshi/oto/v2 v2.2.0-alpha.3.0.20220630172654-9e23d1429786 github.com/jakecoffman/cp v1.2.0 github.com/jezek/xgb v1.0.1 github.com/jfreymuth/oggvorbis v1.0.3 diff --git a/go.sum b/go.sum index b5a1b79fe..2bac854b0 100644 --- a/go.sum +++ b/go.sum @@ -11,8 +11,8 @@ github.com/hajimehoshi/go-mp3 v0.3.3 h1:cWnfRdpye2m9ElSoVqneYRcpt/l3ijttgjMeQh+r github.com/hajimehoshi/go-mp3 v0.3.3/go.mod h1:qMJj/CSDxx6CGHiZeCgbiq2DSUkbK0UbtXShQcnfyMM= github.com/hajimehoshi/oto v0.6.1 h1:7cJz/zRQV4aJvMSSRqzN2TImoVVMpE0BCY4nrNJaDOM= github.com/hajimehoshi/oto v0.6.1/go.mod h1:0QXGEkbuJRohbJaxr7ZQSxnju7hEhseiPx2hrh6raOI= -github.com/hajimehoshi/oto/v2 v2.2.0-alpha.3.0.20220630171212-19c3101d3014 h1:CzwUmBzSfGTCrUXwnuhEbZf3QFzr1qYolBEYE4VxvLI= -github.com/hajimehoshi/oto/v2 v2.2.0-alpha.3.0.20220630171212-19c3101d3014/go.mod h1:9i0oYbpJ8BhVGkXDKdXKfFthX1JUNfXjeTp944W8TGM= +github.com/hajimehoshi/oto/v2 v2.2.0-alpha.3.0.20220630172654-9e23d1429786 h1:SI0I3KWGjVfTTWs6CpeVw85pXBSgwdtY9yO+996HaQ8= +github.com/hajimehoshi/oto/v2 v2.2.0-alpha.3.0.20220630172654-9e23d1429786/go.mod h1:9i0oYbpJ8BhVGkXDKdXKfFthX1JUNfXjeTp944W8TGM= github.com/jakecoffman/cp v1.2.0 h1:ZdCFqHglNYJibiIeRvpAktJ7ZuWUnh0cnBsZNKVbY3A= github.com/jakecoffman/cp v1.2.0/go.mod h1:JjY/Fp6d8E1CHnu74gWNnU0+b9VzEdUVPoJxg2PsTQg= github.com/jezek/xgb v1.0.1 h1:YUGhxps0aR7J2Xplbs23OHnV1mWaxFVcOl9b+1RQkt8=