Skip to content

Commit bf41a39

Browse files
author
Michael Herold
committed
Adds fixes for PHP 7.0
1 parent 988257a commit bf41a39

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

systemd.c

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -30,11 +30,11 @@ ZEND_GET_MODULE(systemd)
3030
PHP_FUNCTION(sd_journal_send)
3131
{
3232
struct iovec *iov = NULL;
33-
zval ***args;
33+
zval *args;
3434
int argc, len, i;
3535
char *val;
3636

37-
if (zend_parse_parameters(ZEND_NUM_ARGS() TSRMLS_CC, "+", &args, &argc) != SUCCESS) {
37+
if (zend_parse_parameters(ZEND_NUM_ARGS(), "+", &args, &argc) != SUCCESS) {
3838
return;
3939
}
4040

@@ -46,10 +46,10 @@ PHP_FUNCTION(sd_journal_send)
4646
}
4747

4848
// Iterate through the PHP arguments and fill the iovector.
49-
for (i = 0; i < ZEND_NUM_ARGS() TSRMLS_CC; ++i) {
50-
convert_to_string_ex(args[i]);
51-
val = Z_STRVAL_PP(args[i]);
52-
len = Z_STRLEN_PP(args[i]);
49+
for (i = 0; i < argc; ++i) {
50+
convert_to_string_ex(&args[i]);
51+
val = Z_STRVAL(args[i]);
52+
len = Z_STRLEN(args[i]);
5353
iov[i].iov_base = val;
5454
iov[i].iov_len = len;
5555
}

0 commit comments

Comments
 (0)