mirror of
https://github.com/jart/cosmopolitan.git
synced 2025-07-06 19:28:29 +00:00
Add tool for viewing memory
https://justine.storage.googleapis.com/memzoom/index.html
This commit is contained in:
parent
2d80bbc802
commit
9fe95ef12b
22 changed files with 1511 additions and 1028 deletions
|
@ -44,6 +44,7 @@
|
|||
#include "libc/stdio/stdio.h"
|
||||
#include "libc/str/str.h"
|
||||
#include "libc/sysv/consts/map.h"
|
||||
#include "libc/sysv/consts/msync.h"
|
||||
#include "libc/sysv/consts/o.h"
|
||||
#include "libc/sysv/consts/prot.h"
|
||||
#include "libc/time/time.h"
|
||||
|
@ -362,6 +363,7 @@ void OpenObject(struct Package *pkg, struct Object *obj, int mode, int prot,
|
|||
}
|
||||
|
||||
void CloseObject(struct Object *obj) {
|
||||
msync(obj->elf, obj->size, MS_SYNC);
|
||||
CHECK_NE(-1, munmap(obj->elf, obj->size));
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue