This repository was archived by the owner on Jul 22, 2024. It is now read-only.
This repository was archived by the owner on Jul 22, 2024. It is now read-only.
Concurreny Support #57
Open
Description
Hi there, i'm just trying a kinda simple code that involves go routines:
// main.go
package main
import (
"github.com/mitchellh/go-mruby"
"sync"
)
func main() {
mrb := mruby.NewMrb()
defer mrb.Close()
var wg sync.WaitGroup
for i := 1; i < 50000; i++ {
wg.Add(1)
go func() {
mrb.LoadString("puts 'hola mundo'")
wg.Done()
}()
}
wg.Wait()
after doing go run main.go
it starts to print the messages as expected but after a while it raise a fatal error:
fatal error: unexpected signal during runtime execution
fatal error: schedule: holding locks
panic during panic
[signal SIGSEGV: segmentation violation code=0x1 addr=0x1357b900160 pc=0x55e9799579c9]
it seems like at some point something really bad is happening inside the Mrb struct, and it just starts crashing over and over again.
my go version is go1.7.4 linux/amd64
running in a Debian 9.1 (stretch)
Metadata
Metadata
Assignees
Labels
No labels
Activity