diff options
Diffstat (limited to 'ext/sysvmsg/sysvmsg.c')
-rw-r--r-- | ext/sysvmsg/sysvmsg.c | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/ext/sysvmsg/sysvmsg.c b/ext/sysvmsg/sysvmsg.c index 30d51a672a..afeffcc092 100644 --- a/ext/sysvmsg/sysvmsg.c +++ b/ext/sysvmsg/sysvmsg.c @@ -230,9 +230,9 @@ PHP_FUNCTION(msg_stat_queue) Check whether a message queue exists */ PHP_FUNCTION(msg_queue_exists) { - long key; + php_int_t key; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "l", &key) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "i", &key) == FAILURE) { return; } @@ -248,11 +248,11 @@ PHP_FUNCTION(msg_queue_exists) Attach to a message queue */ PHP_FUNCTION(msg_get_queue) { - long key; - long perms = 0666; + php_int_t key; + php_int_t perms = 0666; sysvmsg_queue_t *mq; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "l|l", &key, &perms) == FAILURE) { + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "i|i", &key, &perms) == FAILURE) { return; } @@ -299,8 +299,8 @@ PHP_FUNCTION(msg_remove_queue) PHP_FUNCTION(msg_receive) { zval *out_message, *queue, *out_msgtype, *zerrcode = NULL; - long desiredmsgtype, maxsize, flags = 0; - long realflags = 0; + php_int_t desiredmsgtype, maxsize, flags = 0; + php_int_t realflags = 0; zend_bool do_unserialize = 1; sysvmsg_queue_t *mq = NULL; struct php_msgbuf *messagebuffer = NULL; /* buffer to transmit */ @@ -308,7 +308,7 @@ PHP_FUNCTION(msg_receive) RETVAL_FALSE; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rlz/lz/|blz/", + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "riz/iz/|biz/", &queue, &desiredmsgtype, &out_msgtype, &maxsize, &out_message, &do_unserialize, &flags, &zerrcode) == FAILURE) { return; @@ -386,7 +386,7 @@ PHP_FUNCTION(msg_receive) PHP_FUNCTION(msg_send) { zval *message, *queue, *zerror=NULL; - long msgtype; + php_int_t msgtype; zend_bool do_serialize = 1, blocking = 1; sysvmsg_queue_t * mq = NULL; struct php_msgbuf * messagebuffer = NULL; /* buffer to transmit */ @@ -395,7 +395,7 @@ PHP_FUNCTION(msg_send) RETVAL_FALSE; - if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "rlz|bbz/", + if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "riz|bbz/", &queue, &msgtype, &message, &do_serialize, &blocking, &zerror) == FAILURE) { return; } @@ -425,7 +425,7 @@ PHP_FUNCTION(msg_send) break; case IS_INT: - message_len = spprintf(&p, 0, "%ld", Z_IVAL_P(message)); + message_len = spprintf(&p, 0, "%pd", Z_IVAL_P(message)); break; case IS_FALSE: message_len = spprintf(&p, 0, "0"); |