diff options
Diffstat (limited to 'TAO/examples/Kokyu_dsrt_schedulers/muf_example/server.cpp')
-rw-r--r-- | TAO/examples/Kokyu_dsrt_schedulers/muf_example/server.cpp | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/TAO/examples/Kokyu_dsrt_schedulers/muf_example/server.cpp b/TAO/examples/Kokyu_dsrt_schedulers/muf_example/server.cpp index f22355074e1..625df80826e 100644 --- a/TAO/examples/Kokyu_dsrt_schedulers/muf_example/server.cpp +++ b/TAO/examples/Kokyu_dsrt_schedulers/muf_example/server.cpp @@ -7,6 +7,7 @@ #include "tao/RTScheduling/RTScheduler_Manager.h" #include "MUF_Scheduler.h" #include "Task_Stats.h" +#include "ace/Argv_Type_Converter.h" ACE_RCSID(MT_Server, server, "$Id$") @@ -20,7 +21,7 @@ int enable_yield = 1; int parse_args (int argc, char *argv[]) { - ACE_Get_Opt get_opts (argc, argv, "o:n:ds"); + ACE_Get_Arg_Opt<char> get_opts (argc, argv, "o:n:ds"); int c; while ((c = get_opts ()) != -1) @@ -80,8 +81,9 @@ private: Task_Stats task_stats; int -main (int argc, char *argv[]) +ACE_TMAIN (int argc, ACE_TCHAR *argv[]) { + ACE_Argv_Type_Converter convert (argc, argv); MUF_Scheduler* scheduler = 0; RTScheduling::Current_var current; long flags; @@ -98,7 +100,7 @@ main (int argc, char *argv[]) ACE_TRY_NEW_ENV { CORBA::ORB_var orb = - CORBA::ORB_init (argc, argv, "" ACE_ENV_ARG_PARAMETER); + CORBA::ORB_init (convert.get_argc(), convert.get_ASCII_argv(), "" ACE_ENV_ARG_PARAMETER); ACE_TRY_CHECK; CORBA::Object_var poa_object = @@ -118,7 +120,7 @@ main (int argc, char *argv[]) root_poa->the_POAManager (ACE_ENV_SINGLE_ARG_PARAMETER); ACE_TRY_CHECK; - if (parse_args (argc, argv) != 0) + if (parse_args (convert.get_argc(), convert.get_ASCII_argv()) != 0) return 1; if (enable_dynamic_scheduling) @@ -179,7 +181,7 @@ main (int argc, char *argv[]) // If the ior_output_file exists, output the ior to it if (ior_output_file != 0) { - FILE *output_file= ACE_OS::fopen (ior_output_file, "w"); + FILE *output_file= ACE_OS::fopen (ior_output_file, ACE_TEXT("w")); if (output_file == 0) ACE_ERROR_RETURN ((LM_ERROR, "Cannot open output file for writing IOR: %s", |