diff options
author | mitza <mitza@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2010-06-07 22:36:10 +0000 |
---|---|---|
committer | mitza <mitza@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2010-06-07 22:36:10 +0000 |
commit | 9c8ac4fe3f9ae72de429f270af85bec63bcc0ebc (patch) | |
tree | 259d2b6f82aa039036235ac192cf22512fb5a2bf /ACE/tests/Signal_Test.cpp | |
parent | 2f52e4b0b7cf1d00453d52206681072887a70ec4 (diff) | |
download | ATCD-9c8ac4fe3f9ae72de429f270af85bec63bcc0ebc.tar.gz |
ChangeLogTag: Mon Jun 7 21:39:54 UTC 2010 Adam Mitz <mitza@ociweb.com>
Diffstat (limited to 'ACE/tests/Signal_Test.cpp')
-rw-r--r-- | ACE/tests/Signal_Test.cpp | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/ACE/tests/Signal_Test.cpp b/ACE/tests/Signal_Test.cpp index 9fdf4114183..b77af34e636 100644 --- a/ACE/tests/Signal_Test.cpp +++ b/ACE/tests/Signal_Test.cpp @@ -28,6 +28,8 @@ #include "ace/OS_NS_signal.h" #include "ace/OS_NS_stdio.h" #include "ace/OS_NS_unistd.h" +#include "ace/OS_NS_stdlib.h" +#include "ace/SString.h" ACE_RCSID(tests, Signal_Test, "$Id$") @@ -277,7 +279,7 @@ worker_parent (void *arg) // so we need to indicate that it's the child. const ACE_TCHAR *t = ACE_TEXT (".") ACE_DIRECTORY_SEPARATOR_STR - ACE_TEXT ("Signal_Test") + ACE_TEXT ("%sSignal_Test") ACE_PLATFORM_EXE_SUFFIX ACE_TEXT (" -c"); l_argv[0] = const_cast <ACE_TCHAR *> (t); @@ -287,7 +289,15 @@ worker_parent (void *arg) ACE_ARGV argv (l_argv); // Generate a command-line! - options.command_line (argv.buf ()); + ACE_TString exe_sub_dir; + const ACE_TCHAR *subdir_env = ACE_OS::getenv (ACE_TEXT ("ACE_EXE_SUB_DIR")); + if (subdir_env) + { + exe_sub_dir = subdir_env; + exe_sub_dir += ACE_DIRECTORY_SEPARATOR_STR; + } + + options.command_line (argv.buf (), exe_sub_dir.c_str ()); ACE_Process pm; child_pid = pm.spawn (options); |