Skip to content
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

Gull (Linux) occasionally crashes (sig 11) #2

Closed
basil00 opened this issue Oct 22, 2015 · 2 comments
Closed

Gull (Linux) occasionally crashes (sig 11) #2

basil00 opened this issue Oct 22, 2015 · 2 comments

Comments

@basil00
Copy link
Owner

basil00 commented Oct 22, 2015

Gull (Linux) occasionally crashes, line 3033 Gull.cpp

Next->pst += Pst(IRook(me),rnew) - Pst(IRook(me),rold);

The problem is that do_move is called with a bogus move=0x7FFF value for whatever reason. This triggers the IsCastling conditional with to = from = 63. This results in rold being uninitialized, causing Gull to crash. The crash occurs in code that is not Linux specific.

@basil00
Copy link
Owner Author

basil00 commented Oct 25, 2015

Test position that exhibits the crash: r7/2pnk3/4bp2/pN2p2P/P7/8/2K3P1/5R1R b - - 0 1

@basil00
Copy link
Owner Author

basil00 commented Oct 25, 2015

This appears to be a copy-and-paste bug in gen_captures (s/PushE/PushW). This bug also affects the Windows version of Gull 3, although does not seem to cause it to crash. Fixed in be0a079.

Test position analysis after fix:

23  -0.67   1556.8M 0:00.00 Nc5 h6 Bb3+ Kc3 c6 Nc7 Rd8 Ra1 Bf7 h7 Rh8 Rh6 Kf8 Rh4 Kg7 Rg4+ Kf8 Rh1 f5 Rgh4 Kg7 R1h3 Ne4+ Kb2 Rb8+ Kc2 Kh8 Rf3 f4 Na6 Rb7 Rh6 Bd5 Rd3 Rxh7 Rxh7+ Kxh7

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant