php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Return to Bug #72676
Patch php-7.0.9-aix-process-title-test.patch revision 2016-07-26 13:09 UTC by matthieu dot sarter dot external at atos dot net

Patch php-7.0.9-aix-process-title-test.patch for Testing related Bug #72676

Patch version 2016-07-26 13:09 UTC

Return to Bug #72676 | Download this patch
Patch Revisions:

Developer: matthieu.sarter.external@atos.net

diff -Nur php-7.0.3.orig/sapi/cli/tests/cli_process_title_unix.phpt php-7.0.3-aix/sapi/cli/tests/cli_process_title_unix.phpt
--- php-7.0.3.orig/sapi/cli/tests/cli_process_title_unix.phpt	2016-02-02 17:32:21 +0100
+++ php-7.0.3-aix/sapi/cli/tests/cli_process_title_unix.phpt	2016-03-10 17:18:19 +0100
@@ -15,7 +15,12 @@
 if (cli_set_process_title($original_title) === true)
   echo "Successfully set title\n";
 
-$ps_output = shell_exec("ps -p $pid -o command | tail -n 1");
+$ps_process_title_field = "command";
+if (strtoupper(substr(PHP_OS, 0, 13)) == "AIX")
+{
+  $ps_process_title_field = "args";
+}
+$ps_output = shell_exec("ps -p $pid -o $ps_process_title_field | tail -n 1");
 
 if ($ps_output === null)
 {
 
PHP Copyright © 2001-2020 The PHP Group
All rights reserved.
Last updated: Tue Dec 01 18:01:23 2020 UTC