stdcxx-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From se...@apache.org
Subject svn commit: r432669 - /incubator/stdcxx/trunk/util/cmdopt.cpp
Date Fri, 18 Aug 2006 18:20:00 GMT
Author: sebor
Date: Fri Aug 18 11:20:00 2006
New Revision: 432669

URL: http://svn.apache.org/viewvc?rev=432669&view=rev
Log:
2006-08-18 Andrew Black <ablack@roguewave.com>

	* cmdopt.cpp [!_WIN32 && !_WIN64] (rw_sleep): Declared function
	'extern "C"' if __cplusplus is defined.

2006-08-18 Martin Sebor  <sebor@roguewave.com>

	* cmdopt.cpp: Added comments.

Modified:
    incubator/stdcxx/trunk/util/cmdopt.cpp

Modified: incubator/stdcxx/trunk/util/cmdopt.cpp
URL: http://svn.apache.org/viewvc/incubator/stdcxx/trunk/util/cmdopt.cpp?rev=432669&r1=432668&r2=432669&view=diff
==============================================================================
--- incubator/stdcxx/trunk/util/cmdopt.cpp (original)
+++ incubator/stdcxx/trunk/util/cmdopt.cpp Fri Aug 18 11:20:00 2006
@@ -100,12 +100,19 @@
 };
 
 #if !defined (_WIN32) && !defined (_WIN64)
+
 static void
 rw_sleep (int seconds)
 {
     sleep (seconds);
 }
 
+#ifdef __cplusplus
+
+extern "C" {
+
+#endif   /*__cplusplus */
+
 static int
 rw_signal (int signo, void (*func)(int))
 {
@@ -114,7 +121,15 @@
     act.sa_handler = func;
     return 0 > sigaction (signo, &act, 0);
 }
-#else
+
+#ifdef __cplusplus
+
+}   /* extern "C" */
+
+#endif   /* __cplusplus */
+
+#else   /* if defined (_WIN32) || defined (_WIN64) */
+
 static void
 rw_sleep (int seconds)
 {
@@ -126,7 +141,8 @@
 {
     return SIG_ERR == signal (signo, func);
 }
-#endif
+
+#endif   /* _WIN{32,64}*/
 
 /**
    Display command line switches for program and terminate.



Mime
View raw message