diff options
author | ljb1 <ljb1@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 1999-10-31 02:49:22 +0000 |
---|---|---|
committer | ljb1 <ljb1@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 1999-10-31 02:49:22 +0000 |
commit | 6c65d91a137018d3baeaa10f877a0768c01277cc (patch) | |
tree | e400ffbe0828bd82e39e867542f4f5a9c1d84118 | |
parent | 262da4ad7a1f575c03f2e0e4b009f16d22e3b887 (diff) | |
download | ATCD-6c65d91a137018d3baeaa10f877a0768c01277cc.tar.gz |
Sat Oct 30 21:40:48 1999 Luther J Baker <ljb1@cs.wustl.edu>
-rw-r--r-- | TAO/ChangeLog-99c | 16 | ||||
-rw-r--r-- | TAO/tao/ORB_Core.cpp | 32 |
2 files changed, 29 insertions, 19 deletions
diff --git a/TAO/ChangeLog-99c b/TAO/ChangeLog-99c index fea621dfde7..22b07b02733 100644 --- a/TAO/ChangeLog-99c +++ b/TAO/ChangeLog-99c @@ -1,6 +1,18 @@ +Sat Oct 30 21:40:48 1999 Luther J Baker <ljb1@cs.wustl.edu> + + * tao/ORB_Core.cpp (init): Removed ACE_IOSTREAM_TYPE and replaced + code with either FILE* or ofstream* until I find a macro + that will properly represnt either an ofstream* or FILE*. + When (ACE_LACKS_IOSTREAM_TOTALLY) is defined, it produces a FILE* + that works well with open(FILE*...), but if it is not defined, + it returns an iostream which does not work with + ->open (filename,...,..) For now, depending on what is defined, + we create an explicit FILE* or ofstream* to redirect ACE_DEBUG + and ACE_ERROR to. + Sat Oct 30 19:32:49 1999 Balachandran Natarajan <bala@cs.wustl.edu> - * examples/Load_Balancing_persistent/README: + * examples/Load_Balancing_persistent/README: * examples/Load_Balancing_persistent/Identity_Client.cpp: * examples/Load_Balancing_persistent/Identity_Client.h * examples/Load_Balancing_persistent/Identity_Server.cpp: @@ -17,7 +29,7 @@ Sat Oct 30 19:32:49 1999 Balachandran Natarajan <bala@cs.wustl.edu> demonstrates how to make a service persistent. This is a simple extension of the Load_Balancing_Service in $TAO_ROOT/Load_Balancing. Please refer to the README for more - details. + details. Sat Oct 30 12:16:50 1999 Douglas C. Schmidt <schmidt@tango.cs.wustl.edu> diff --git a/TAO/tao/ORB_Core.cpp b/TAO/tao/ORB_Core.cpp index ab77af6434a..8e2e1212e10 100644 --- a/TAO/tao/ORB_Core.cpp +++ b/TAO/tao/ORB_Core.cpp @@ -834,43 +834,41 @@ TAO_ORB_Core::init (int &argc, char *argv[], CORBA::Environment &ACE_TRY_ENV) else if ((current_arg = arg_shifter.get_the_parameter ("-ORBLogFile"))) { - - // USAGE: -ORBLogFile <filename> <a|w> - // I actually accept anything that starts with - // an 'a' ie: append + // redirect all ACE_DEUBG and ACE_ERROR output to a file + // USAGE: -ORBLogFile <filename> + // default: append ASYS_TCHAR* file_name = current_arg; arg_shifter.consume_arg (); - ACE_OSTREAM_TYPE* output_stream; + // + // would rather use ACE_OSTREAM_TYPE out here.. + // but need ACE_FSTREAM_TYPE to call ->open(...) + // and haven't found such a macro to rep FILE* and/or fstream* + // #if defined (ACE_LACKS_IOSTREAM_TOTALLY) - output_stream = ACE_OS::fopen (file_name, "a"); + FILE* output_stream = ACE_OS::fopen (file_name, "a"); ACE_LOG_MSG->msg_ostream (output_stream); #else /* ! ACE_LACKS_IOSTREAM_TOTALLY */ - // - // won't compile on linux ??? - // - // output_stream->open (file_name, flags, 0660); - // - // forced to use constructor with file name - // + ofstream* output_stream; ACE_NEW_RETURN (output_stream, - ofstream(file_name, ios::out | ios::app, 0660), + ofstream (), 1); // - // note: we are allocating dynamic memory here.... - // but I assume it will stay persistent for the life - // of the program. + // note: we are allocating dynamic memory here....but + // I assume it will persist for the life of the program // + output_stream->open (file_name, ios::out | ios::app, 0660); + if (!output_stream->bad ()) { ACE_LOG_MSG->msg_ostream (output_stream); |