Skip to content

Commit 7e0d193

Browse files
committed
fix warnings/50700 stuff
1 parent 5cc9a35 commit 7e0d193

File tree

3 files changed

+8
-3
lines changed

3 files changed

+8
-3
lines changed

phpdbg.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -499,9 +499,14 @@ static inline int php_sapi_phpdbg_ub_write(const char *message, unsigned int len
499499
return phpdbg_write("%s", message);
500500
} /* }}} */
501501

502+
#if PHP_VERSION_ID >= 50700
503+
static inline void php_sapi_phpdbg_flush(void *context TSRMLS_DC) /* {{{ */
504+
{
505+
#else
502506
static inline void php_sapi_phpdbg_flush(void *context) /* {{{ */
503507
{
504508
TSRMLS_FETCH();
509+
#endif
505510

506511
fflush(PHPDBG_G(io)[PHPDBG_STDOUT]);
507512
} /* }}} */

phpdbg_cmd.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -436,7 +436,7 @@ PHPDBG_API phpdbg_input_t **phpdbg_read_argv(char *buffer, int *argc TSRMLS_DC)
436436

437437
case IN_STRING:
438438
phpdbg_error(
439-
"Malformed command line (unclosed quote) @ %d: %s!",
439+
"Malformed command line (unclosed quote) @ %ld: %s!",
440440
(p - buffer)-1, &buffer[(p - buffer)-1]);
441441
break;
442442

phpdbg_opcode.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ char *phpdbg_decode_opline(zend_op_array *ops, zend_op *op, HashTable *vars TSRM
8585
#ifdef ZEND_FAST_CALL
8686
case ZEND_FAST_CALL:
8787
#endif
88-
asprintf(&decode[1], "J%d", op->op1.jmp_addr - ops->opcodes);
88+
asprintf(&decode[1], "J%ld", op->op1.jmp_addr - ops->opcodes);
8989
goto format;
9090

9191
case ZEND_JMPZNZ:
@@ -107,7 +107,7 @@ char *phpdbg_decode_opline(zend_op_array *ops, zend_op *op, HashTable *vars TSRM
107107
#endif
108108
decode[1] = phpdbg_decode_op(ops, &op->op1, op->op1_type, vars TSRMLS_CC);
109109
asprintf(
110-
&decode[2], "J%d", op->op2.jmp_addr - ops->opcodes);
110+
&decode[2], "J%ld", op->op2.jmp_addr - ops->opcodes);
111111
goto result;
112112

113113
case ZEND_RECV_INIT:

0 commit comments

Comments
 (0)