-
Notifications
You must be signed in to change notification settings - Fork 4
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
Fix crash when run from xboard #17
Comments
Here is the xboard protocol, note section 6. Here is a reference implementation. |
This problem was observed yesterday, and seems to be caused deep in julia internals. |
Also note that we can flush c style... but I haven't yet found how to call it (its not in Base namespace) |
Also worth understanding - how julia sets up its environment: |
The problem happens on all Win/Mac/Arch, with xboard 4.8 and 4.9 (haven't tested earlier versions). The problem seems to have always been present (checking out earlier commits the problem persists). It appears to just be something fundamental in how julia receives / sends on these pipes. I've reproduced the problem with simply xboard_bug.jl To reproduce, run the command line: this asks xboard to output its debug info of the io. Make a couple of moves for white, one or two black moves will happen, but then xboard will report the julia crash. |
Running strace:
|
The source for xboard is available at: http://ftp.gnu.org/gnu/xboard/ and childio.c contains the relevant pipes code. Reading about pipes in Linux / POSIX at: http://tldp.org/LDP/lpg/node9.html Looking at the strace for xboard, there are some weird long read calls. Learning about strace
Maybe julia is spitting out information on the STDERR tied to STDOUT? |
We must set feature SIGINT=0 to prevent xboard from sending this to julia. Section 7 of the protocol. |
No description provided.
The text was updated successfully, but these errors were encountered: