File tree Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Expand file tree Collapse file tree 1 file changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -253,7 +253,7 @@ fn get_ext_dir() -> AResult<PathBuf> {
253253 bail ! ( "Failed to call PHP: {:?}" , cmd) ;
254254 }
255255 let stdout = String :: from_utf8_lossy ( & cmd. stdout ) ;
256- let ext_dir = PathBuf :: from ( & * stdout) ;
256+ let ext_dir = PathBuf :: from ( stdout. rsplit ( " \n " ) . next ( ) . unwrap ( ) ) ;
257257 if !ext_dir. is_dir ( ) {
258258 if ext_dir. exists ( ) {
259259 bail ! (
@@ -283,7 +283,7 @@ fn get_php_ini() -> AResult<PathBuf> {
283283 bail ! ( "Failed to call PHP: {:?}" , cmd) ;
284284 }
285285 let stdout = String :: from_utf8_lossy ( & cmd. stdout ) ;
286- let ini = PathBuf :: from ( & * stdout) ;
286+ let ini = PathBuf :: from ( stdout. rsplit ( " \n " ) . next ( ) . unwrap ( ) ) ;
287287 if !ini. is_file ( ) {
288288 bail ! (
289289 "php.ini does not exist or is not a file at the given path: {:?}" ,
You can’t perform that action at this time.
0 commit comments