]> granicus.if.org Git - php/commitdiff
Fixed __DIR__ in CLI mode.
authorGeorge Wang <gwang@php.net>
Wed, 9 Dec 2015 05:09:14 +0000 (00:09 -0500)
committerGeorge Wang <gwang@php.net>
Wed, 9 Dec 2015 05:09:14 +0000 (00:09 -0500)
sapi/litespeed/lsapi_main.c

index a296261e1ada9bed09a34d8392dc8bf6487b3159..f7098fb20200f4099b547df25dfcbc49357cd698 100644 (file)
@@ -771,6 +771,8 @@ static int cli_main( int argc, char * argv[] )
 
         zend_uv.html_errors = 0; /* tell the engine we're in non-html mode */
         CG(in_compilation) = 0; /* not initialized but needed for several options */
+        SG(options) |= SAPI_OPTION_NO_CHDIR;
+        
 #if PHP_MAJOR_VERSION < 7
         EG(uninitialized_zval_ptr) = NULL;
 #endif