diff options
author | Sander Vrijders <sander.vrijders@intec.ugent.be> | 2016-06-28 16:38:03 +0200 |
---|---|---|
committer | Sander Vrijders <sander.vrijders@intec.ugent.be> | 2016-06-28 16:45:45 +0200 |
commit | 99d19307fae8f1370f52a62aee88fded624ad464 (patch) | |
tree | 36b94730d8690c2d131f39b3cc3ff715674f9fcc /src/lib/shm_du_map.c | |
parent | 0d789ed8d938cc342c8f2138280795a1d5a61e3d (diff) | |
download | ouroboros-99d19307fae8f1370f52a62aee88fded624ad464.tar.gz ouroboros-99d19307fae8f1370f52a62aee88fded624ad464.zip |
lib, irmd, ipcpd: Change pid to api
Changes the variable name as well to API instead of PID.
Diffstat (limited to 'src/lib/shm_du_map.c')
-rw-r--r-- | src/lib/shm_du_map.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/lib/shm_du_map.c b/src/lib/shm_du_map.c index f5909e11..2a316265 100644 --- a/src/lib/shm_du_map.c +++ b/src/lib/shm_du_map.c @@ -75,7 +75,7 @@ struct shm_du_map { size_t * ptr_tail; /* start of ringbuffer tail */ pthread_mutex_t * shm_mutex; /* lock all free space in shm */ pthread_cond_t * sanitize; /* run sanitizer when buffer full */ - pid_t * pid; /* pid of the irmd owner */ + pid_t * api; /* api of the irmd owner */ int fd; }; @@ -141,7 +141,7 @@ struct shm_du_map * shm_du_map_create() dum->ptr_tail = dum->ptr_head + 1; dum->shm_mutex = (pthread_mutex_t *) (dum->ptr_tail + 1); dum->sanitize = (pthread_cond_t *) (dum->shm_mutex + 1); - dum->pid = (pid_t *) (dum->sanitize + 1); + dum->api = (pid_t *) (dum->sanitize + 1); pthread_mutexattr_init(&mattr); pthread_mutexattr_setpshared(&mattr, PTHREAD_PROCESS_SHARED); @@ -155,7 +155,7 @@ struct shm_du_map * shm_du_map_create() *dum->ptr_head = 0; *dum->ptr_tail = 0; - *dum->pid = getpid(); + *dum->api = getpid(); dum->fd = shm_fd; @@ -203,7 +203,7 @@ struct shm_du_map * shm_du_map_open() dum->ptr_tail = dum->ptr_head + 1; dum->shm_mutex = (pthread_mutex_t *) (dum->ptr_tail + 1); dum->sanitize = (pthread_cond_t *) (dum->shm_mutex + 1); - dum->pid = (pid_t *) (dum->sanitize + 1); + dum->api = (pid_t *) (dum->sanitize + 1); dum->fd = shm_fd; @@ -212,7 +212,7 @@ struct shm_du_map * shm_du_map_open() pid_t shm_du_map_owner(struct shm_du_map * dum) { - return *dum->pid; + return *dum->api; } void * shm_du_map_sanitize(void * o) |