diff options
author | Luke Mewburn <Luke@Mewburn.net> | 2022-09-23 19:01:43 +1000 |
---|---|---|
committer | Luke Mewburn <Luke@Mewburn.net> | 2022-09-23 19:01:43 +1000 |
commit | eb1fccda5feb81606a021382bb8fe4d40c85b087 (patch) | |
tree | 5b6edd9893cf99ef0120d37a8676b6f74f2e65d9 | |
parent | a16ac15dd106967992baef21a91f73f002b2cb79 (diff) | |
download | ATCD-eb1fccda5feb81606a021382bb8fe4d40c85b087.tar.gz |
Fix -Wformat-security issues in examples
-rw-r--r-- | ACE/examples/OS/Process/imore.cpp | 4 | ||||
-rw-r--r-- | ACE/examples/OS/Process/process.cpp | 6 |
2 files changed, 5 insertions, 5 deletions
diff --git a/ACE/examples/OS/Process/imore.cpp b/ACE/examples/OS/Process/imore.cpp index 46233c6f975..bee6f5cd3f6 100644 --- a/ACE/examples/OS/Process/imore.cpp +++ b/ACE/examples/OS/Process/imore.cpp @@ -240,7 +240,7 @@ ACE_TMAIN (int argc, ACE_TCHAR *argv[]) ACE_ERROR_RETURN ((LM_ERROR, "Error, bailing out!\n"), -1); } - options.command_line (executable); + options.command_line (ACE_TEXT("%") ACE_TEXT_PRIs, executable); if (new_process.spawn (options) == -1) { int const error_number = ACE_OS::last_error (); @@ -260,7 +260,7 @@ ACE_TMAIN (int argc, ACE_TCHAR *argv[]) // if your child process don't need to interact with the terminal, // we can use the exact code for Unixes on NT. ACE_Process_Options options; - options.command_line (executable); + options.command_line (ACE_TEXT("%") ACE_TEXT_PRIs, executable); options.set_handles (infile); if (new_process.spawn (options) == -1) { diff --git a/ACE/examples/OS/Process/process.cpp b/ACE/examples/OS/Process/process.cpp index 87e8e53f29e..f0d31e5babd 100644 --- a/ACE/examples/OS/Process/process.cpp +++ b/ACE/examples/OS/Process/process.cpp @@ -124,7 +124,7 @@ test_more () ACE_Process new_process; ACE_Process_Options options; - options.command_line (executable); + options.command_line (ACE_TEXT ("%") ACE_TEXT_PRIs, executable); options.set_handles (infile); if (new_process.spawn (options) == -1) @@ -153,7 +153,7 @@ static void test_date () { ACE_Process_Options options; - options.command_line (DATE_PATH); + options.command_line (ACE_TEXT ("%") ACE_TEXT_PRIs, DATE_PATH); // Try to create a new process running date. ACE_Process new_process; @@ -457,7 +457,7 @@ test_setenv (const ACE_TCHAR *argv0) options.setenv (ACE_TEXT ("ACE_PROCESS_TEST= here's a large number %u"), 0 - 1); options.setenv (ACE_TEXT ("ACE_PROCESS_TEST2"), ACE_TEXT ("ophilli")); - options.command_line (ACE_TEXT ("%") ACE_TEXT_PRIs ACE_TEXT (" -g", argv0); + options.command_line (ACE_TEXT ("%") ACE_TEXT_PRIs ACE_TEXT (" -g"), argv0); ACE_Process process; if (process.spawn (options) == -1) { |