criu/lib
Bhavik Sachdev 7daaa11aa0 mem: don't PROT_WRITE on reservation mmaps
An application might call mmap with PROT_NONE to reserve a large amount
of the virtual address space. Something like:

void *addr = mmap(NULL, SIZE, PROT_NONE,
	      MAP_PRIVATE | MAP_ANONYMOUS, -1, 0);

During restore, when we have to premap private vmas (ie pieok is false),
CRIU tries to mmap this large PROT_NONE and fails.

If a vma has never been written to, it does not have "ac" flag set. Use
this fact to safely premap vmas that were done for address reservation.

Suggested-by: Andrei Vagin <avagin@gmail.com>
Signed-off-by: Bhavik Sachdev <b.sachdev1904@gmail.com>
2026-05-07 11:45:34 -07:00
..
c libcriu: enable setting of RPC config file 2025-11-05 15:41:34 -08:00
pycriu mem: don't PROT_WRITE on reservation mmaps 2026-05-07 11:45:34 -07:00
.gitignore lib: use separate packages for pycriu and crit 2023-11-27 16:47:16 -08:00
Makefile make: improve check for externally managed Python 2024-09-11 16:02:11 -07:00
pyproject.toml pycriu: add missing protobuf dependency 2025-11-05 15:41:34 -08:00
setup.cfg pycriu: add missing protobuf dependency 2025-11-05 15:41:34 -08:00
setup.py lib: use separate packages for pycriu and crit 2023-11-27 16:47:16 -08:00