diff options
Diffstat (limited to 'src/ipc.c')
| -rw-r--r-- | src/ipc.c | 14 |
1 files changed, 1 insertions, 13 deletions
@@ -3,21 +3,9 @@ #include "ipc.h" -// https://stackoverflow.com/a/5656561 -void* create_shared_memory(size_t size) { - int protection = PROT_READ | PROT_WRITE; - int visibility = MAP_SHARED | MAP_ANONYMOUS; - return mmap( - NULL, - size, - protection, visibility, - -1, 0 - ); -} - comm_moves comm_moves_init() { return (comm_moves) { - create_shared_memory(sizeof(struct uci_move) * 50), + malloc(sizeof(struct uci_move) * 50), 0, 50 }; |
