com php-src: Turn interactive mode on, if cli binary is clicked in filemanager: sapi/cli/php_cli.c

From: Date: Thu, 25 May 2017 19:04:56 +0000
Subject: com php-src: Turn interactive mode on, if cli binary is clicked in filemanager: sapi/cli/php_cli.c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-97887@lists.php.net to get a copy of this message
Commit: e5c273dc0ea4cb0e0583af9b4c5889a8c431264f Author: Anatol Belski <ab@php.net> Thu, 25 May 2017 21:01:32 +0200 Parents: d32288b5bf78ad684b73479633a0bc0209a3de35 Branches: master Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=e5c273dc0ea4cb0e0583af9b4c5889a8c431264f Log: Turn interactive mode on, if cli binary is clicked in filemanager Changed paths: M sapi/cli/php_cli.c Diff: diff --git a/sapi/cli/php_cli.c b/sapi/cli/php_cli.c index 0de93d8..ed66a8f 100644 --- a/sapi/cli/php_cli.c +++ b/sapi/cli/php_cli.c @@ -674,7 +674,12 @@ static int do_cli(int argc, char **argv) /* {{{ */ char *exec_direct=NULL, *exec_run=NULL, *exec_begin=NULL, *exec_end=NULL; char *arg_free=NULL, **arg_excp=&arg_free; char *script_file=NULL, *translated_path = NULL; +#if defined(PHP_WIN32) && !defined(PHP_CLI_WIN32_NO_CONSOLE) && (HAVE_LIBREADLINE || HAVE_LIBEDIT) && !defined(COMPILE_DL_READLINE) + DWORD pl[1]; + int interactive = GetConsoleProcessList(pl, 1) == 1; +#else int interactive=0; +#endif int lineno = 0; const char *param_error=NULL; int hide_argv = 0;

« previous php.cvs (#97887) next »