summaryrefslogtreecommitdiff
path: root/TAO
diff options
context:
space:
mode:
authorelliott_c <ocielliottc@users.noreply.github.com>2003-04-22 18:55:30 +0000
committerelliott_c <ocielliottc@users.noreply.github.com>2003-04-22 18:55:30 +0000
commit5dbda4cbe83f7f0b1be421f1efe864c0ea109283 (patch)
treee20b53110a3f7f9ee8e7d259b7f86823a06f2c10 /TAO
parentb0f5147b139a54ac350dac80f2a9b5f92112d666 (diff)
downloadATCD-5dbda4cbe83f7f0b1be421f1efe864c0ea109283.tar.gz
ChangeLogTag: Tue Apr 22 13:51:45 2003 Chad Elliott <elliott_c@ociweb.com>
Diffstat (limited to 'TAO')
-rw-r--r--TAO/ChangeLog7
-rw-r--r--TAO/orbsvcs/orbsvcs/LoadBalancing/LB_CPU_Monitor.cpp10
2 files changed, 14 insertions, 3 deletions
diff --git a/TAO/ChangeLog b/TAO/ChangeLog
index 17451d9d391..edaac50a538 100644
--- a/TAO/ChangeLog
+++ b/TAO/ChangeLog
@@ -1,3 +1,10 @@
+Tue Apr 22 13:51:45 2003 Chad Elliott <elliott_c@ociweb.com>
+
+ * orbsvcs/orbsvcs/LoadBalancing/LB_CPU_Monitor.cpp:
+
+ Only #include <sys/loadavg.h> if ACE_HAS_SYS_LOADAVG_H is defined.
+ It only exists with SunOS 5.7 and later.
+
Tue Apr 22 14:26:31 2003 Irfan Pyarali <irfan@oomworks.com>
* tao\RTPortableServer\RT_Servant_Dispatcher.cpp:
diff --git a/TAO/orbsvcs/orbsvcs/LoadBalancing/LB_CPU_Monitor.cpp b/TAO/orbsvcs/orbsvcs/LoadBalancing/LB_CPU_Monitor.cpp
index c61a4969310..32e3cbf1e52 100644
--- a/TAO/orbsvcs/orbsvcs/LoadBalancing/LB_CPU_Monitor.cpp
+++ b/TAO/orbsvcs/orbsvcs/LoadBalancing/LB_CPU_Monitor.cpp
@@ -1,8 +1,8 @@
#include "LB_CPU_Monitor.h"
-#ifdef sun
-# include <sys/loadavg.h>
-#endif /* sun */
+#if defined (ACE_HAS_SYS_LOADAVG_H)
+# include <sys/loadavg.h>
+#endif /* ACE_HAS_SYS_LOADAVG_H */
ACE_RCSID (LoadBalancing,
@@ -130,7 +130,11 @@ TAO_LB_CPU_Monitor::loads (ACE_ENV_SINGLE_ARG_DECL)
# else
+# if defined (ACE_HAS_SYS_LOADAVG_H)
const int samples = ::getloadavg (loadavg, 1);
+# else
+ const int samples = 0;
+# endif /* ACE_HAS_SYS_LOADAVG_H */
# endif /* linux
&& ((__GLIBC__ == 2 && __GLIBC_MINOR__ < 2)