Skip to content

Commit 75e2253

Browse files
committed
simplify nr_php_show_exec
1 parent c9563c2 commit 75e2253

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

agent/php_execute.c

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -598,9 +598,6 @@ void nr_php_show_exec(const char* context, NR_EXECUTE_PROTO TSRMLS_DC) {
598598
const char* filename = nr_php_op_array_file_name(NR_OP_ARRAY);
599599
const char* function_name = nr_php_op_array_function_name(NR_OP_ARRAY);
600600
const char* ctx = context ? context : "execute";
601-
#if ZEND_MODULE_API_NO >= ZEND_7_4_X_API_NO
602-
nruserfn_t* wr = nr_php_get_wraprec(execute_data->func);
603-
#endif
604601
argstr[0] = '\0';
605602

606603
if (NR_OP_ARRAY->scope) {
@@ -624,7 +621,7 @@ void nr_php_show_exec(const char* context, NR_EXECUTE_PROTO TSRMLS_DC) {
624621
#if ZEND_MODULE_API_NO < ZEND_7_4_X_API_NO
625622
nr_php_op_array_get_wraprec(NR_OP_ARRAY TSRMLS_CC) ? " *" : "",
626623
#else
627-
wr ? " *" : "",
624+
nr_php_get_wraprec(execute_data->func) ? " *" : "",
628625
#endif
629626
NRP_FILENAME(filename), NR_OP_ARRAY->line_start);
630627
} else if (NR_OP_ARRAY->function_name) {
@@ -646,7 +643,7 @@ void nr_php_show_exec(const char* context, NR_EXECUTE_PROTO TSRMLS_DC) {
646643
#if ZEND_MODULE_API_NO < ZEND_7_4_X_API_NO
647644
nr_php_op_array_get_wraprec(NR_OP_ARRAY TSRMLS_CC) ? " *" : "",
648645
#else
649-
wr ? " *" : "",
646+
nr_php_get_wraprec(execute_data->func) ? " *" : "",
650647
#endif
651648
NRP_FILENAME(filename), NR_OP_ARRAY->line_start);
652649
} else if (NR_OP_ARRAY->filename) {

0 commit comments

Comments
 (0)