-
Notifications
You must be signed in to change notification settings - Fork 188
Hangs and Crashes when starting another process #89
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Full crash output:
|
Full Hang Output (killed with CTRL-):
|
That looks like an instance of http://golang.org/issue/7227 |
Probably, although it's a little odd how the behaviour is different between calling exec in the event handler directly and calling it from a separate go-routine. I guess the Go->C->Go nature of the code contributes to that. I can confirm that the issue isn't exec directly, as you can see the echo command printed out correctly, it's the SIGCHLD the program receives when the exec finishes which causes the problem. I took a regular qml program and sent it a SIGCHLD via "kill -CHLD" and it got stuck as well. |
It might be a good idea to list the caveat somewhere in the QML documentation. eg: On darwin (OSX), if the qml program receives a SIGCHLD signal it will cause problems. This means that starting another executable will cause the QML app to crash or hang when the child process terminates. |
I'll close this and reopen #26, which has more details on the issue. |
I've only tested this on darwin/amd64 using go tip and 1.3.1, it may not happen elsewhere.
Attempting to start a new process (eg: via os/exec.Command) will cause either a crash or a hang when qml is running.
Sample Code: http://play.golang.org/p/eUoef9S3e4
The DoClick button executes the sub-proccess (just a simple echo command) in the code called directly by qml. It causes a crash: "fatal error: runtime: stack growth during syscall"
The GoDoClick button does the same work, but in a new goroutine, it simply causes the app to hang forever and eat up CPU. Hitting CTRL-\ properly causes go to print a stack trace and exit.
The text was updated successfully, but these errors were encountered: