fix: windows crash for golang1.26 on WSARecvFrom syscall

This commit is contained in:
wwqgtxx
2026-03-09 14:19:23 +08:00
parent 4c35436b70
commit 68ca83f2f8
4 changed files with 72 additions and 3 deletions

View File

@@ -179,12 +179,19 @@ jobs:
tar zxf go1.26.0.linux-amd64-abi1.tar.gz -C $HOME/usr/local
echo "$HOME/usr/local/go/bin" >> $GITHUB_PATH
# TODO: remove after CL747663 merged, see: https://github.com/golang/go/issues/77731
- name: Apply CL747663 for Golang1.26
# TODO: remove after issue77731 merged, see: https://github.com/golang/go/issues/77731
- name: Apply issue77731 for Golang1.26
if: ${{ matrix.jobs.goversion == '' }}
run: |
cd $(go env GOROOT)
patch --verbose -p 1 < $GITHUB_WORKSPACE/.github/patch/cl747663.patch
patch --verbose -p 1 < $GITHUB_WORKSPACE/.github/patch/issue77731.patch
# TODO: remove after issue77975 fixed, see: https://github.com/golang/go/issues/77975
- name: Fix issue77975 for Golang1.26
if: ${{ matrix.jobs.goversion == '' }}
run: |
cd $(go env GOROOT)
patch --verbose -p 1 < $GITHUB_WORKSPACE/.github/patch/issue77975.patch
# this patch file only works on golang1.26.x
# that means after golang1.27 release it must be changed

View File

@@ -50,6 +50,13 @@ jobs:
go-version: ${{ matrix.go-version }}
check-latest: true # Always check for the latest patch release
# TODO: remove after issue77975 fixed, see: https://github.com/golang/go/issues/77975
- name: Fix issue77975 for Golang1.26
if: ${{ matrix.jobs.goversion == '1.26' }}
run: |
cd $(go env GOROOT)
patch --verbose -p 1 < $GITHUB_WORKSPACE/.github/patch/issue77975.patch
- name: Revert Golang commit for Windows7/8
if: ${{ runner.os == 'Windows' && matrix.go-version != '1.20' }}
run: |