8000 [Console] Add additional ways to detect OS400 platform by johnkary · Pull Request #16095 · symfony/symfony · GitHub
[go: up one dir, main page]

Skip to content

[Console] Add additional ways to detect OS400 platform #16095

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 2 commits into from
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
[Console] Allow checking for OS400 platform when php_uname() disabled
  • Loading branch information
johnkary committed Oct 3, 2015
commit e397379e226ff8b5904443371ada644f696864c9
8 changes: 7 additions & 1 deletion src/Symfony/Component/Console/Output/ConsoleOutput.php
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,13 @@ protected function hasStderrSupport()
*/
private function isRunningOS400()
{
return 'OS400' === php_uname('s');
$checks = array(
function_exists('php_uname') ? php_uname('s') : '',
getenv('OSTYPE'),
PHP_OS,
);

return false !== stristr(implode(';', $checks), 'OS400');
}

/**
Expand Down
0