1
1
mirror of https://github.com/go-gitea/gitea synced 2025-07-22 18:28:37 +00:00

Fix Azure blob object Seek (#32974)

This bug was found in a
[test](https://github.com/go-gitea/gitea/actions/runs/12464294025/job/34788152194?pr=32883#step:9:105)
of #32883

---------

Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
This commit is contained in:
Zettat123
2024-12-25 12:54:52 +08:00
committed by GitHub
parent 973363fec3
commit abaeae0b9c
2 changed files with 46 additions and 1 deletions

View File

@@ -70,7 +70,7 @@ func (a *azureBlobObject) Seek(offset int64, whence int) (int64, error) {
case io.SeekCurrent:
offset += a.offset
case io.SeekEnd:
offset = a.Size - offset
offset = a.Size + offset
default:
return 0, errors.New("Seek: invalid whence")
}