diff options
author | cbeaulac <cbeaulac@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2010-01-09 14:37:54 +0000 |
---|---|---|
committer | cbeaulac <cbeaulac@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 2010-01-09 14:37:54 +0000 |
commit | 736e40c35eee73edf308e41291da08ce352e9aaf (patch) | |
tree | 19e85515c71d50c71497f5d1d0b25eb7885ba5fd | |
parent | 66f1ffc2c4d82a0bafb6940a856950fa9b2644e6 (diff) | |
download | ATCD-736e40c35eee73edf308e41291da08ce352e9aaf.tar.gz |
Sat Jan 9 14:37:12 UTC 2010 Chad Beaulac <chad@objectivesolutions.com>
Merged changes from trunk into Bugzilla #3334 branch
51 files changed, 338 insertions, 497 deletions
@@ -8,7 +8,7 @@ referred to as "DOC software") are copyrighted by [5]Douglas C. Schmidt and his [6]research group at [7]Washington University, [8]University of California, Irvine, and [9]Vanderbilt University, - Copyright (c) 1993-2009, all rights reserved. Since DOC software is + Copyright (c) 1993-2010, all rights reserved. Since DOC software is open-source, freely available software, you are free to use, modify, copy, and distribute--perpetually and irrevocably--the DOC software source code and object code produced from the source, as well as copy @@ -104,7 +104,7 @@ References 16. http://www.dre.vanderbilt.edu/ 17. http://www.isis.vanderbilt.edu/ 18. http://www.cs.wustl.edu/~schmidt/doc-center.html - 19. http://www.cs.wustl.edu/~schmidt/commercial-support.html + 19. http://www.cs.wustl.edu/~schmidt/commercial-support.html 20. mailto:d.schmidt@vanderbilt.edu 21. http://www.dre.vanderbilt.edu/~schmidt/ 22. http://www.cs.wustl.edu/ACE.html diff --git a/ChangeLog b/ChangeLog index 0f1c66675dd..7bcf2d45193 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,293 +1,3 @@ -Mon Dec 14 14:58:05 UTC 2009 Abdul Sowayan <sowayan@gmail.com> - - * NEWS: - - Updated to note iPhone/iPod Touch support. - -Mon Dec 14 11:21:46 UTC 2009 Johnny Willemsen <jwillemsen@remedy.nl> - - * html/Stats/index.shtml: - Updated link to PS3/IBM Cell performance graphs - -Mon Dec 14 10:58:46 UTC 2009 Johnny Willemsen <jwillemsen@remedy.nl> - - * examples/Export/run_test.pl: - Fixed fuzz error - -Sun Dec 13 22:38:13 UTC 2009 Abdul Sowayan <sowayan@gmail.com> - - * include/makeinclude/platform_macosx_iphone.GNU: - - Changed to allow iPhone Hardware compiler to generate executables. - -Sun Dec 13 18:30:26 UTC 2009 Abdul Sowayan <sowayan@gmail.com> - - * include/makeinclude/platform_macosx_iphone.GNU: - - Enhanced iPhone support. Now we can build for the iPhone - Hardware target in addition to the simulator. - -Sat Dec 12 15:40:13 UTC 2009 Abdul Sowayan <sowayan@gmail.com> - - * ace/config-macosx-iphone.h: - * include/makeinclude/platform_macosx_iphone.GNU: - - First cut at supporting iPhone 3.1.2. These files need - some cleanup. With these files, using the iPhone simulator - I was able to spawn ACE Threads, print ACE Logs messages, - and communicate between the the iPhone simulator and a - Windows machine using CORBA. - -Thu Dec 10 20:03:58 UTC 2009 Johnny Willemsen <jwillemsen@remedy.nl> - - * bin/fuzz.pl: - Improved error message - -Thu Dec 10 15:37:58 UTC 2009 Johnny Willemsen <jwillemsen@remedy.nl> - - * bin/ACETAOCIAO.style: - Small updates - -Thu Dec 10 15:10:58 UTC 2009 Johnny Willemsen <jwillemsen@remedy.nl> - - * bin/fuzz.pl: - Check all run_*.pl files for fuzz - -Thu Dec 10 13:07:58 UTC 2009 Johnny Willemsen <jwillemsen@remedy.nl> - - * ace/config-win32-borland.h: - Removed hard supported version check - -Wed Dec 9 10:52:26 UTC 2009 Denis Budko <denis.budko@remedy.nl> - - * bin/fuzz.pl: - - Updated conditions for new framework - -Mon Dec 7 16:09:18 UTC 2009 Steve Huston <shuston@riverace.com> - - * tests/Basic_Types_Test.cpp: Add a verification for the endianness - setting. - -Mon Dec 7 07:40:00 UTC 2009 Johnny Willemsen <jwillemsen@remedy.nl> - - * bin/MakeProjectCreator/config/bmake.features: - Disable mcpp for bmake - -Fri Dec 4 23:24:21 UTC 2009 Yan Dai <dai_y@ociweb.com> - - * bin/MakeProjectCreator/config/global.features: - - Added mpc feature to optionally turn on the indirection - support on valuetype outgoing message. It defaults to - be enabled. To be compatible with previous version TAO, - it needs run mwc.pl with - "-features valuetype_out_indirection=0" to disable it. - -Fri Dec 4 17:25:32 UTC 2009 Yan Dai <dai_y@ociweb.com> - - * NEWS: - - Removed entry for member validation feature in LoadBalancer as it - should be in TAO NEWS. - -Fri Dec 4 13:19:00 UTC 2009 Johnny Willemsen <jwillemsen@remedy.nl> - - * html/Stats/index.shtml: - Added link for IBM Cell xampler performance stats - -Fri Dec 4 10:20:23 UTC 2009 Marcel Smit <msmit@remedy.nl> - - * bin/fuzz.pl: - Removed -v option. The information which is generated - by -v should always be visible. - -Fri Dec 4 07:30:00 UTC 2009 Johnny Willemsen <jwillemsen@remedy.nl> - - * ace/config-win32-borland.h: - CB2010 fix - -Thu Dec 3 11:59:00 UTC 2009 Johnny Willemsen <jwillemsen@remedy.nl> - - * bin/fuzz.pl: - Check CIAO_TRACE macros and put all run_*.pl files in a separate - list - -Wed Dec 2 18:17:04 UTC 2009 Yan Dai <dai_y@ociweb.com> - - * NEWS: - - Added entry for member validation feature in LoadBalancer. - -Wed Dec 2 13:46:00 UTC 2009 Martin Corino <mcorino@remedy.nl> - - * debianbuild/{all files containign version numbers}: - Updated to latest micro release. - -Wed Dec 2 13:30:00 UTC 2009 Martin Corino <mcorino@remedy.nl> - - * bin/make_release.py: - Added code to update version numbers in ACE_ROOT/debianbuild files - on release. - Changed to retrieve repo root by default from info of working copy. - -Wed Dec 2 07:51:00 UTC 2009 Johnny Willemsen <jwillemsen@remedy.nl> - - * bin/copy-script.sh: - Also copy md5 files - - * bin/MakeProjectCreator/config/bmake.features: - Enable mcpp for bmake - -Thu Nov 26 02:08:59 UTC 2009 Douglas C. Schmidt <schmidt@dre.vanderbilt.edu> - - * Gaurav Kulshreshtha is the 2300th contributor to ACE+TAO+CIAO! - -Mon Nov 30 19:11:00 UTC 2009 Johnny Willemsen <jwillemsen@remedy.nl> - - * apps/gperf/src/Bool_Array.h: - * apps/gperf/src/Key_List.h: - C++ Builder 2010 fixes - -Mon Nov 30 14:02:00 UTC 2009 Johnny Willemsen <jwillemsen@remedy.nl> - - * ace/Process.cpp: - * ace/Process.h: - Fixed gcc warnings - -Mon Nov 30 12:38:00 UTC 2009 Johnny Willemsen <jwillemsen@remedy.nl> - - * ace/config-win32-borland.h: - Started port to C++ Builder 2010, older versions of C++ Builder are - now deprecated - - * ace/MMAP_Memory_Pool.cpp: - Layout change - - * ace/OS_NS_sys_time.h: - * ace/OS_NS_sys_time.inl: - Removed workarounds for ancient wince versions - - * ace/Process.cpp: - * ace/Process.h: - Use bool and size_t and removed some ugly casts - - * ace/Trace.cpp: - * ace/Trace.h: - Use bool - -Mon Nov 30 10:53:00 UTC 2009 Johnny Willemsen <jwillemsen@remedy.nl> - - * debianbuild/patches/18-fix-bswap-detection.dpatch: - * debianbuild/patches/22-tao_idl-64bit-fix.dpatch: - Removed, not needed anymore - -Mon Nov 30 10:08:00 UTC 2009 Martin Corino <mcorino@remedy.nl> - - * include/makeinclude/platform_linux_common.GNU: - - Added some rules to support cross builds. - Setting the environment variable (or make variable) CROSS_COMPILE - to the platform tool prefix will redefine the CC, CXX and AR - variables and add a '-Wl,-rpath-link' option to the LDFLAGS. - If the HOST_ROOT variable has been set as well TAO_IDLxxx variables - will be redefined as well. - -Mon Nov 30 08:58:00 UTC 2009 Johnny Willemsen <jwillemsen@remedy.nl> - - * bin/diff-builds-and-group-fixed-tests-only.sh: - * bin/Download.html: - updated for x.7.5 - - * bin/make_release.py - * rpmbuild/ace-tao-ciao.spec - * rpmbuild/ace-tao.spec - Updated to match opensuse build service - - * docs/svn/svn-prefs.reg: - Added idl3+ - - * etc/index.html: - Added 5.7.5 - -Sun Nov 29 13:06:02 CST 2009 Johnny Willemsen <jwillemsen@remedy.nl> - - * ACE version 5.7.5 released. - -Thu Nov 26 12:33:00 UTC 2009 Johnny Willemsen <jwillemsen@remedy.nl> - - * tests/Message_Queue_Test.cpp: - Fixed msvc warning - -Thu Nov 26 04:19:02 UTC 2009 William R. Otte <wotte@dre.vanderbilt.edu> - - * tests/Message_Queue_Test.cpp: - - Attempt to resolve warning for MSVC. - -Tue Nov 24 09:39:00 UTC 2009 Johnny Willemsen <jwillemsen@remedy.nl> - - * ace/Tokenizer_T.cpp: - Check if buffer_ is not nil - - * bin/fuzz.pl: - Export files shouldn't be in the ciao repository anymore, all - should be generated by TAO_IDL - -Mon Nov 23 10:56:18 UTC 2009 Marcel Smit <msmit@remedy.nl> - - * THANKS: - Added Wolfgang Pickartz.for solving a TAO_IDL compiler - issue. - -Mon Nov 23 07:53:57 UTC 2009 Johnny Willemsen <jwillemsen@remedy.nl> - - * debianbuild/changelog: - * debianbuild/control: - * debianbuild/dsc: - * debianbuild/rules: - Imported last version from debian - -Thu Nov 19 20:29:57 UTC 2009 Douglas C. Schmidt <schmidt@dre.vanderbilt.edu> - - * ace/Log_Msg_NT_Event_Log.cpp (ACE_Log_Msg_NT_Event_Log::log): - Added checks to ensure that log() works properly if the msg_data - size is greater than ACE_Log_Record::MAXLOGMSGLEN. Thanks to - Gaurav Kulshreshtha <gaurav dot kulshreshtha at onmobile dot - com> for contributing this fix. - -Fri Nov 20 08:45:52 UTC 2009 Olli Savia <ops@iki.fi> - - * ace/Log_Msg.cpp: - Updated documentation for '%S' modifier. - -Fri Nov 20 07:06:04 UTC 2009 Olli Savia <ops@iki.fi> - - * ace/Sig_Handler.cpp: - Reverted: Sun Nov 1 16:47:29 UTC 2009 Olli Savia <ops@iki.fi> - -Thu Nov 19 14:08:29 UTC 2009 Olli Savia <ops@iki.fi> - - * ace/Sig_Handler.cpp: - Reverted: Mon Nov 2 08:36:24 UTC 2009 Olli Savia <ops@iki.fi> - -Wed Nov 19 09:45:00 UTC 2009 Johnny Willemsen <jwillemsen@remedy.nl> - - * ace/config-WinCE.h: - Only define FILE_MAP_COPY when it is not defined yet - -Mon Nov 16 14:40:42 UTC 2009 Olli Savia <ops@iki.fi> - - * include/makeinclude/platform_win32_interix.GNU: - * ace/config-win32-interix.h: - * ace/os_include/sys/os_types.h: - Updated Interix support. - -Sun Nov 15 08:09:00 UTC 2009 Johnny Willemsen <jwillemsen@remedy.nl> - - * debianbuild/*: - Renamed all files for x.7.4 - Fri Nov 13 19:38:00 UTC 2009 Johnny Willemsen <jwillemsen@remedy.nl> * bin/fuzz.pl: @@ -9,15 +9,29 @@ USER VISIBLE CHANGES BETWEEN ACE-5.7.5 and ACE-5.7.6 on the iPhone/iPod Touch device. IPHONE_VERSION, should be set to 3.1.2. One can set - the version to any future or past versions, but + the version to any future or past versions, but only 3.1.2 has been tried. Note that one has to compile ACE/TAO statically as it is believed that the iPhone OS does not support dynamic loading of external libraries. The usual - procedure of cross compiling ACE/TAO applies + procedure of cross compiling ACE/TAO applies (such as setting HOST_ROOT environment variable). +. Added support for Embarcadero C++ Builder 2010 + +. Added option to print a given ACE_Time_Value in the log + message instead of system supplied timestamp as in %T + and %D. + The option is implemented as a variant of the %D/%T + options by using the '#' flag character like '%#D' or + '%#T'. When using this flag an ACE_Time_Value pointer is + expected in the argument list supplied with the log message. + This fixed Bugzilla #3221. + +. Fixed problems with ACE_INET_Addr::is_multicast() on + little endian platforms. This fixed bugzilla #3729. + USER VISIBLE CHANGES BETWEEN ACE-5.7.4 and ACE-5.7.5 ==================================================== @@ -2310,6 +2310,7 @@ Gaurav Kulshreshtha <gaurav dot kulshreshtha at onmobile dot com> Wolfgang Pickartz <Wolfgang dot Pickartz at procom.de> Joost Kraaijeveld <J dot Kraaijeveld at Askesis dot nl> Pau Garcia i Quiles <pgquiles at elpauer dot org> +<sailzeng at tencent dot com> I would particularly like to thank Paul Stephenson, who worked with me at Ericsson in the early 1990's. Paul devised the recursive Makefile diff --git a/ace/ACE.cpp b/ace/ACE.cpp index b94c65983c5..03c35fc991d 100644 --- a/ace/ACE.cpp +++ b/ace/ACE.cpp @@ -2423,6 +2423,22 @@ ACE::timestamp (ACE_TCHAR date_and_time[], size_t date_and_timelen, bool return_pointer_to_first_digit) { + return ACE::timestamp (ACE_Time_Value::zero, + date_and_time, + date_and_timelen, + return_pointer_to_first_digit); +} + +// Returns the given timestamp in the form +// "hour:minute:second:microsecond." The month, day, and year are +// also stored in the beginning of the date_and_time array. + +ACE_TCHAR * +ACE::timestamp (const ACE_Time_Value& time_value, + ACE_TCHAR date_and_time[], + size_t date_and_timelen, + bool return_pointer_to_first_digit) +{ //ACE_TRACE ("ACE::timestamp"); if (date_and_timelen < 35) @@ -2432,52 +2448,57 @@ ACE::timestamp (ACE_TCHAR date_and_time[], } #if defined (WIN32) - // Emulate Unix. Win32 does NOT support all the UNIX versions - // below, so DO we need this ifdef. - static const ACE_TCHAR *day_of_week_name[] = - { - ACE_TEXT ("Sun"), - ACE_TEXT ("Mon"), - ACE_TEXT ("Tue"), - ACE_TEXT ("Wed"), - ACE_TEXT ("Thu"), - ACE_TEXT ("Fri"), - ACE_TEXT ("Sat") - }; - - static const ACE_TCHAR *month_name[] = - { - ACE_TEXT ("Jan"), - ACE_TEXT ("Feb"), - ACE_TEXT ("Mar"), - ACE_TEXT ("Apr"), - ACE_TEXT ("May"), - ACE_TEXT ("Jun"), - ACE_TEXT ("Jul"), - ACE_TEXT ("Aug"), - ACE_TEXT ("Sep"), - ACE_TEXT ("Oct"), - ACE_TEXT ("Nov"), - ACE_TEXT ("Dec") - }; - - SYSTEMTIME local; - ::GetLocalTime (&local); - - ACE_OS::sprintf (date_and_time, - ACE_TEXT ("%3s %3s %2d %04d %02d:%02d:%02d.%06d"), - day_of_week_name[local.wDayOfWeek], - month_name[local.wMonth - 1], - (int) local.wDay, - (int) local.wYear, - (int) local.wHour, - (int) local.wMinute, - (int) local.wSecond, - (int) (local.wMilliseconds * 1000)); - return &date_and_time[15 + (return_pointer_to_first_digit != 0)]; -#else /* UNIX */ + if (time_value == ACE_Time_Value::zero) + { + // Emulate Unix. Win32 does NOT support all the UNIX versions + // below, so DO we need this ifdef. + static const ACE_TCHAR *day_of_week_name[] = + { + ACE_TEXT ("Sun"), + ACE_TEXT ("Mon"), + ACE_TEXT ("Tue"), + ACE_TEXT ("Wed"), + ACE_TEXT ("Thu"), + ACE_TEXT ("Fri"), + ACE_TEXT ("Sat") + }; + + static const ACE_TCHAR *month_name[] = + { + ACE_TEXT ("Jan"), + ACE_TEXT ("Feb"), + ACE_TEXT ("Mar"), + ACE_TEXT ("Apr"), + ACE_TEXT ("May"), + ACE_TEXT ("Jun"), + ACE_TEXT ("Jul"), + ACE_TEXT ("Aug"), + ACE_TEXT ("Sep"), + ACE_TEXT ("Oct"), + ACE_TEXT ("Nov"), + ACE_TEXT ("Dec") + }; + + SYSTEMTIME local; + ::GetLocalTime (&local); + + ACE_OS::sprintf (date_and_time, + ACE_TEXT ("%3s %3s %2d %04d %02d:%02d:%02d.%06d"), + day_of_week_name[local.wDayOfWeek], + month_name[local.wMonth - 1], + (int) local.wDay, + (int) local.wYear, + (int) local.wHour, + (int) local.wMinute, + (int) local.wSecond, + (int) (local.wMilliseconds * 1000)); + return &date_and_time[15 + (return_pointer_to_first_digit != 0)]; + } +#endif /* WIN32 */ ACE_TCHAR timebuf[26]; // This magic number is based on the ctime(3c) man page. - ACE_Time_Value cur_time = ACE_OS::gettimeofday (); + ACE_Time_Value cur_time = + (time_value == ACE_Time_Value::zero) ? + ACE_Time_Value (ACE_OS::gettimeofday ()) : time_value; time_t secs = cur_time.sec (); ACE_OS::ctime_r (&secs, @@ -2506,7 +2527,6 @@ ACE::timestamp (ACE_TCHAR date_and_time[], cur_time.usec ()); date_and_time[33] = '\0'; return &date_and_time[15 + (return_pointer_to_first_digit != 0)]; -#endif /* WIN32 */ } // This function rounds the request to a multiple of the page size. diff --git a/ace/ACE.h b/ace/ACE.h index d7f0068e3fb..8894788b627 100644 --- a/ace/ACE.h +++ b/ace/ACE.h @@ -474,6 +474,22 @@ namespace ACE ACE_DIRECTORY_SEPARATOR_CHAR); /** + * Returns the given timestamp in the form + * "hour:minute:second:microsecond." The month, day, and year are + * also stored in the beginning of the @a date_and_time array, which + * is a user-supplied array of size @a time_len> @c ACE_TCHARs. + * Returns 0 if unsuccessful, else returns pointer to beginning of the + * "time" portion of @a date_and_time. If @a + * return_pointer_to_first_digit is 0 then return a pointer to the + * space before the time, else return a pointer to the beginning of + * the time portion. + */ + extern ACE_Export ACE_TCHAR *timestamp (const ACE_Time_Value& time_value, + ACE_TCHAR date_and_time[], + size_t time_len, + bool return_pointer_to_first_digit = false); + + /** * Returns the current timestamp in the form * "hour:minute:second:microsecond." The month, day, and year are * also stored in the beginning of the @a date_and_time array, which diff --git a/ace/High_Res_Timer.cpp b/ace/High_Res_Timer.cpp index ce787c02129..69099214051 100644 --- a/ace/High_Res_Timer.cpp +++ b/ace/High_Res_Timer.cpp @@ -152,9 +152,12 @@ ACE_High_Res_Timer::get_cpuinfo (void) { // If the line "cpu MHz : xxx" is present, then it's a // reliable measure of the CPU speed - according to the - // kernel-source. - scale_factor = (ACE_UINT32) (mhertz + 0.5); - break; + // kernel-source. It's possible to see a 0 value reported. + if (mhertz > 0.0) + { + scale_factor = (ACE_UINT32) (mhertz + 0.5); + break; + } } else if (::sscanf (buf, "bogomips : %lf\n", &bmips) == 1 || ::sscanf (buf, "BogoMIPS : %lf\n", &bmips) == 1) diff --git a/ace/INET_Addr.inl b/ace/INET_Addr.inl index 21d053b7bc5..ab98d632f4e 100644 --- a/ace/INET_Addr.inl +++ b/ace/INET_Addr.inl @@ -216,8 +216,8 @@ ACE_INET_Addr::is_multicast (void) const return this->inet_addr_.in6_.sin6_addr.s6_addr[0] == 0xFF; #endif /* ACE_HAS_IPV6 */ return - this->inet_addr_.in4_.sin_addr.s_addr >= 0xE0000000 && // 224.0.0.0 - this->inet_addr_.in4_.sin_addr.s_addr <= 0xEFFFFFFF; // 239.255.255.255 + (*static_cast<const unsigned char*> ( + static_cast<const void*> (&this->inet_addr_.in4_.sin_addr.s_addr)) & 0xf0) == 0xe0; } #if defined (ACE_HAS_IPV6) diff --git a/ace/Log_Msg.cpp b/ace/Log_Msg.cpp index b06d361ed9a..57e2c6c1d42 100644 --- a/ace/Log_Msg.cpp +++ b/ace/Log_Msg.cpp @@ -1165,7 +1165,7 @@ ACE_Log_Msg::log (const ACE_TCHAR *format_str, case 'A': // ACE_timer_t { ACE_OS::strcpy (fp, ACE_TEXT ("f")); - double value = va_arg (argp, double); + double const value = va_arg (argp, double); if (can_check) this_len = ACE_OS::snprintf (bp, bspace, format, value); else @@ -1649,8 +1649,19 @@ ACE_Log_Msg::log (const ACE_TCHAR *format_str, // Weekday Month day year hour:minute:sec.usec { ACE_TCHAR day_and_time[35]; - ACE::timestamp (day_and_time, - sizeof day_and_time / sizeof (ACE_TCHAR)); + // Did we find the flag indicating a time value argument + if (format[1] == ACE_TEXT('#')) + { + ACE_Time_Value* time_value = va_arg (argp, ACE_Time_Value*); + ACE::timestamp (*time_value, + day_and_time, + sizeof day_and_time / sizeof (ACE_TCHAR)); + } + else + { + ACE::timestamp (day_and_time, + sizeof day_and_time / sizeof (ACE_TCHAR)); + } #if !defined (ACE_WIN32) && defined (ACE_USES_WCHAR) ACE_OS::strcpy (fp, ACE_TEXT ("ls")); #else @@ -1674,14 +1685,33 @@ ACE_Log_Msg::log (const ACE_TCHAR *format_str, #else ACE_OS::strcpy (fp, ACE_TEXT ("s")); #endif - if (can_check) - this_len = ACE_OS::snprintf - (bp, bspace, format, - ACE::timestamp (day_and_time, sizeof day_and_time / sizeof (ACE_TCHAR))); + // Did we find the flag indicating a time value argument + if (format[1] == ACE_TEXT('#')) + { + ACE_Time_Value* time_value = va_arg (argp, ACE_Time_Value*); + if (can_check) + this_len = ACE_OS::snprintf + (bp, bspace, format, + ACE::timestamp (*time_value, + day_and_time, + sizeof day_and_time / sizeof (ACE_TCHAR))); + else + this_len = ACE_OS::sprintf + (bp, format, ACE::timestamp (*time_value, + day_and_time, + sizeof day_and_time / sizeof (ACE_TCHAR))); + } else - this_len = ACE_OS::sprintf - (bp, format, ACE::timestamp (day_and_time, - sizeof day_and_time / sizeof (ACE_TCHAR))); + { + if (can_check) + this_len = ACE_OS::snprintf + (bp, bspace, format, + ACE::timestamp (day_and_time, sizeof day_and_time / sizeof (ACE_TCHAR))); + else + this_len = ACE_OS::sprintf + (bp, format, ACE::timestamp (day_and_time, + sizeof day_and_time / sizeof (ACE_TCHAR))); + } ACE_UPDATE_COUNT (bspace, this_len); break; } diff --git a/ace/Log_Msg.h b/ace/Log_Msg.h index aff1e216e4b..64f647d7229 100644 --- a/ace/Log_Msg.h +++ b/ace/Log_Msg.h @@ -57,7 +57,7 @@ #if !defined (ACE_HEX_DUMP) #define ACE_HEX_DUMP(X) \ do { \ - int __ace_error = ACE_Log_Msg::last_error_adapter (); \ + int const __ace_error = ACE_Log_Msg::last_error_adapter (); \ ACE_Log_Msg *ace___ = ACE_Log_Msg::instance (); \ ace___->conditional_set (__FILE__, __LINE__, 0, __ace_error); \ ace___->log_hexdump X; \ @@ -66,7 +66,7 @@ #if !defined (ACE_RETURN) #define ACE_RETURN(Y) \ do { \ - int __ace_error = ACE_Log_Msg::last_error_adapter (); \ + int const __ace_error = ACE_Log_Msg::last_error_adapter (); \ ACE_Log_Msg *ace___ = ACE_Log_Msg::instance (); \ ace___->set (__FILE__, __LINE__, Y, __ace_error, ace___->restart (), \ ace___->msg_ostream (), ace___->msg_callback ()); \ @@ -76,7 +76,7 @@ #if !defined (ACE_ERROR_RETURN) #define ACE_ERROR_RETURN(X, Y) \ do { \ - int __ace_error = ACE_Log_Msg::last_error_adapter (); \ + int const __ace_error = ACE_Log_Msg::last_error_adapter (); \ ACE_Log_Msg *ace___ = ACE_Log_Msg::instance (); \ ace___->conditional_set (__FILE__, __LINE__, Y, __ace_error); \ ace___->log X; \ @@ -86,7 +86,7 @@ #if !defined (ACE_ERROR) #define ACE_ERROR(X) \ do { \ - int __ace_error = ACE_Log_Msg::last_error_adapter (); \ + int const __ace_error = ACE_Log_Msg::last_error_adapter (); \ ACE_Log_Msg *ace___ = ACE_Log_Msg::instance (); \ ace___->conditional_set (__FILE__, __LINE__, -1, __ace_error); \ ace___->log X; \ @@ -95,7 +95,7 @@ #if !defined (ACE_DEBUG) #define ACE_DEBUG(X) \ do { \ - int __ace_error = ACE_Log_Msg::last_error_adapter (); \ + int const __ace_error = ACE_Log_Msg::last_error_adapter (); \ ACE_Log_Msg *ace___ = ACE_Log_Msg::instance (); \ ace___->conditional_set (__FILE__, __LINE__, 0, __ace_error); \ ace___->log X; \ @@ -105,7 +105,8 @@ #define ACE_ERROR_INIT(VALUE, FLAGS) \ do { \ ACE_Log_Msg *ace___ = ACE_Log_Msg::instance (); \ - ace___->set_flags (FLAGS); ace___->op_status (VALUE); \ + ace___->set_flags (FLAGS); \ + ace___->op_status (VALUE); \ } while (0) #endif #if !defined (ACE_ERROR_BREAK) @@ -528,8 +529,13 @@ public: * - 'S': print out the appropriate signal message corresponding * to var-argument, e.g., as done by strsignal() * - 's': prints a ACE_TCHAR* character string (also see C and W) - * - 'T': print timestamp in hour:minute:sec:usec format. + * - 'T': print timestamp in hour:minute:sec:usec format (plain option, + * i.e. without any flags, prints system supplied timestamp; + * with '#' flag added expects ACE_Time_Value* in argument list) * - 'D': print timestamp as Weekday Month day year hour:minute:sec.usec + * (plain option, i.e. without any flags, prints system supplied + * timestamp; with '#' flag added expects ACE_Time_Value* in + * argument list) * - 't': print thread id (1 if single-threaded) * - 'u': print as unsigned int * - 'w': prints a wide character diff --git a/ace/OS_NS_string.cpp b/ace/OS_NS_string.cpp index b4fbae793e3..280679bf337 100644 --- a/ace/OS_NS_string.cpp +++ b/ace/OS_NS_string.cpp @@ -155,7 +155,7 @@ ACE_OS::strsignal (int signum) { static char signal_text[128]; #if defined (ACE_HAS_STRSIGNAL) - char *ret_val; + char *ret_val = 0; # if defined (ACE_NEEDS_STRSIGNAL_RANGE_CHECK) if (signum < 0 || signum >= ACE_NSIG) @@ -199,8 +199,12 @@ const ACE_WCHAR_T * ACE_OS::strnchr (const ACE_WCHAR_T *s, ACE_WCHAR_T c, size_t len) { for (size_t i = 0; i < len; ++i) - if (s[i] == c) - return s + i; + { + if (s[i] == c) + { + return s + i; + } + } return 0; } @@ -221,8 +225,10 @@ ACE_OS::strnstr (const char *s1, const char *s2, size_t len2) for (size_t i = 0; i <= len; i++) { if (ACE_OS::memcmp (s1 + i, s2, len2) == 0) - // Found a match! Return the index. - return s1 + i; + { + // Found a match! Return the index. + return s1 + i; + } } return 0; @@ -232,20 +238,22 @@ const ACE_WCHAR_T * ACE_OS::strnstr (const ACE_WCHAR_T *s1, const ACE_WCHAR_T *s2, size_t len2) { // Substring length - const size_t len1 = ACE_OS::strlen (s1); + size_t const len1 = ACE_OS::strlen (s1); // Check if the substring is longer than the string being searched. if (len2 > len1) return 0; // Go upto <len> - const size_t len = len1 - len2; + size_t const len = len1 - len2; for (size_t i = 0; i <= len; i++) { if (ACE_OS::memcmp (s1 + i, s2, len2 * sizeof (ACE_WCHAR_T)) == 0) - // Found a match! Return the index. - return s1 + i; + { + // Found a match! Return the index. + return s1 + i; + } } return 0; @@ -325,7 +333,9 @@ ACE_OS::strsncpy (char *dst, const char *src, size_t maxlen) { *rdst = '\0'; if (rsrc != 0) - strncat (rdst, rsrc, --rmaxlen); + { + ACE_OS::strncat (rdst, rsrc, --rmaxlen); + } } else { @@ -345,11 +355,13 @@ ACE_OS::strsncpy (ACE_WCHAR_T *dst, const ACE_WCHAR_T *src, size_t maxlen) if (rmaxlen > 0) { - if (rdst!=rsrc) + if (rdst!= rsrc) { *rdst = ACE_TEXT_WIDE ('\0'); if (rsrc != 0) - strncat (rdst, rsrc, --rmaxlen); + { + ACE_OS::strncat (rdst, rsrc, --rmaxlen); + } } else { @@ -371,11 +383,11 @@ ACE_OS::strtok_r_emulation (char *s, const char *tokens, char **lasts) *lasts = s; if (*s == 0) // We have reached the end return 0; - size_t l_org = ACE_OS::strlen (s); + size_t const l_org = ACE_OS::strlen (s); s = ::strtok (s, tokens); if (s == 0) return 0; - const size_t l_sub = ACE_OS::strlen (s); + size_t const l_sub = ACE_OS::strlen (s); if (s + l_sub < *lasts + l_org) *lasts = s + l_sub + 1; else diff --git a/ace/OS_NS_wchar.cpp b/ace/OS_NS_wchar.cpp index 2e02c87c05d..2563abb930f 100644 --- a/ace/OS_NS_wchar.cpp +++ b/ace/OS_NS_wchar.cpp @@ -157,7 +157,7 @@ ACE_OS::wcsicmp_emulation (const wchar_t *s, const wchar_t *t) size_t ACE_OS::wcslen_emulation (const ACE_WCHAR_T *string) { - const ACE_WCHAR_T *s; + const ACE_WCHAR_T *s = 0; for (s = string; *s; ++s) continue; @@ -178,14 +178,14 @@ ACE_OS::wcsncat_emulation (ACE_WCHAR_T *destination, const ACE_WCHAR_T *s = source; while (*d != 0) - d++; + ++d; do { if ((*d = *s++) == 0) break; - d++; + ++d; } while (--count != 0); *d = 0; @@ -285,7 +285,7 @@ wchar_t * ACE_OS::wcspbrk_emulation (const wchar_t *string, const wchar_t *charset) { - const wchar_t *scanp; + const wchar_t *scanp = 0; int c, sc; while ((c = *string++) != 0) @@ -335,7 +335,7 @@ ACE_OS::wcsspn_emulation (const wchar_t *string, const wchar_t *charset) { const wchar_t *p = string; - const wchar_t *spanp; + const wchar_t *spanp = 0; wchar_t c, sc; // Skip any characters in charset, excluding the terminating \0. diff --git a/ace/Sig_Handler.cpp b/ace/Sig_Handler.cpp index 08330ed704a..3ee5b84146a 100644 --- a/ace/Sig_Handler.cpp +++ b/ace/Sig_Handler.cpp @@ -431,7 +431,9 @@ ACE_Sig_Handlers::register_handler (int signum, // Default is to restart signal handlers. new_disp->flags (new_disp->flags () | SA_RESTART); +#if !defined (ACE_HAS_LYNXOS4_SIGNALS) new_disp->flags (new_disp->flags () | SA_SIGINFO); +#endif /* ACE_HAS_LYNXOS4_SIGNALS */ // Finally install (possibly reinstall) the ACE signal // handler disposition with the SA_RESTART mode enabled. diff --git a/ace/checked_iterator.h b/ace/checked_iterator.h index ac5e44f6dfc..98df3d757b0 100644 --- a/ace/checked_iterator.h +++ b/ace/checked_iterator.h @@ -32,12 +32,12 @@ * @author Ossama Othman */ -# if defined (_MSC_VER) && (_MSC_FULL_VER >= 140050000) +# if defined (_MSC_VER) && (_MSC_FULL_VER >= 140050000) && (!defined (_STLPORT_VERSION)) // Checked iterators are currently only supported in MSVC++ 8 or better. # include <iterator> -# endif /* _MSC_VER >= 1400 */ +# endif /* _MSC_VER >= 1400 && !_STLPORT_VERSION */ -# if defined (_MSC_VER) && (_MSC_FULL_VER >= 140050000) +# if defined (_MSC_VER) && (_MSC_FULL_VER >= 140050000) && (!defined (_STLPORT_VERSION)) template <typename PTR> stdext::checked_array_iterator<PTR> ACE_make_checked_array_iterator (PTR buf, size_t len) @@ -53,6 +53,6 @@ ACE_make_checked_array_iterator (PTR buf, size_t /* len */) // the buffer itself. return buf; } -# endif /* _MSC_VER >= 1400 */ +# endif /* _MSC_VER >= 1400 && !_STLPORT_VERSION */ #endif /* ACE_CHECKED_ITERATOR_H */ diff --git a/ace/config-macosx-iphone.h b/ace/config-macosx-iphone.h index 917673079f0..67d31c1f39b 100644 --- a/ace/config-macosx-iphone.h +++ b/ace/config-macosx-iphone.h @@ -2,7 +2,10 @@ #ifndef ACE_CONFIG_MACOSX_IPHONE_H #define ACE_CONFIG_MACOSX_IPHONE_H +#define ACE_SIZEOF_LONG_DOUBLE 8 + #include "ace/config-macosx-snowleopard.h" + #endif ACE_CONFIG_MACOSX_IPHONE_H diff --git a/ace/config-win32-borland.h b/ace/config-win32-borland.h index d2e1cfb8c36..545d7adb8c5 100644 --- a/ace/config-win32-borland.h +++ b/ace/config-win32-borland.h @@ -155,6 +155,10 @@ # endif #endif +#if (__BORLANDC__ == 0x621) +// C++ Builder 2010 wcsncat seems broken +# define ACE_LACKS_WCSNCAT +#endif #define ACE_WCSDUP_EQUIVALENT ::_wcsdup #define ACE_STRCASECMP_EQUIVALENT ::stricmp diff --git a/apps/gperf/src/Bool_Array.h b/apps/gperf/src/Bool_Array.h index bf5a9ccb810..0089295f748 100644 --- a/apps/gperf/src/Bool_Array.h +++ b/apps/gperf/src/Bool_Array.h @@ -36,7 +36,7 @@ #if defined (ACE_HAS_GPERF) -#if defined (__BORLANDC__) && (__BORLANDC__ <= 0x620) +#if defined (__BORLANDC__) && (__BORLANDC__ < 0x630) #include "gperf_export.h" #endif @@ -47,7 +47,7 @@ * Uses a "Generation Numbering" implementation to minimize * initialization time. */ -#if defined (__BORLANDC__) && (__BORLANDC__ <= 0x620) +#if defined (__BORLANDC__) && (__BORLANDC__ < 0x630) class ACE_GPERF_Export Bool_Array #else class Bool_Array diff --git a/apps/gperf/src/Key_List.h b/apps/gperf/src/Key_List.h index 149ac28d339..7d39532c17c 100644 --- a/apps/gperf/src/Key_List.h +++ b/apps/gperf/src/Key_List.h @@ -34,7 +34,7 @@ #include "Vectors.h" #include "ace/Copy_Disabled.h" -#if defined (__BORLANDC__) && (__BORLANDC__ <= 0x620) +#if defined (__BORLANDC__) && (__BORLANDC__ < 0x630) #include "gperf_export.h" #endif @@ -64,7 +64,7 @@ public: * the Gen_Perf.hash function. A Key_List is a singly-linked list * of List_Nodes. */ -#if defined (__BORLANDC__) && (__BORLANDC__ <= 0x620) +#if defined (__BORLANDC__) && (__BORLANDC__ < 0x630) class ACE_GPERF_Export Key_List : private ACE_Copy_Disabled #else class Key_List : private ACE_Copy_Disabled diff --git a/bin/MakeProjectCreator/config/ace_fl.mpb b/bin/MakeProjectCreator/config/ace_fl.mpb index 99dffd223db..6c9d558870b 100644 --- a/bin/MakeProjectCreator/config/ace_fl.mpb +++ b/bin/MakeProjectCreator/config/ace_fl.mpb @@ -10,7 +10,7 @@ project : ace_x11, ace_gl { CPPFLAGS += $(PLATFORM_GL_CPPFLAGS) $(PLATFORM_X11_CPPFLAGS) LIBS += $(PLATFORM_FL_LIBS) $(PLATFORM_GL_LIBS) $(PLATFORM_X11_LIBS) LDFLAGS += $(PLATFORM_FL_LDFLAGS) $(PLATFORM_GL_LDFLAGS) - LDFLAGS += $(PLATFORM_GL_LDFLAGS) + LDFLAGS += $(PLATFORM_X11_LDFLAGS) } specific(prop:microsoft) { libs += fltkdll diff --git a/bin/PerlACE/ProcessVX.pm b/bin/PerlACE/ProcessVX.pm index 175da90bae6..e273e6f8ed7 100644 --- a/bin/PerlACE/ProcessVX.pm +++ b/bin/PerlACE/ProcessVX.pm @@ -130,6 +130,16 @@ sub IgnoreExeSubDir return $self->{IGNOREEXESUBDIR}; } +sub IgnoreHostRoot +{ + my $self = shift; + + if (@_ != 0) { + $self->{IGNOREHOSTROOT} = shift; + } + + return $self->{IGNOREHOSTROOT}; +} sub delay_factor { my($lps) = 128; diff --git a/bin/PerlACE/ProcessVX_Unix.pm b/bin/PerlACE/ProcessVX_Unix.pm index 7a3b083d3f8..2c40d078f0e 100644 --- a/bin/PerlACE/ProcessVX_Unix.pm +++ b/bin/PerlACE/ProcessVX_Unix.pm @@ -50,6 +50,7 @@ sub new $self->{RUNNING} = 0; $self->{IGNOREEXESUBDIR} = 1; + $self->{IGNOREHOSTROOT} = 0; $self->{PROCESS} = undef; $self->{EXECUTABLE} = shift; $self->{ARGUMENTS} = shift; @@ -467,5 +468,4 @@ sub TimedWait ($) return -1; } - 1; diff --git a/bin/PerlACE/ProcessVX_Win32.pm b/bin/PerlACE/ProcessVX_Win32.pm index 1be9a425d13..a94ef515ba9 100644 --- a/bin/PerlACE/ProcessVX_Win32.pm +++ b/bin/PerlACE/ProcessVX_Win32.pm @@ -29,6 +29,7 @@ sub new $self->{RUNNING} = 0; $self->{IGNOREEXESUBDIR} = 1; + $self->{IGNOREHOSTROOT} = 0; $self->{PROCESS} = undef; $self->{EXECUTABLE} = shift; $self->{ARGUMENTS} = shift; @@ -407,5 +408,4 @@ sub Kill () $self->{RUNNING} = 0; } - 1; diff --git a/bin/PerlACE/ProcessWinCE.pm b/bin/PerlACE/ProcessWinCE.pm index 7f6bed61dd0..9c7d92932be 100644 --- a/bin/PerlACE/ProcessWinCE.pm +++ b/bin/PerlACE/ProcessWinCE.pm @@ -29,6 +29,7 @@ sub new $self->{RUNNING} = 0; $self->{IGNOREEXESUBDIR} = 1; + $self->{IGNOREHOSTROOT} = 0; $self->{PROCESS} = undef; $self->{TARGET} = shift; $self->{EXECUTABLE} = shift; diff --git a/bin/PerlACE/ProcessWinCE_Unix.pm b/bin/PerlACE/ProcessWinCE_Unix.pm index 74d63663909..5354a427240 100644 --- a/bin/PerlACE/ProcessWinCE_Unix.pm +++ b/bin/PerlACE/ProcessWinCE_Unix.pm @@ -50,6 +50,7 @@ sub new $self->{RUNNING} = 0; $self->{IGNOREEXESUBDIR} = 1; + $self->{IGNOREHOSTROOT} = 0; $self->{PROCESS} = undef; $self->{EXECUTABLE} = shift; $self->{ARGUMENTS} = shift; diff --git a/bin/bootstrap b/bin/bootstrap index 9aadb28bf13..9b35e3e21da 100755 --- a/bin/bootstrap +++ b/bin/bootstrap @@ -70,9 +70,9 @@ if test -d m4; then # Update the NEWS file # For now just copy the contents of the `VERSION' file to make automake # happy. Eventually, we should start putting real news in to it. -# echo "Creating a NEWS file" -# cp VERSION NEWS + autoupdate -f + # autoreconf -I m4 --install --force --symlink --verbose autoreconf -I m4 --install --force diff --git a/bin/fuzz.pl b/bin/fuzz.pl index 94d132a4c5f..b467beb2da9 100755 --- a/bin/fuzz.pl +++ b/bin/fuzz.pl @@ -50,7 +50,6 @@ use PerlACE::Run_Test; @files_noncvs = (); @files_sln = (); @files_vcproj = (); -@files_run_pl = (); # To keep track of errors and warnings $errors = 0; @@ -123,9 +122,6 @@ sub store_file ($) } elsif ($name =~ /\.pl$/i) { push @files_pl, ($name); - if ($name =~ /run.*\.pl$/i) { - push @files_run_pl, ($name); - } } elsif ($name =~ /\.vcproj$/i) { push @files_vcproj, ($name); @@ -367,19 +363,6 @@ sub check_for_ACE_SYNCH_MUTEX () } } -# This test checks for not having export files in CIAO, all have to be --- -# generated using TAO_IDL -sub check_for_export_file () -{ - print "Running export file check\n"; - ITERATION: foreach $file (@files_h) { - if (($file =~ /.*CIAO.*export.h/)) { - print_error ("$file:$.: found should be generated by TAO_IDL, check -Gx** option"); - } - } -} - - # This test checks for the use of ACE_Thread_Mutex in TAO/CIAO, # TAO_SYNCH_MUTEX should used instead to make the code build # in single-threaded builds. @@ -1384,7 +1367,21 @@ sub check_for_mismatched_filename () sub check_for_bad_run_test () { print "Running run_test.pl test\n"; - foreach $file (@files_run_pl) { + # Add the know ACE files + if (defined $ENV{"TAO_ROOT"}) { + push @files_lst, $ENV{"TAO_ROOT"} . "/bin/tao_orb_tests.lst"; + push @files_lst, $ENV{"TAO_ROOT"} . "/bin/tao_other_tests.lst"; + } + if (defined $ENV{"CIAO_ROOT"}) { + push @files_lst, $ENV{"CIAO_ROOT"} . "/bin/ciao_tests.lst"; + } + $config_list = new PerlACE::ConfigList; + foreach $file (@files_lst) { + $config_list->load ($file); + } + $config_list->add_one_config ("FUZZ"); + @valid_files = $config_list->valid_entries (); + foreach $file (@valid_files) { if (open (FILE, $file)) { my $is_run_test = 0; my $sub = 0; @@ -1417,20 +1414,20 @@ sub check_for_bad_run_test () print_error ("$file:$.: using Sys::Hostname"); } - if (m/PerlACE::wait_interval_for_process_creation/) { - print_error ("$file:$.: using PerlACE::wait_interval_for_process_creation"); + if (m/\$PerlACE::wait_interval_for_process_creation/) { + print_error ("$file:$.: using \$PerlACE::wait_interval_for_process_creation"); } - if (m/PerlACE::waitforfile_timed/) { - print_error ("$file:$.: using PerlACE::waitforfile_timed"); + if (m/\$PerlACE::waitforfile_timed/) { + print_error ("$file:$.: using \$PerlACE::waitforfile_timed"); } - if (m/PerlACE::is_vxworks_test/) { - print_error ("$file:$.: using PerlACE::is_vxworks_test"); + if (m/\$PerlACE::is_vxworks_test/) { + print_error ("$file:$.: using \$PerlACE::is_vxworks_test"); } - if (m/PerlACE::add_lib_path/) { - print_error ("$file:$.: using PerlACE::add_lib_path, use AddLibPath on the target"); + if (m/\$PerlACE::add_lib_path/) { + print_error ("$file:$.: using \$PerlACE::add_lib_path"); } if (m/PerlACE::Run_Test/) { @@ -1545,7 +1542,7 @@ sub check_for_absolute_ace_wrappers() if (m/\~schmidt\/ACE_wrappers\//) { chomp; print_error ("$file:$.: ~schmidt/ACE_wrappers found"); - print_error ($_); + print_error ($_) if (defined $opt_v); } } close (FILE); @@ -1584,8 +1581,7 @@ sub check_for_bad_ace_trace() # Look for TRACE statements if (m/ACE_OS_TRACE\s*\(\s*\"(.*)\"/ - || m/ACE_TRACE\s*\(\s*\"(.*)\"/ - || m/CIAO_TRACE\s*\(\s*\"(.*)\"/) { + || m/ACE_TRACE\s*\(\s*\"(.*)\"/) { my $trace = $1; # reduce the classname @@ -1601,7 +1597,7 @@ sub check_for_bad_ace_trace() || ($trace =~ m/\:\:/ && !($trace =~ m/\Q$class\E/ && $trace =~ m/\Q$function\E/))) { print_error ("$file:$.: Mismatched TRACE"); print_error ("$file:$.: I see \"$trace\" but I think I'm in \"" - . $class . "::" . $function . "\""); + . $class . "::" . $function . "\"") if (defined $opt_v); } } } @@ -1732,15 +1728,15 @@ sub check_for_include () } if ($disable == 0) { if (/^\s*#\s*include\s*<[(ace)|(TAO)|(CIAO)]\/.*>/) { - print_error ("$file:$.: include <ace\/..> used"); + print_error ("$file:$.: include <ace\/..> used") if ($opt_v); ++$bad_occurance; } if (/^\s*#\s*include\s*<tao\/.*>/) { - print_error ("$file:$.: include <tao\/..> used"); + print_error ("$file:$.: include <tao\/..> used") if ($opt_v); ++$bad_occurance; } if (/^\s*#\s*include\s*<ciao\/.*>/) { - print_error ("$file:$.: include <ciao\/..> used"); + print_error ("$file:$.: include <ciao\/..> used") if ($opt_v); ++$bad_occurance; } } @@ -1991,7 +1987,7 @@ sub check_for_ORB_init () ############################################################################## -use vars qw/$opt_c $opt_d $opt_h $opt_l $opt_t $opt_m/; +use vars qw/$opt_c $opt_d $opt_h $opt_l $opt_t $opt_m $opt_v/; if (!getopts ('cdhl:t:mv') || $opt_h) { print "fuzz.pl [-cdhm] [-l level] [-t test_name][file1, file2, ...]\n"; @@ -2002,6 +1998,7 @@ if (!getopts ('cdhl:t:mv') || $opt_h) { print " -l level set detection level (default = 5)\n"; print " -t test_name specify any single test to run. This will disable the run level setting\n"; print " -m only check locally modified files (uses cvs)\n"; + print " -v verbose mode\n"; print "======================================================\n"; print "list of the tests that could be run:\n"; print "\t check_for_noncvs_files @@ -2068,8 +2065,8 @@ print "--------------------Configuration: Fuzz - Level ",$opt_l, "--------------------\n"; check_for_bad_run_test () if ($opt_l >= 5); -check_for_deprecated_macros () if ($opt_l >= 1); -check_for_refcountservantbase () if ($opt_l >= 1); +check_for_deprecated_macros () if ($opt_l > 1 ); +check_for_refcountservantbase () if ($opt_l > 1 ); check_for_msc_ver_string () if ($opt_l >= 3); check_for_empty_files () if ($opt_l >= 1); check_for_noncvs_files () if ($opt_l >= 1); @@ -2102,11 +2099,10 @@ check_for_changelog_errors () if ($opt_l >= 4); check_for_ptr_arith_t () if ($opt_l >= 4); check_for_include () if ($opt_l >= 5); check_for_non_bool_operators () if ($opt_l > 2); -check_for_long_file_names () if ($opt_l >= 1); -check_for_improper_main_declaration () if ($opt_l >= 1); -check_for_TAO_Local_RefCounted_Object () if ($opt_l >= 1); -check_for_ORB_init () if ($opt_l >= 1); -check_for_export_file () if ($opt_l >= 6); +check_for_long_file_names () if ($opt_l > 1 ); +check_for_improper_main_declaration (); +check_for_TAO_Local_RefCounted_Object (); +check_for_ORB_init (); print "\nFuzz.pl - $errors error(s), $warnings warning(s)\n"; diff --git a/bin/mail_test_stats.sh b/bin/mail_test_stats.sh index 062d3b8025a..3a7256b6910 100755 --- a/bin/mail_test_stats.sh +++ b/bin/mail_test_stats.sh @@ -1,9 +1,10 @@ -export TREE_ROOT=/home/build/ACE/latest +export TREE_ROOT=$HOME/ACE/latest export ACE_ROOT=$TREE_ROOT/ACE_wrappers export TAO_ROOT=$ACE_ROOT/TAO export CIAO_ROOT=$TAO_ROOT/CIAO +mkdir -p $TREE_ROOT cd $TREE_ROOT -svn up +svn co svn://svn.dre.vanderbilt.edu/DOC/Middleware/sets-anon/ACE+TAO+CIAO . cd $ACE_ROOT/bin rm *Tests.txt rm *TestRev.txt @@ -12,7 +13,7 @@ rm *Builds.txt ./diff-builds-and-group-fixed-tests-only.sh MAILTO="devo-group@list.isis.vanderbilt.edu" -MAIL="/usr/bin/mail -S smtp=10.2.0.3" +MAIL="mail -S smtp=10.2.0.3" MAILFROM="jwillemsen@remedy.nl" MAIL_ATTACHMENTS= diff --git a/etc/ace.doxygen b/etc/ace.doxygen index 4dd9e83c471..59fb8cd41b9 100644 --- a/etc/ace.doxygen +++ b/etc/ace.doxygen @@ -142,7 +142,7 @@ EXPAND_AS_DEFINED = ACE_RCSID \ ACE_T2 #--------------------------------------------------------------------------- -# Configuration::addtions related to external references +# Configuration::additions related to external references #--------------------------------------------------------------------------- TAGFILES = @@ -169,7 +169,7 @@ DOT_MULTI_TARGETS = YES DOT_PATH = #--------------------------------------------------------------------------- -# Configuration::addtions related to the search engine +# Configuration::additions related to the search engine #--------------------------------------------------------------------------- SEARCHENGINE = YES diff --git a/etc/ace_man.doxygen b/etc/ace_man.doxygen index 77b486e6c3f..fb68ad5a788 100644 --- a/etc/ace_man.doxygen +++ b/etc/ace_man.doxygen @@ -130,7 +130,7 @@ EXPAND_AS_DEFINED = ACE_RCSID \ ACE_THROW_SPEC #--------------------------------------------------------------------------- -# Configuration::addtions related to external references +# Configuration::additions related to external references #--------------------------------------------------------------------------- TAGFILES = @@ -157,7 +157,7 @@ DOT_MULTI_TARGETS = YES DOT_PATH = #--------------------------------------------------------------------------- -# Configuration::addtions related to the search engine +# Configuration::additions related to the search engine #--------------------------------------------------------------------------- SEARCHENGINE = NO diff --git a/etc/ace_qos.doxygen b/etc/ace_qos.doxygen index 8fd8b0f3996..8bfe08dd69b 100644 --- a/etc/ace_qos.doxygen +++ b/etc/ace_qos.doxygen @@ -130,7 +130,7 @@ EXPAND_AS_DEFINED = ACE_RCSID \ ACE_THROW_SPEC #--------------------------------------------------------------------------- -# Configuration::addtions related to external references +# Configuration::additions related to external references #--------------------------------------------------------------------------- TAGFILES = html/ace/ACE.tag=.. @@ -157,7 +157,7 @@ DOT_MULTI_TARGETS = YES DOT_PATH = #--------------------------------------------------------------------------- -# Configuration::addtions related to the search engine +# Configuration::additions related to the search engine #--------------------------------------------------------------------------- SEARCHENGINE = YES diff --git a/etc/ace_rmcast.doxygen b/etc/ace_rmcast.doxygen index 0448d635653..b3b70d77c80 100644 --- a/etc/ace_rmcast.doxygen +++ b/etc/ace_rmcast.doxygen @@ -130,7 +130,7 @@ EXPAND_AS_DEFINED = ACE_RCSID \ ACE_THROW_SPEC #--------------------------------------------------------------------------- -# Configuration::addtions related to external references +# Configuration::additions related to external references #--------------------------------------------------------------------------- TAGFILES = html/ace/ACE.tag=.. @@ -157,7 +157,7 @@ DOT_MULTI_TARGETS = YES DOT_PATH = #--------------------------------------------------------------------------- -# Configuration::addtions related to the search engine +# Configuration::additions related to the search engine #--------------------------------------------------------------------------- SEARCHENGINE = YES diff --git a/etc/ace_ssl.doxygen b/etc/ace_ssl.doxygen index 6ab0cbf39eb..b4deff4e2c9 100644 --- a/etc/ace_ssl.doxygen +++ b/etc/ace_ssl.doxygen @@ -130,7 +130,7 @@ EXPAND_AS_DEFINED = ACE_RCSID \ ACE_THROW_SPEC #--------------------------------------------------------------------------- -# Configuration::addtions related to external references +# Configuration::additions related to external references #--------------------------------------------------------------------------- TAGFILES = html/ace/ACE.tag=.. @@ -157,7 +157,7 @@ DOT_MULTI_TARGETS = YES DOT_PATH = #--------------------------------------------------------------------------- -# Configuration::addtions related to the search engine +# Configuration::additions related to the search engine #--------------------------------------------------------------------------- SEARCHENGINE = YES diff --git a/etc/acexml.doxygen b/etc/acexml.doxygen index 880863c44cb..ccb5dd45b97 100644 --- a/etc/acexml.doxygen +++ b/etc/acexml.doxygen @@ -130,7 +130,7 @@ EXPAND_AS_DEFINED = ACE_RCSID \ ACE_THROW_SPEC #--------------------------------------------------------------------------- -# Configuration::addtions related to external references +# Configuration::additions related to external references #--------------------------------------------------------------------------- TAGFILES = html/ace/ACE.tag=../ace @@ -157,7 +157,7 @@ DOT_MULTI_TARGETS = YES DOT_PATH = #--------------------------------------------------------------------------- -# Configuration::addtions related to the search engine +# Configuration::additions related to the search engine #--------------------------------------------------------------------------- SEARCHENGINE = YES diff --git a/examples/Reactor/TP_Reactor/run_test.pl b/examples/Reactor/TP_Reactor/run_test.pl index ac07295a735..ef4a059dc6c 100755 --- a/examples/Reactor/TP_Reactor/run_test.pl +++ b/examples/Reactor/TP_Reactor/run_test.pl @@ -5,7 +5,7 @@ eval '(exit $?0)' && eval 'exec perl -S $0 ${1+"$@"}' # $Id$ # -*- perl -*- -use lib '../../../bin'; +use lib "$ENV{ACE_ROOT}/bin"; use PerlACE::Run_Test; $status = 0; diff --git a/examples/Reactor/WFMO_Reactor/run_test.pl b/examples/Reactor/WFMO_Reactor/run_test.pl index e47d878f7c4..3ecbebd4f89 100755 --- a/examples/Reactor/WFMO_Reactor/run_test.pl +++ b/examples/Reactor/WFMO_Reactor/run_test.pl @@ -11,8 +11,7 @@ use PerlACE::TestTarget; # # These tests only run on Win32 # -if ($^O ne "MSWin32") -{ +if ($^O ne "MSWin32") { exit; } @@ -40,8 +39,7 @@ if ($^O ne "MSWin32") my $target = PerlACE::TestTarget::create_target (1) || die "Create target 1 failed\n";; $test_timeout = 60 + $target->ProcessStartWaitInterval(); -for $test (@tests) -{ +for $test (@tests) { print STDOUT "\n________________________________________\n"; print STDOUT "\nStarting test \"$test\""; print STDOUT "\n________________________________________\n\n"; @@ -51,14 +49,11 @@ for $test (@tests) if (! -e $test_process->Executable ()) { print STDERR "Error: " . $test_process->Executable () . " does not exist or is not runnable\n"; - } - else - { + } else { $test_process->Spawn (); $test_result = $test_process->WaitKill ($test_timeout); - if ($test_result != 0) - { + if ($test_result != 0) { print STDERR "\n________________________________________\n"; print STDERR "\nERROR: \"$test\" returned $test_result"; print STDERR "\n________________________________________\n"; diff --git a/include/makeinclude/platform_macosx_iphone.GNU b/include/makeinclude/platform_macosx_iphone.GNU index cadbb4a78e7..448460285c4 100644 --- a/include/makeinclude/platform_macosx_iphone.GNU +++ b/include/makeinclude/platform_macosx_iphone.GNU @@ -14,6 +14,8 @@ ifeq ($(IPHONE_TARGET), HARDWARE) IPHONE_PLATFORM:=$(XCODE)/Platforms/iPhoneOS.platform/Developer IPHONE_SDK:=$(IPHONE_PLATFORM)/SDKs/iPhoneOS${IPHONE_VERSION}.sdk IPHONE_HARDWARE_ARCHITECTURE=armv6 + CODESIGN_ALLOCATE:=$(IPHONE_PLATFORM)/usr/bin/codesign_allocate + POSTLINK=; codesign -f -s "iPhone Developer" $(BIN) endif CC:=$(IPHONE_PLATFORM)/usr/bin/gcc diff --git a/include/makeinclude/wrapper_macros.GNU b/include/makeinclude/wrapper_macros.GNU index 9cc8aedf8a8..c6d62b4f860 100644 --- a/include/makeinclude/wrapper_macros.GNU +++ b/include/makeinclude/wrapper_macros.GNU @@ -729,8 +729,12 @@ ifeq ($(static_libs_only),0) endif # static_libs_only ifdef shared_libs_only - override shared_libs = 1 - override static_libs = + ifdef static_libs_only + $(error Both static_libs_only and shared_libs_only defined.) + else + override shared_libs = 1 + override static_libs = + endif endif # shared_libs_only ifdef static_libs_only override shared_libs = diff --git a/performance-tests/RPC/run_test.pl b/performance-tests/RPC/run_test.pl index 305509dc83a..70e4167efe1 100755 --- a/performance-tests/RPC/run_test.pl +++ b/performance-tests/RPC/run_test.pl @@ -5,7 +5,7 @@ eval '(exit $?0)' && eval 'exec perl -S $0 ${1+"$@"}' # $Id$ # -*- perl -*- -use lib '../../bin'; +use lib "$ENV{ACE_ROOT}/bin"; use PerlACE::Run_Test; $SV = new PerlACE::Process ("server"); diff --git a/performance-tests/SCTP/run_spectrum.pl b/performance-tests/SCTP/run_spectrum.pl index d6ec34e6075..9d1d923e6d5 100755 --- a/performance-tests/SCTP/run_spectrum.pl +++ b/performance-tests/SCTP/run_spectrum.pl @@ -7,7 +7,7 @@ eval '(exit $?0)' && eval 'exec perl -S $0 ${1+"$@"}' use warnings; use strict; -use lib '../../bin'; +use lib "$ENV{ACE_ROOT}/bin"; use PerlACE::Run_Test; use Getopt::Long; use Pod::Usage; diff --git a/performance-tests/TCP/run_test.pl b/performance-tests/TCP/run_test.pl index 34c4f416c39..8000ae6496e 100755 --- a/performance-tests/TCP/run_test.pl +++ b/performance-tests/TCP/run_test.pl @@ -5,8 +5,8 @@ eval '(exit $?0)' && eval 'exec perl -S $0 ${1+"$@"}' # $Id$ # -*- perl -*- -use lib '../../bin'; -use PerlACE::Run_Test; +use lib "$ENV{ACE_ROOT}/bin"; +use PerlACE::TestTarget; $SV = new PerlACE::Process ("tcp_test", "-s"); $CL = new PerlACE::Process ("tcp_test", "-c localhost -i 50000 -b 64"); diff --git a/performance-tests/UDP/run_test.pl b/performance-tests/UDP/run_test.pl index 638b8c18c99..fcd236a40a2 100755 --- a/performance-tests/UDP/run_test.pl +++ b/performance-tests/UDP/run_test.pl @@ -5,8 +5,8 @@ eval '(exit $?0)' && eval 'exec perl -S $0 ${1+"$@"}' # $Id$ # -*- perl -*- -use lib '../../bin'; -use PerlACE::Run_Test; +use lib "$ENV{ACE_ROOT}/bin"; +use PerlACE::TestTarget; $SV = new PerlACE::Process ("udp_test", "-r"); $CL = new PerlACE::Process ("udp_test", "-t -n 10000 localhost"); diff --git a/protocols/tests/HTBP/Reactor_Tests/run_test.pl b/protocols/tests/HTBP/Reactor_Tests/run_test.pl index 13aafef2d43..0ba137a10e1 100755 --- a/protocols/tests/HTBP/Reactor_Tests/run_test.pl +++ b/protocols/tests/HTBP/Reactor_Tests/run_test.pl @@ -35,14 +35,14 @@ $target1->DeleteFile ($synchbase); my $CL = $target2->CreateProcess ("client", " -h $host -p $port"); -$client = $CL->SpawnWaitKill (300); +$client = $CL->SpawnWaitKill ($target2->ProcessStartWaitInterval() + 285); if ($client != 0) { print STDERR "ERROR: client returned $client\n"; $status = 1; } -$server = $SV->WaitKill (10); +$server = $SV->WaitKill ($target1->ProcessStopWaitInterval()); if ($server != 0) { print STDERR "ERROR: server returned $server\n"; diff --git a/protocols/tests/HTBP/Send_Large_Msg/run_test.pl b/protocols/tests/HTBP/Send_Large_Msg/run_test.pl index 6b5255794d9..430f3fdf962 100755 --- a/protocols/tests/HTBP/Send_Large_Msg/run_test.pl +++ b/protocols/tests/HTBP/Send_Large_Msg/run_test.pl @@ -17,7 +17,7 @@ $synchfile = $target1->LocalFile ("$synchbase"); my $port = $target1->RandomPort (); my $host = $target1->HostName(); -my $SV = $target1->CreateProcess("server", "-p $port -o $synchfile"); +my $SV = $target1->CreateProcess ("server", "-p $port -o $synchfile"); my $CL = $target2->CreateProcess ("client", " -h $host -p $port"); $target1->DeleteFile ($synchbase); @@ -34,14 +34,14 @@ if ($target1->WaitForFileTimed ($synchbase, $target1->DeleteFile ($synchbase); -$client = $CL->SpawnWaitKill (300); +$client = $CL->SpawnWaitKill ($target2->ProcessStartWaitInterval() + 285); if ($client != 0) { print STDERR "ERROR: client returned $client\n"; $status = 1; } -$server = $SV->WaitKill (10); +$server = $SV->WaitKill ($target1->ProcessStopWaitInterval()); if ($server != 0) { print STDERR "ERROR: server returned $server\n"; diff --git a/protocols/tests/HTBP/Send_Recv_Tests/run_test.pl b/protocols/tests/HTBP/Send_Recv_Tests/run_test.pl index a5175909548..17b9e3f2193 100755 --- a/protocols/tests/HTBP/Send_Recv_Tests/run_test.pl +++ b/protocols/tests/HTBP/Send_Recv_Tests/run_test.pl @@ -33,14 +33,14 @@ if ($target1->WaitForFileTimed ($synchbase, } $target1->DeleteFile ($synchbase); -$client = $CL->SpawnWaitKill (300); +$client = $CL->SpawnWaitKill ($target2->ProcessStartWaitInterval() + 285); if ($client != 0) { print STDERR "ERROR: client returned $client\n"; $status = 1; } -$server = $SV->WaitKill (10); +$server = $SV->WaitKill ($target1->ProcessStopWaitInterval()); if ($server != 0) { print STDERR "ERROR: server returned $server\n"; diff --git a/protocols/tests/HTBP/ping/run_test.pl b/protocols/tests/HTBP/ping/run_test.pl index 7269c8fcbfc..d5592ee3f26 100755 --- a/protocols/tests/HTBP/ping/run_test.pl +++ b/protocols/tests/HTBP/ping/run_test.pl @@ -35,14 +35,14 @@ if ($target1->WaitForFileTimed ($synchbase, $target1->DeleteFile ($synchbase); -$client = $CL->SpawnWaitKill (300); +$client = $CL->SpawnWaitKill ($target2->ProcessStartWaitInterval() + 285); if ($client != 0) { print STDERR "ERROR: client returned $client\n"; $status = 1; } -$server = $SV->WaitKill (10); +$server = $SV->WaitKill ($target1->ProcessStopWaitInterval()); if ($server != 0) { print STDERR "ERROR: server returned $server\n"; diff --git a/protocols/tests/RMCast/run_test.pl b/protocols/tests/RMCast/run_test.pl index abee8b0594c..2e9d75142ad 100755 --- a/protocols/tests/RMCast/run_test.pl +++ b/protocols/tests/RMCast/run_test.pl @@ -24,7 +24,7 @@ sleep ($target1->ProcessStartWaitInterval()); $sender->Spawn (); -$status = $receiver->WaitKill (40); +$status = $receiver->WaitKill ($target2->ProcessStopWaitInterval() + 30); if ($status != 0) { print STDERR "ERROR: receiver returned $status\n"; diff --git a/tests/Bug_3729_Regression_Test.cpp b/tests/Bug_3729_Regression_Test.cpp index 03d94529706..05d6f5ef7f4 100644 --- a/tests/Bug_3729_Regression_Test.cpp +++ b/tests/Bug_3729_Regression_Test.cpp @@ -22,7 +22,7 @@ struct Multicast_Address int run_main (int, ACE_TCHAR *[]) { - ACE_START_TEST (ACE_TEXT ("Bug_3279_Regression_Test")); + ACE_START_TEST (ACE_TEXT ("Bug_3729_Regression_Test")); int status = 0; // Innocent until proven guilty diff --git a/tests/Log_Msg_Test.cpp b/tests/Log_Msg_Test.cpp index 035ca345e78..e35b2c38e5b 100644 --- a/tests/Log_Msg_Test.cpp +++ b/tests/Log_Msg_Test.cpp @@ -33,6 +33,9 @@ #include "ace/OS_NS_string.h" #include "ace/OS_NS_unistd.h" #include "ace/OS_Memory.h" +#include "ace/OS_NS_sys_time.h" +#include "ace/OS_NS_time.h" +#include "ace/Time_Value.h" ACE_RCSID(tests, Log_Msg_Test, "$Id$") @@ -626,6 +629,12 @@ test_format_specs (void) ACE_DEBUG ((LM_DEBUG, ACE_TEXT ("%m %p\n"), ACE_TEXT("perror"))); ACE_DEBUG ((LM_DEBUG, ACE_TEXT ("%S\n"), SIGINT)); ACE_DEBUG ((LM_DEBUG, ACE_TEXT ("%S\n"), ACE_NSIG)); + ACE_DEBUG ((LM_DEBUG, ACE_TEXT ("%D\n"))); + ACE_Time_Value tv = ACE_OS::gettimeofday (); + tv += ACE_Time_Value (25*60*60); // + 25 hours + ACE_DEBUG ((LM_DEBUG, ACE_TEXT ("%#D\n"), &tv)); + ACE_DEBUG ((LM_DEBUG, ACE_TEXT ("%T\n"))); + ACE_DEBUG ((LM_DEBUG, ACE_TEXT ("%#T\n"), &tv)); Log_Spec_Verify verifier; diff --git a/tests/Message_Queue_Test.cpp b/tests/Message_Queue_Test.cpp index fbf029bc5eb..ac8a7135a8b 100644 --- a/tests/Message_Queue_Test.cpp +++ b/tests/Message_Queue_Test.cpp @@ -123,7 +123,7 @@ Counting_Test_Producer::svc (void) // correct. // Also, to be sure there's not just 1 producer and 1 consumer pinging // back and forth, make the producers randomly delay between blocks. - ACE_OS::srand (static_cast<ACE_RANDR_TYPE> (ACE_OS::time ())); + ACE_OS::srand ((u_int) ACE_OS::time ()); int multiple = ACE_OS::rand () % 10; int delay_ms = (ACE_OS::rand () % 10) / 2; // The delay usually causes the test to time out in the automated @@ -213,7 +213,8 @@ Counting_Test_Consumer::svc (void) // a calculated number of blocks then stop; the test checker will determine // if the number consumed plus the number remaining is correct for the // number produced. - ACE_RANDR_TYPE seed = static_cast<ACE_RANDR_TYPE> (ACE_OS::time ()); + + ACE_RANDR_TYPE seed = ACE_OS::time (); int multiple = ACE_OS::rand_r (seed) % 10; int delay_ms = ACE_OS::rand_r (seed) % 10; diff --git a/tests/run_test.lst b/tests/run_test.lst index e0f46cdcbe8..d954a06fa19 100644 --- a/tests/run_test.lst +++ b/tests/run_test.lst @@ -55,7 +55,7 @@ Bug_3505_Regression_Test Bug_3673_Regression_Test Bug_3709_Regression_Test: !LabVIEW_RT Bug_3710_Regression_Test -Bug_3729_Regression_Test: !FIXED_BUGS_ONLY +Bug_3729_Regression_Test: Bug_3744_Regression_Test: !FIXED_BUGS_ONLY Bug_3758_Regression_Test: !FIXED_BUGS_ONLY CDR_Array_Test: !ACE_FOR_TAO diff --git a/tests/run_test.pl b/tests/run_test.pl index 3efaa000a29..cf31ceca925 100755 --- a/tests/run_test.pl +++ b/tests/run_test.pl @@ -26,8 +26,6 @@ use File::Basename; $config_list = new PerlACE::ConfigList; -PerlACE::add_lib_path("$ENV{ACE_ROOT}/tests"); - ################################################################################ sub check_for_more_configs () @@ -155,7 +153,7 @@ sub run_program ($@) check_log ($program); if ($config_list->check_config ('Codeguard')) { - check_codeguard_log ($program); + check_codeguard_log ($program); } chdir $start_dir; } @@ -332,9 +330,9 @@ sub check_log ($) } print STDERR "======= End Sublog File \n"; } - } + } } - } + } } } @@ -433,6 +431,8 @@ my($oh) = \*STDOUT; my $target = PerlACE::TestTarget::create_target (1); +$target->AddLibPath("$ENV{ACE_ROOT}/tests"); + # Put needed files in place for targets that require them. # # Service_Config_Test needs service config file. @@ -452,16 +452,16 @@ if ($target->PutFile ("Service_Config_Stream_Test.conf", $svc_conf_file) == -1) } foreach $test (@tests) { - if (defined $opt_d) { - print "Would run test $test now\n"; - } - elsif ($config_list->check_config ('Purify')) { - purify_program ($test); - } - else { - run_program ($target, $test); - } - $target->GetStderrLog(); + if (defined $opt_d) { + print "Would run test $test now\n"; + } + elsif ($config_list->check_config ('Purify')) { + purify_program ($test); + } + else { + run_program ($target, $test); + } + $target->GetStderrLog(); } check_resources ($oh) if (!defined $opt_d); |