Skip to content

Fix nil pointer panic in getOptions when File.options is nil and no opts are passed #1752

Fix nil pointer panic in getOptions when File.options is nil and no opts are passed

Fix nil pointer panic in getOptions when File.options is nil and no opts are passed #1752

Workflow file for this run

on: [push, pull_request]
name: build
jobs:
test:
strategy:
matrix:
go-version: [1.25.x, 1.26.x]
os: [ubuntu-24.04, macos-15-intel, macos-26, windows-latest]
targetplatform: [x86, x64]
runs-on: ${{ matrix.os }}
steps:
- name: Install Go
uses: actions/setup-go@v6
with:
go-version: ${{ matrix.go-version }}
cache: false
- name: Checkout code
uses: actions/checkout@v6
- name: Get dependencies
run: |
env GO111MODULE=on go vet ./...
- name: Build
run: go build -v .
- name: Build on ARM
if: runner.os == 'Linux'
run: |
GOARCH=arm GOARM=5 go build .
GOARCH=arm GOARM=6 go build .
GOARCH=arm GOARM=7 go build .
GOARCH=arm64 go build .
GOARCH=arm64 GOOS=android go build .
- name: Test
run: env GO111MODULE=on go test -v -timeout 60m -race ./... -coverprofile='coverage.txt' -covermode=atomic
- name: Codecov
uses: codecov/codecov-action@v6
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
with:
files: coverage.txt
flags: unittests
name: codecov-umbrella