Lines Matching refs:mq
122 sysvmsg_queue_t *mq = (sysvmsg_queue_t *) rsrc->ptr; in ZEND_GET_MODULE() local
123 efree(mq); in ZEND_GET_MODULE()
155 sysvmsg_queue_t *mq = NULL; in PHP_FUNCTION() local
164 …if ((mq = (sysvmsg_queue_t *)zend_fetch_resource(Z_RES_P(queue), "sysvmsg queue", le_sysvmsg)) == … in PHP_FUNCTION()
168 if (msgctl(mq->id, IPC_STAT, &stat) == 0) { in PHP_FUNCTION()
184 if (msgctl(mq->id, IPC_SET, &stat) == 0) { in PHP_FUNCTION()
196 sysvmsg_queue_t *mq = NULL; in PHP_FUNCTION() local
205 …if ((mq = (sysvmsg_queue_t *)zend_fetch_resource(Z_RES_P(queue), "sysvmsg queue", le_sysvmsg)) == … in PHP_FUNCTION()
209 if (msgctl(mq->id, IPC_STAT, &stat) == 0) { in PHP_FUNCTION()
250 sysvmsg_queue_t *mq; in PHP_FUNCTION() local
256 mq = (sysvmsg_queue_t *) emalloc(sizeof(sysvmsg_queue_t)); in PHP_FUNCTION()
258 mq->key = key; in PHP_FUNCTION()
259 mq->id = msgget(key, 0); in PHP_FUNCTION()
260 if (mq->id < 0) { in PHP_FUNCTION()
262 mq->id = msgget(key, IPC_CREAT | IPC_EXCL | perms); in PHP_FUNCTION()
263 if (mq->id < 0) { in PHP_FUNCTION()
265 efree(mq); in PHP_FUNCTION()
269 ZVAL_COPY_VALUE(return_value, zend_list_insert(mq, le_sysvmsg)); in PHP_FUNCTION()
278 sysvmsg_queue_t *mq = NULL; in PHP_FUNCTION() local
284 …if ((mq = (sysvmsg_queue_t *)zend_fetch_resource(Z_RES_P(queue), "sysvmsg queue", le_sysvmsg)) == … in PHP_FUNCTION()
288 if (msgctl(mq->id, IPC_RMID, NULL) == 0) { in PHP_FUNCTION()
304 sysvmsg_queue_t *mq = NULL; in PHP_FUNCTION() local
338 …if ((mq = (sysvmsg_queue_t *)zend_fetch_resource(Z_RES_P(queue), "sysvmsg queue", le_sysvmsg)) == … in PHP_FUNCTION()
344 result = msgrcv(mq->id, messagebuffer, maxsize, desiredmsgtype, realflags); in PHP_FUNCTION()
391 sysvmsg_queue_t * mq = NULL; in PHP_FUNCTION() local
403 …if ((mq = (sysvmsg_queue_t *)zend_fetch_resource(Z_RES_P(queue), "sysvmsg queue", le_sysvmsg)) == … in PHP_FUNCTION()
457 result = msgsnd(mq->id, messagebuffer, message_len, blocking ? 0 : IPC_NOWAIT); in PHP_FUNCTION()