Make ZipOS mmap safer (#735)

- It now runs entirely under __mmi_lock
- Hide implementation strace
This commit is contained in:
Gavin Hayes 2023-02-22 21:57:36 -05:00 committed by GitHub
parent e323527ffa
commit b275e664ec
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
6 changed files with 44 additions and 29 deletions

View file

@ -44,6 +44,9 @@ int GetDosEnviron(const char16_t *, char *, size_t, char **, size_t);
bool __intercept_flag(int *, char *[], const char *);
int sys_mprotect_nt(void *, size_t, int) _Hide;
int __inflate(void *, size_t, const void *, size_t);
noasan void *Mmap(void *addr, size_t size, int prot, int flags, int fd,
int64_t off) _Hide;
noasan int Munmap(char *, size_t) _Hide;
COSMOPOLITAN_C_END_
#endif /* !(__ASSEMBLER__ + __LINKER__ + 0) */