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

Fixes for QEMU support #18

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

michalbednarski
Copy link

Set MAP_FIXED when addr isn't NULL and don't assume that shmflg != 0 means SHM_RDONLY

termux/proot-distro#495

QEMU implies use of SHM_REMAP: https://github.com/qemu/qemu/blob/495de0fd82d8bb2d7035f82d9869cfeb48de2f9e/linux-user/mmap.c#L1420-L1423

In Linux, addr != 0 implies MAP_FIXED, while SHM_REMAP flag only requires use of addr != 0: https://github.com/torvalds/linux/blob/7ff71e6d923969d933e1ba7e0db857782d36cd19/ipc/shm.c#L1534-L1555

Don't assume that shmflg != 0 means SHM_RDONLY

termux/proot-distro#495
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.

1 participant