Lines Matching refs:PHPDBG_G

147 	zend_hash_init(&PHPDBG_G(bp)[PHPDBG_BREAK_FILE], 8, NULL, php_phpdbg_destroy_bp_file, 0);  in PHP_MINIT_FUNCTION()
148 zend_hash_init(&PHPDBG_G(bp)[PHPDBG_BREAK_FILE_PENDING], 8, NULL, php_phpdbg_destroy_bp_file, 0); in PHP_MINIT_FUNCTION()
149 zend_hash_init(&PHPDBG_G(bp)[PHPDBG_BREAK_SYM], 8, NULL, php_phpdbg_destroy_bp_symbol, 0); in PHP_MINIT_FUNCTION()
150 …zend_hash_init(&PHPDBG_G(bp)[PHPDBG_BREAK_FUNCTION_OPLINE], 8, NULL, php_phpdbg_destroy_bp_methods… in PHP_MINIT_FUNCTION()
151 …zend_hash_init(&PHPDBG_G(bp)[PHPDBG_BREAK_METHOD_OPLINE], 8, NULL, php_phpdbg_destroy_bp_methods, … in PHP_MINIT_FUNCTION()
152 zend_hash_init(&PHPDBG_G(bp)[PHPDBG_BREAK_FILE_OPLINE], 8, NULL, php_phpdbg_destroy_bp_methods, 0); in PHP_MINIT_FUNCTION()
153 zend_hash_init(&PHPDBG_G(bp)[PHPDBG_BREAK_OPLINE], 8, NULL, php_phpdbg_destroy_bp_opline, 0); in PHP_MINIT_FUNCTION()
154 zend_hash_init(&PHPDBG_G(bp)[PHPDBG_BREAK_OPCODE], 8, NULL, php_phpdbg_destroy_bp_opcode, 0); in PHP_MINIT_FUNCTION()
155 zend_hash_init(&PHPDBG_G(bp)[PHPDBG_BREAK_METHOD], 8, NULL, php_phpdbg_destroy_bp_methods, 0); in PHP_MINIT_FUNCTION()
156 zend_hash_init(&PHPDBG_G(bp)[PHPDBG_BREAK_COND], 8, NULL, php_phpdbg_destroy_bp_condition, 0); in PHP_MINIT_FUNCTION()
157 zend_hash_init(&PHPDBG_G(bp)[PHPDBG_BREAK_MAP], 8, NULL, NULL, 0); in PHP_MINIT_FUNCTION()
159 zend_hash_init(&PHPDBG_G(seek), 8, NULL, NULL, 0); in PHP_MINIT_FUNCTION()
160 zend_hash_init(&PHPDBG_G(registered), 8, NULL, php_phpdbg_destroy_registered, 0); in PHP_MINIT_FUNCTION()
162 zend_hash_init(&PHPDBG_G(file_sources), 0, NULL, php_phpdbg_destroy_file_source, 0); in PHP_MINIT_FUNCTION()
178 zend_hash_destroy(&PHPDBG_G(registered)); in PHP_MSHUTDOWN_FUNCTION()
181 if (!(PHPDBG_G(flags) & PHPDBG_IS_QUITTING)) { in PHP_MSHUTDOWN_FUNCTION()
191 if (PHPDBG_G(buffer)) { in PHP_MSHUTDOWN_FUNCTION()
192 free(PHPDBG_G(buffer)); in PHP_MSHUTDOWN_FUNCTION()
193 PHPDBG_G(buffer) = NULL; in PHP_MSHUTDOWN_FUNCTION()
196 if (PHPDBG_G(exec)) { in PHP_MSHUTDOWN_FUNCTION()
197 free(PHPDBG_G(exec)); in PHP_MSHUTDOWN_FUNCTION()
198 PHPDBG_G(exec) = NULL; in PHP_MSHUTDOWN_FUNCTION()
201 if (PHPDBG_G(oplog_list)) { in PHP_MSHUTDOWN_FUNCTION()
202 phpdbg_oplog_list *cur = PHPDBG_G(oplog_list); in PHP_MSHUTDOWN_FUNCTION()
209 zend_arena_destroy(PHPDBG_G(oplog_arena)); in PHP_MSHUTDOWN_FUNCTION()
210 PHPDBG_G(oplog_list) = NULL; in PHP_MSHUTDOWN_FUNCTION()
244 if (PHPDBG_G(stdin_file)) { in PHP_RSHUTDOWN_FUNCTION()
245 fclose(PHPDBG_G(stdin_file)); in PHP_RSHUTDOWN_FUNCTION()
246 PHPDBG_G(stdin_file) = NULL; in PHP_RSHUTDOWN_FUNCTION()
270 if (PHPDBG_G(exec)) { in PHP_FUNCTION()
271 ZVAL_STRINGL(return_value, PHPDBG_G(exec), PHPDBG_G(exec_len)); in PHP_FUNCTION()
272 free(PHPDBG_G(exec)); in PHP_FUNCTION()
276 PHPDBG_G(exec) = zend_strndup(ZSTR_VAL(exec), ZSTR_LEN(exec)); in PHP_FUNCTION()
277 PHPDBG_G(exec_len) = ZSTR_LEN(exec); in PHP_FUNCTION()
362 zend_hash_clean(&PHPDBG_G(bp)[PHPDBG_BREAK_FILE]); in PHP_FUNCTION()
363 zend_hash_clean(&PHPDBG_G(bp)[PHPDBG_BREAK_FILE_PENDING]); in PHP_FUNCTION()
364 zend_hash_clean(&PHPDBG_G(bp)[PHPDBG_BREAK_SYM]); in PHP_FUNCTION()
365 zend_hash_clean(&PHPDBG_G(bp)[PHPDBG_BREAK_FUNCTION_OPLINE]); in PHP_FUNCTION()
366 zend_hash_clean(&PHPDBG_G(bp)[PHPDBG_BREAK_METHOD_OPLINE]); in PHP_FUNCTION()
367 zend_hash_clean(&PHPDBG_G(bp)[PHPDBG_BREAK_FILE_OPLINE]); in PHP_FUNCTION()
368 zend_hash_clean(&PHPDBG_G(bp)[PHPDBG_BREAK_OPLINE]); in PHP_FUNCTION()
369 zend_hash_clean(&PHPDBG_G(bp)[PHPDBG_BREAK_METHOD]); in PHP_FUNCTION()
370 zend_hash_clean(&PHPDBG_G(bp)[PHPDBG_BREAK_COND]); in PHP_FUNCTION()
418 prev = PHPDBG_G(oplog_list); in PHP_FUNCTION()
421 PHPDBG_G(oplog_arena) = zend_arena_create(64 * 1024); in PHP_FUNCTION()
424 PHPDBG_G(oplog_list) = emalloc(sizeof(phpdbg_oplog_list)); in PHP_FUNCTION()
425 PHPDBG_G(oplog_list)->prev = prev; in PHP_FUNCTION()
426 PHPDBG_G(oplog_cur) = &PHPDBG_G(oplog_list)->start; in PHP_FUNCTION()
427 PHPDBG_G(oplog_cur)->next = NULL; in PHP_FUNCTION()
499 HashTable *files = &PHPDBG_G(file_sources); in PHP_FUNCTION()
571 phpdbg_file_source *source = zend_hash_find_ptr(&PHPDBG_G(file_sources), name); in PHP_FUNCTION()
600 if (!PHPDBG_G(oplog_list)) { in PHP_FUNCTION()
605 cur = PHPDBG_G(oplog_list)->start.next; in PHP_FUNCTION()
606 prev = PHPDBG_G(oplog_list)->prev; in PHP_FUNCTION()
608 efree(PHPDBG_G(oplog_list)); in PHP_FUNCTION()
609 PHPDBG_G(oplog_list) = prev; in PHP_FUNCTION()
684 zend_arena_destroy(PHPDBG_G(oplog_arena)); in PHP_FUNCTION()
742 if (PHPDBG_G(flags) & PHPDBG_IN_EVAL) { in php_sapi_phpdbg_log_message()
749 if (PHPDBG_G(flags) & PHPDBG_PREVENT_INTERACTIVE) { in php_sapi_phpdbg_log_message()
771 } while (!(PHPDBG_G(flags) & PHPDBG_IS_STOPPING)); in php_sapi_phpdbg_log_message()
787 zend_hash_destroy(&PHPDBG_G(file_sources)); in php_sapi_phpdbg_deactivate()
788 zend_hash_destroy(&PHPDBG_G(bp)[PHPDBG_BREAK_FILE]); in php_sapi_phpdbg_deactivate()
789 zend_hash_destroy(&PHPDBG_G(bp)[PHPDBG_BREAK_FILE_PENDING]); in php_sapi_phpdbg_deactivate()
790 zend_hash_destroy(&PHPDBG_G(bp)[PHPDBG_BREAK_SYM]); in php_sapi_phpdbg_deactivate()
791 zend_hash_destroy(&PHPDBG_G(bp)[PHPDBG_BREAK_FUNCTION_OPLINE]); in php_sapi_phpdbg_deactivate()
792 zend_hash_destroy(&PHPDBG_G(bp)[PHPDBG_BREAK_METHOD_OPLINE]); in php_sapi_phpdbg_deactivate()
793 zend_hash_destroy(&PHPDBG_G(bp)[PHPDBG_BREAK_FILE_OPLINE]); in php_sapi_phpdbg_deactivate()
794 zend_hash_destroy(&PHPDBG_G(bp)[PHPDBG_BREAK_OPLINE]); in php_sapi_phpdbg_deactivate()
795 zend_hash_destroy(&PHPDBG_G(bp)[PHPDBG_BREAK_OPCODE]); in php_sapi_phpdbg_deactivate()
796 zend_hash_destroy(&PHPDBG_G(bp)[PHPDBG_BREAK_METHOD]); in php_sapi_phpdbg_deactivate()
797 zend_hash_destroy(&PHPDBG_G(bp)[PHPDBG_BREAK_COND]); in php_sapi_phpdbg_deactivate()
798 zend_hash_destroy(&PHPDBG_G(bp)[PHPDBG_BREAK_MAP]); in php_sapi_phpdbg_deactivate()
799 zend_hash_destroy(&PHPDBG_G(seek)); in php_sapi_phpdbg_deactivate()
801 if (PHPDBG_G(ops)) { in php_sapi_phpdbg_deactivate()
802 destroy_op_array(PHPDBG_G(ops)); in php_sapi_phpdbg_deactivate()
803 efree(PHPDBG_G(ops)); in php_sapi_phpdbg_deactivate()
804 PHPDBG_G(ops) = NULL; in php_sapi_phpdbg_deactivate()
819 if (PHPDBG_G(exec)) { in php_sapi_phpdbg_register_vars()
820 len = PHPDBG_G(exec_len); in php_sapi_phpdbg_register_vars()
821 …if (sapi_module.input_filter(PARSE_SERVER, "PHP_SELF", &PHPDBG_G(exec), PHPDBG_G(exec_len), &len))… in php_sapi_phpdbg_register_vars()
822 php_register_variable("PHP_SELF", PHPDBG_G(exec), track_vars_array); in php_sapi_phpdbg_register_vars()
824 …if (sapi_module.input_filter(PARSE_SERVER, "SCRIPT_NAME", &PHPDBG_G(exec), PHPDBG_G(exec_len), &le… in php_sapi_phpdbg_register_vars()
825 php_register_variable("SCRIPT_NAME", PHPDBG_G(exec), track_vars_array); in php_sapi_phpdbg_register_vars()
828 …if (sapi_module.input_filter(PARSE_SERVER, "SCRIPT_FILENAME", &PHPDBG_G(exec), PHPDBG_G(exec_len),… in php_sapi_phpdbg_register_vars()
829 php_register_variable("SCRIPT_FILENAME", PHPDBG_G(exec), track_vars_array); in php_sapi_phpdbg_register_vars()
831 …if (sapi_module.input_filter(PARSE_SERVER, "PATH_TRANSLATED", &PHPDBG_G(exec), PHPDBG_G(exec_len),… in php_sapi_phpdbg_register_vars()
832 php_register_variable("PATH_TRANSLATED", PHPDBG_G(exec), track_vars_array); in php_sapi_phpdbg_register_vars()
876 return PHPDBG_G(php_stdiop_write)(stream, buf, count); in phpdbg_stdiop_write()
1017 if (!(PHPDBG_G(flags) & PHPDBG_IS_INTERACTIVE)) { in phpdbg_sigint_handler()
1019 if (PHPDBG_G(flags) & PHPDBG_IS_SIGNALED) { in phpdbg_sigint_handler()
1028 PHPDBG_G(flags) &= ~PHPDBG_IS_SIGNALED; in phpdbg_sigint_handler()
1030 if (PHPDBG_G(flags) & PHPDBG_IS_STOPPING) { in phpdbg_sigint_handler()
1034 PHPDBG_G(flags) |= PHPDBG_IS_SIGNALED; in phpdbg_sigint_handler()
1035 if (PHPDBG_G(flags) & PHPDBG_PREVENT_INTERACTIVE) { in phpdbg_sigint_handler()
1036 PHPDBG_G(flags) |= PHPDBG_HAS_PAGINATION; in phpdbg_sigint_handler()
1037 PHPDBG_G(flags) &= ~PHPDBG_PREVENT_INTERACTIVE; in phpdbg_sigint_handler()
1053 if (PHPDBG_G(sigsegv_bailout)) { in phpdbg_signal_handler()
1054 LONGJMP(*PHPDBG_G(sigsegv_bailout), FAILURE); in phpdbg_signal_handler()
1056 zend_sigaction(sig, &PHPDBG_G(old_sigsegv_signal), NULL); in phpdbg_signal_handler()
1099 if (!strncasecmp(path, "stdin", 6) && PHPDBG_G(stdin_file)) { in phpdbg_stream_url_wrap_php()
1100 php_stream *stream = php_stream_fopen_from_fd(dup(fileno(PHPDBG_G(stdin_file))), "r", NULL); in phpdbg_stream_url_wrap_php()
1113 …return PHPDBG_G(orig_url_wrap_php)->wops->stream_opener(wrapper, path, mode, options, opened_path,… in phpdbg_stream_url_wrap_php()
1392 PHPDBG_G(flags) = flags; in main()
1404 PHPDBG_G(io)[PHPDBG_STDOUT].fd = fileno(stdout); in main()
1417 PHPDBG_G(flags) |= PHPDBG_IS_QUITTING; in main()
1449 PHPDBG_G(original_free_function) = _free; in main()
1462 _free = PHPDBG_G(original_free_function); in main()
1467 PHPDBG_G(sapi_name_ptr) = sapi_name; in main()
1470 PHPDBG_G(exec) = phpdbg_resolve_path(exec); in main()
1471 PHPDBG_G(exec_len) = PHPDBG_G(exec) ? strlen(PHPDBG_G(exec)) : 0; in main()
1495 SG(request_info).argv[0] = PHPDBG_G(exec) ? estrdup(PHPDBG_G(exec)) : estrdup(""); in main()
1504 …zend_try { zend_sigaction(SIGSEGV, &signal_struct, &PHPDBG_G(old_sigsegv_signal)); } zend_end_try(… in main()
1505 …zend_try { zend_sigaction(SIGBUS, &signal_struct, &PHPDBG_G(old_sigsegv_signal)); } zend_end_try(); in main()
1510 PHPDBG_G(io)[PHPDBG_STDIN].fd = fileno(stdin); in main()
1511 PHPDBG_G(io)[PHPDBG_STDOUT].fd = fileno(stdout); in main()
1512 PHPDBG_G(io)[PHPDBG_STDERR].fd = fileno(stderr); in main()
1515 PHPDBG_G(php_stdiop_write) = php_stream_stdio_ops.write; in main()
1522 PHPDBG_G(orig_url_wrap_php) = tmp_wrapper; in main()
1547 PHPDBG_G(flags) |= PHPDBG_IS_INITIALIZING; in main()
1551 PHPDBG_G(flags) &= ~PHPDBG_IS_INITIALIZING; in main()
1554 if (PHPDBG_G(flags) & PHPDBG_IS_QUITTING) { in main()
1563 PHPDBG_G(flags) |= PHPDBG_IS_QUITTING; in main()
1572 PHPDBG_G(flags) |= PHPDBG_DISCARD_OUTPUT; in main()
1582 PHPDBG_G(flags) &= ~PHPDBG_DISCARD_OUTPUT; in main()
1583 } else if (PHPDBG_G(exec)) { in main()
1585 PHPDBG_G(flags) |= PHPDBG_DISCARD_OUTPUT; in main()
1597 PHPDBG_G(flags) &= ~PHPDBG_DISCARD_OUTPUT; in main()
1601 PHPDBG_G(flags) |= PHPDBG_DISCARD_OUTPUT | PHPDBG_IS_INITIALIZING; in main()
1605 PHPDBG_G(flags) &= ~PHPDBG_DISCARD_OUTPUT & ~PHPDBG_IS_INITIALIZING; in main()
1609 if (PHPDBG_G(ops)) { in main()
1612 …zend_quiet_write(PHPDBG_G(io)[PHPDBG_STDERR].fd, ZEND_STRL("No opcodes could be compiled | No file… in main()
1627PHPDBG_G(flags) = (PHPDBG_G(flags) & ~PHPDBG_HAS_PAGINATION) | PHPDBG_IS_INTERACTIVE | PHPDBG_PREV… in main()
1629 PHPDBG_G(flags) |= PHPDBG_IS_INTERACTIVE; in main()
1649 if ((PHPDBG_G(flags) & PHPDBG_IS_CLEANING)) { in main()
1651 PHPDBG_G(flags) |= PHPDBG_DISCARD_OUTPUT; in main()
1653 PHPDBG_G(flags) &= ~PHPDBG_DISCARD_OUTPUT; in main()
1663 } while (!(PHPDBG_G(flags) & PHPDBG_IS_STOPPING)); in main()
1680 PHPDBG_G(flags) &= ~PHPDBG_IS_CLEANING; in main()
1702 if (!(PHPDBG_G(flags) & PHPDBG_IS_RUNNING)) { in main()
1703 is_exit = !PHPDBG_G(in_execution); in main()
1704 CG(unclean_shutdown) = is_exit || PHPDBG_G(unclean_eval); in main()
1707 if ((PHPDBG_G(flags) & (PHPDBG_IS_CLEANING | PHPDBG_IS_RUNNING)) == PHPDBG_IS_CLEANING) { in main()
1712 …if (PHPDBG_G(exec) && strcmp("Standard input code", PHPDBG_G(exec)) == SUCCESS) { /* i.e. executio… in main()
1713 …phpdbg_file_source *data = zend_hash_str_find_ptr(&PHPDBG_G(file_sources), PHPDBG_G(exec), PHPDBG_… in main()
1729 if (PHPDBG_G(exec)) { in main()
1730 settings->exec = zend_strndup(PHPDBG_G(exec), PHPDBG_G(exec_len)); in main()
1731 settings->exec_len = PHPDBG_G(exec_len); in main()
1733 settings->prompt[0] = PHPDBG_G(prompt)[0]; in main()
1734 settings->prompt[1] = PHPDBG_G(prompt)[1]; in main()
1735 memcpy(ZEND_VOIDP(settings->colors), PHPDBG_G(colors), sizeof(settings->colors)); in main()
1736 settings->input_buflen = PHPDBG_G(input_buflen); in main()
1737 memcpy(settings->input_buffer, PHPDBG_G(input_buffer), settings->input_buflen); in main()
1738 settings->flags = PHPDBG_G(flags) & PHPDBG_PRESERVE_FLAGS_MASK; in main()
1739 first_command = PHPDBG_G(cur_command); in main()
1741 if (PHPDBG_G(prompt)[0]) { in main()
1742 free(PHPDBG_G(prompt)[0]); in main()
1744 if (PHPDBG_G(prompt)[1]) { in main()
1745 free(PHPDBG_G(prompt)[1]); in main()
1747 if (PHPDBG_G(cur_command)) { in main()
1748 free(PHPDBG_G(cur_command)); in main()
1758 if (!(PHPDBG_G(flags) & PHPDBG_IS_QUITTING)) { in main()
1759 PHPDBG_G(flags) |= PHPDBG_IS_QUITTING; in main()
1760 if (PHPDBG_G(in_execution) || is_exit) { in main()
1762 PHPDBG_G(flags) -= PHPDBG_IS_QUITTING; in main()
1770 Z_PTR_P(zv) = (void*)PHPDBG_G(orig_url_wrap_php); in main()
1779 php_stream_stdio_ops.write = PHPDBG_G(php_stdiop_write); in main()