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

Fix #397 (Segfault after quitting from a break loop) #709

Merged
merged 1 commit into from
Apr 14, 2016

Conversation

markuspf
Copy link
Member

@markuspf markuspf commented Apr 2, 2016

If the interpreter runs into an error while reading from a stream and
tries to check for a dual semicolon at the end of the statement, the
call to GetSymbol() leads to a call to ReadLine on the input stream.

With (IsInputTextStream and IsInputTextStringRep) the correct method
is selected and called. The crash happens inside the method when trying
to access the stream or local variables.

This might not be the correct fix yet, but it seems clear that the
interpreter state is not right at this point.

Maybe @stevelinton or @ChrisJefferson can have a look and comment.

If the interpreter runs into an error while reading from a stream and
tries to check for a dual semicolon at the end of the statement, the
call to GetSymbol() leads to a call to ReadLine on the input stream.

With  (IsInputTextStream and IsInputTextStringRep) the correct method
is selected and called. The crash happens inside the method when trying
to access the stream or local variables.

This might not be the correct fix yet, but it seems clear that the
interpreter state is not right at this point.
@ChrisJefferson
Copy link
Contributor

Looks right to me, and I've tried hammering it in various ways and I can't make anything break.

@olexandr-konovalov olexandr-konovalov changed the title Fix #397 Fix #397 (Segfault after quitting from a break loop) Apr 14, 2016
@ChrisJefferson ChrisJefferson merged commit 7aec88c into gap-system:master Apr 14, 2016
@markuspf markuspf deleted the fix-397 branch February 5, 2017 12:31
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

Successfully merging this pull request may close these issues.

2 participants