Skip to content

Commit

Permalink
Fix offset regression in wshremote
Browse files Browse the repository at this point in the history
  • Loading branch information
esimkowitz authored Jan 23, 2025
1 parent 50b80a1 commit 8bbc612
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/wshrpc/wshremote/wshremote.go
Original file line number Diff line number Diff line change
Expand Up @@ -738,7 +738,7 @@ func (*ServerImpl) RemoteWriteFileCommand(ctx context.Context, data wshrpc.FileD
if finfo != nil {
fileSize = finfo.Size()
}
offset := fileSize
offset := 0
if data.At != nil {
if data.At.Offset > 0 {
offset = min(data.At.Offset, fileSize)

Check failure on line 744 in pkg/wshrpc/wshremote/wshremote.go

View workflow job for this annotation

GitHub Actions / Analyze (go)

cannot use min(data.At.Offset, fileSize) (value of type int64) as int value in assignment

Check failure on line 744 in pkg/wshrpc/wshremote/wshremote.go

View workflow job for this annotation

GitHub Actions / Build for TestDriver.ai

cannot use min(data.At.Offset, fileSize) (value of type int64) as int value in assignment
Expand Down

0 comments on commit 8bbc612

Please sign in to comment.