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

CtoB: not page-boundary safe #64

Closed
damianut opened this issue Aug 17, 2023 · 0 comments · Fixed by #65
Closed

CtoB: not page-boundary safe #64

damianut opened this issue Aug 17, 2023 · 0 comments · Fixed by #65

Comments

@damianut
Copy link
Contributor

CtoB function is not page-boundary safe.

As mud-freak wrote here:

In the second line within the function, reading an integer (four bytes) instead of one byte might read across page boundaries in memory. How ever small the chances are of that ever happening - it did!. See more details in the linked post. This issue was then addressed in MEM_ReadByte (Ikarus). MEM_ReadByte is, of course, the better choice here than reading an integer when only interested in the first byte. For further discussion, it might be best to move to the Ikarus-thread in the editing section of the forum, to not go too far off-topic here.

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 a pull request may close this issue.

1 participant