Skip to content

segmentation violation with go 1.24 #112

@tinmrn

Description

@tinmrn

After upgrading go to 1.24 go-graphviz crashes with

unexpected fault address 0xc002400000
fatal error: fault
[signal SIGSEGV: segmentation violation code=0x2 addr=0xc002400000 pc=0x477595]

following with goroutine stack dumps which only contain go runtime paths (no app or lib code involved)

reproduce with this Dockerfile:

FROM golang:1.24

WORKDIR "/app"

RUN go mod init graphviz-crash

RUN go get github.com/goccy/go-graphviz

RUN <<EOF cat > main.go
package main

import (
  "context"
  "fmt"
  "github.com/goccy/go-graphviz"
)

func main(){

  gv, _ := graphviz.New(context.Background())
  gr, _ := gv.Graph()
  gr.CreateNodeByName("test")

  fmt.Print("all good")

}

EOF

ENTRYPOINT ["go", "run", "main.go"]

and this command:

docker build --tag graphviz-crash . && docker run -ti --rm graphviz-crash

if you change FROM golang:1.24 to 1.23 it works

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions