Skip to content

Fix null pointer access when iterating over empty arrays#30

Merged
WalterBright merged 5 commits intoDigitalMars:masterfrom
s-ludwig:fix_null_pointer_access
Jun 19, 2024
Merged

Fix null pointer access when iterating over empty arrays#30
WalterBright merged 5 commits intoDigitalMars:masterfrom
s-ludwig:fix_null_pointer_access

Conversation

@s-ludwig
Copy link
Copy Markdown
Contributor

@s-ludwig s-ludwig commented Jun 12, 2024

The PropTable.table field is a RandAA, which is a class and thus does not exhibit the more forgiving interface as built-in AAs.

This PR also fixes the CI stage for running the test262 test suite, which appears to have been broken for a while.

@WalterBright
Copy link
Copy Markdown
Contributor

thank you!

@WalterBright
Copy link
Copy Markdown
Contributor

What about the failing test?

@s-ludwig
Copy link
Copy Markdown
Contributor Author

Looks like the python2 executable isn't available by default for GitHub actions anymore. I'll see if I can quickly fix that.

@s-ludwig s-ludwig force-pushed the fix_null_pointer_access branch 9 times, most recently from 3f4df7d to 70196c8 Compare June 15, 2024 08:34
@s-ludwig
Copy link
Copy Markdown
Contributor Author

Finally got it to complete again. There were several issues:

  • Python 2 not being available, I first tried to install Python 2 manually, which didn't quite work, so instead the code is now adjusted for Python 3
  • Some test log output caused grep to recognize the log as binary and in turn to not output the matched text
  • For some reason the dmdscript:ds binary, which used by the test suite, crashes when being generated by DMD - I worked around that for now by compiling with LDC
  • The fix makes some additional test cases pass, so the number needed to be bumped up

@s-ludwig s-ludwig changed the title [trivial] Fix null pointer access when iterating over empty arrays Fix null pointer access when iterating over empty arrays Jun 15, 2024
@s-ludwig s-ludwig force-pushed the fix_null_pointer_access branch from 70196c8 to 3aa9957 Compare June 15, 2024 10:41
Fixes issues with corrupted values under GC load.
@s-ludwig
Copy link
Copy Markdown
Contributor Author

Fixed another small issue in RandAA that came up.

@WalterBright WalterBright merged commit f93cb97 into DigitalMars:master Jun 19, 2024
@s-ludwig s-ludwig deleted the fix_null_pointer_access branch June 19, 2024 06:33
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