summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog-97a45
-rw-r--r--VERSION2
-rw-r--r--ace/FILE_IO.h3
-rw-r--r--ace/LSOCK.cpp57
-rw-r--r--ace/LSOCK.h7
-rw-r--r--ace/LSOCK_Stream.cpp45
-rw-r--r--ace/LSOCK_Stream.h4
-rw-r--r--ace/OS.h5
-rw-r--r--ace/OS.i25
-rw-r--r--ace/README1
-rw-r--r--ace/SOCK_Dgram.cpp16
-rw-r--r--ace/Shared_Memory_MM.h13
-rw-r--r--ace/Shared_Memory_MM.i8
-rw-r--r--ace/Signal.h4
-rw-r--r--ace/Task_T.cpp2
-rw-r--r--ace/config-hpux-10.x-aCC.h16
-rw-r--r--ace/config-hpux-10.x-g++.h19
17 files changed, 226 insertions, 46 deletions
diff --git a/ChangeLog-97a b/ChangeLog-97a
index 51ebd881440..378899086f8 100644
--- a/ChangeLog-97a
+++ b/ChangeLog-97a
@@ -1,5 +1,45 @@
+Fri Apr 25 00:11:52 1997 Douglas C. Schmidt <schmidt@flamenco.cs.wustl.edu>
+
+ * ace/FILE_IO.h: Removed a trailing default initializer from the
+ send() method since it was ambiguous. Thanks to Carlos O'Ryan
+ for reporting this bug.
+
+ * ace/OS.i (select): Unfortunately the (operator timeval*) defined
+ for ACE_Time_Value was not used in ACE_OS::select (int width,
+ fd_set *rfds, fd_set *wfds, fd_set *efds, const ACE_Time_Value
+ *timeout) because the operator cannot be applied for a
+ ACE_Time_Value*. Therefore, I fixed this as follows:
+
+ ACE_SOCKCALL_RETURN (::select (width,
+ (ACE_FD_SET_TYPE *) rfds,
+ (ACE_FD_SET_TYPE *) wfds,
+ (ACE_FD_SET_TYPE *) efds,
+ timeout == 0 ? 0 : (timeval *) *timeout) , int, -1);
+
+ Thanks to Carlos O'Ryan for reporting this bug.
+
+ * ace: Applied a slew of patches from Carlos O'Ryan in order to
+ get ACE to compile on HP/UX 10.x with the aCC compiler.
+
+ * ace/Shared_Memory_MM: Export the filename in
+ ACE_Shared_Memory_MM class in order to aid debugging. Thanks to
+ Ashish Singhai <singhai@delirius.cs.uiuc.edu> for reporting
+ this.
+
Thu Apr 24 13:56:28 1997 Douglas C. Schmidt <schmidt@flamenco.cs.wustl.edu>
+ * ace/SOCK_Dgram.cpp: Added support for FreeBSD (i.e., BSD 4.4)
+ features for passing file descriptors between processes. Thanks
+ to Nanbor Wang <nw1@cs.wustl.edu> for reporting this.
+
+ * ace/LSOCK_Stream.cpp: Added support for FreeBSD (i.e., BSD 4.4)
+ features for passing file descriptors between processes. Thanks
+ to Nanbor Wang <nw1@cs.wustl.edu> for reporting this.
+
+ * ace/LSOCK.cpp: Added support for FreeBSD (i.e., BSD 4.4)
+ features for passing file descriptors between processes. Thanks
+ to Nanbor Wang <nw1@cs.wustl.edu> for reporting this.
+
* ace/SOCK_Connector.cpp (complete): There's a bug in WinNT that
causes non-blocking connects to fail. The workaround is to
sleep for 1 millisecond. Thanks to Steve Huston
@@ -169,10 +209,7 @@ Tue Apr 22 20:17:00 1997 Douglas C. Schmidt <schmidt@flamenco.cs.wustl.edu>
bug fix at mid April so you may want to CVSup the latest libc_r
library and re-make the pthreaded library.
- Notice that under FreeBSD, the environment variable
- LD_LIBRARY_PATH has no effect at all (for stricter security reason
- ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
- (?)) Also, a shared library must be name as lib<name>.so.<version
+ A shared library must be name as lib<name>.so.<version
number> (e.g. libACE.4.1.0). Therefore, if you want to take
advantage of shared library (libACE.so), you'll need to either
diff --git a/VERSION b/VERSION
index d40e99cdc85..2c2b1e0a171 100644
--- a/VERSION
+++ b/VERSION
@@ -1,4 +1,4 @@
-This is ACE version 4.1.5, released Thu Apr 24 07:50:36 CDT 1997.
+This is ACE version 4.1.6, released Fri Apr 25 00:45:03 CDT 1997.
If you have any problems with ACE, please send email to Douglas
C. Schmidt (schmidt@cs.wustl.edu).
diff --git a/ace/FILE_IO.h b/ace/FILE_IO.h
index 436621ff518..99f97a29aba 100644
--- a/ace/FILE_IO.h
+++ b/ace/FILE_IO.h
@@ -1,7 +1,6 @@
/* -*- C++ -*- */
// $Id$
-
// ============================================================================
//
// = LIBRARY
@@ -57,7 +56,7 @@ public:
ssize_t send (const ACE_Str_Buf *cntl,
const ACE_Str_Buf *data,
int band,
- int flags = 0) const;
+ int flags) const;
// Send bytes via STREAM pipes using "band" mode.
ssize_t recv (ACE_Str_Buf *cntl,
diff --git a/ace/LSOCK.cpp b/ace/LSOCK.cpp
index ee8aa67077f..7ea0375501b 100644
--- a/ace/LSOCK.cpp
+++ b/ace/LSOCK.cpp
@@ -22,12 +22,16 @@ ACE_LSOCK::dump (void) const
// This routine sends an open file descriptor to <this->handle_>.
int
-ACE_LSOCK::send_handle (const ACE_HANDLE fd) const
+ACE_LSOCK::send_handle (const ACE_HANDLE handle) const
{
ACE_TRACE ("ACE_LSOCK::send_handle");
unsigned char a[2];
iovec iov;
msghdr send_msg;
+#if defined (ACE_HAS_4_4BSD_SENDMSG_RECVMSG)
+ char cmsgbuf[ACE_BSD_CONTROL_MSG_LEN];
+ cmsghdr *cmsgptr = (cmsghdr *) cmsgbuf;
+#endif /* ACE_HAS_4_4BSD_SENDMSG_RECVMSG */
a[0] = 0xab;
a[1] = 0xcd;
@@ -37,23 +41,38 @@ ACE_LSOCK::send_handle (const ACE_HANDLE fd) const
send_msg.msg_iovlen = 1;
send_msg.msg_name = 0;
send_msg.msg_namelen = 0;
- send_msg.msg_accrights = (char *) &fd;
- send_msg.msg_accrightslen = sizeof fd;
+
+#if defined (ACE_HAS_4_4BSD_SENDMSG_RECVMSG)
+ cmsgptr->cmsg_level = SOL_SOCKET;
+ cmsgptr->cmsg_type = SCM_RIGHTS;
+ cmsgptr->cmsg_len = sizeof cmsgbuf;
+ send_msg.msg_control = cmsgbuf;
+ send_msg.msg_controllen = sizeof cmsgbuf;
+ *(ACE_HANDLE *) CMSG_DATA (cmsgptr) = handle;
+ send_msg.msg_flags = 0;
+#else
+ send_msg.msg_accrights = (char *) &handle;
+ send_msg.msg_accrightslen = sizeof handle;
+#endif /* ACE_HAS_4_4BSD_SENDMSG_RECVMSG */
return ACE_OS::sendmsg (this->get_handle (), &send_msg, 0);
}
-// This file receives an open file descriptor from THIS->SOK_FD.
+// This file receives an open file descriptor from <this->handle_>.
// Note, this routine returns -1 if problems occur, 0 if we recv a
// message that does not have file descriptor in it, and 1 otherwise.
int
-ACE_LSOCK::recv_handle (ACE_HANDLE &fd, char *pbuf, int *len) const
+ACE_LSOCK::recv_handle (ACE_HANDLE &handle, char *pbuf, int *len) const
{
ACE_TRACE ("ACE_LSOCK::recv_handle");
unsigned char a[2];
iovec iov;
msghdr recv_msg;
+#if defined (ACE_HAS_4_4BSD_SENDMSG_RECVMSG)
+ char cmsgbuf[ACE_BSD_CONTROL_MSG_LEN];
+ cmsghdr *cmsgptr = (cmsghdr *) cmsgbuf;
+#endif /* ACE_HAS_4_4BSD_SENDMSG_RECVMSG */
if (pbuf != 0 && len != 0)
{
@@ -70,8 +89,13 @@ ACE_LSOCK::recv_handle (ACE_HANDLE &fd, char *pbuf, int *len) const
recv_msg.msg_iovlen = 1;
recv_msg.msg_name = 0;
recv_msg.msg_namelen = 0;
- recv_msg.msg_accrights = (char *) &fd;
- recv_msg.msg_accrightslen = sizeof fd;
+#if defined (ACE_HAS_4_4BSD_SENDMSG_RECVMSG)
+ recv_msg.msg_control = cmsgbuf;
+ recv_msg.msg_controllen = sizeof cmsgbuf;
+#else
+ recv_msg.msg_accrights = (char *) &handle;
+ recv_msg.msg_accrightslen = sizeof handle;
+#endif /* ACE_HAS_4_4BSD_SENDMSG_RECVMSG */
#if defined (ACE_HAS_STREAMS)
ssize_t nbytes = ACE_OS::recvmsg (this->get_handle (), &recv_msg, 0);
@@ -97,13 +121,24 @@ ACE_LSOCK::recv_handle (ACE_HANDLE &fd, char *pbuf, int *len) const
&& ((unsigned char *) iov.iov_base)[0] == 0xab
&& ((unsigned char *) iov.iov_base)[1] == 0xcd)
{
- recv_msg.msg_accrights = (char *) &fd;
- recv_msg.msg_accrightslen = sizeof fd;
+#if defined (ACE_HAS_4_4BSD_SENDMSG_RECVMSG)
+ recv_msg.msg_control = cmsgbuf;
+ recv_msg.msg_controllen = sizeof cmsgbuf;
+#else
+ recv_msg.msg_accrights = (char *) &handle;
+ recv_msg.msg_accrightslen = sizeof handle;
+#endif /* ACE_HAS_4_4BSD_SENDMSG_RECVMSG */
- if (ACE_OS::recvmsg (this->get_handle (), &recv_msg, 0) == ACE_INVALID_HANDLE)
+ if (ACE_OS::recvmsg (this->get_handle (),
+ &recv_msg, 0) == ACE_INVALID_HANDLE)
return ACE_INVALID_HANDLE;
else
- return 1;
+ {
+#if defined (ACE_HAS_4_4BSD_SENDMSG_RECVMSG)
+ handle = *(ACE_HANDLE *) CMSG_DATA (cmsgptr) ;
+#endif /* ACE_HAS_4_4BSD_SENDMSG_RECVMSG */
+ return 1;
+ }
}
else
{
diff --git a/ace/LSOCK.h b/ace/LSOCK.h
index 283d0c87a23..4aa734a4da1 100644
--- a/ace/LSOCK.h
+++ b/ace/LSOCK.h
@@ -1,7 +1,6 @@
/* -*- C++ -*- */
// $Id$
-
// ============================================================================
//
// = LIBRARY
@@ -59,12 +58,6 @@ protected:
void set_handle (ACE_HANDLE handle);
// Set handle.
-#if defined (ACE_HAS_4_4BSD_SENDMSG_RECVMSG)
- static const int msg_control_len_
- = sizeof(struct cmsghdr) + sizeof(ACE_HANDLE) ;
- // control message size to pass a file descriptor
-#endif // ACE_HAS_4_4BSD_SENDMSG_RECVMSG
-
private:
ACE_HANDLE aux_handle_;
// An auxiliary handle used to avoid virtual base classes...
diff --git a/ace/LSOCK_Stream.cpp b/ace/LSOCK_Stream.cpp
index eb6db5d0b26..292c6a5090c 100644
--- a/ace/LSOCK_Stream.cpp
+++ b/ace/LSOCK_Stream.cpp
@@ -34,20 +34,35 @@ ACE_LSOCK_Stream::dump (void) const
ssize_t
ACE_LSOCK_Stream::send_msg (const iovec iov[],
size_t n,
- int fd)
+ ACE_HANDLE handle)
{
ACE_TRACE ("ACE_LSOCK_Stream::send_msg");
msghdr send_msg;
+#if defined (ACE_HAS_4_4BSD_SENDMSG_RECVMSG)
+ char cmsgbuf[ACE_BSD_CONTROL_MSG_LEN];
+ cmsghdr *cmsgptr = (cmsghdr *) cmsgbuf;
+#endif /* ACE_HAS_4_4BSD_SENDMSG_RECVMSG */
send_msg.msg_iov = (iovec *) iov;
send_msg.msg_iovlen = n;
send_msg.msg_name = 0;
send_msg.msg_namelen = 0;
- send_msg.msg_accrights = (char *) &fd;
- send_msg.msg_accrightslen = sizeof fd;
+
+#if defined (ACE_HAS_4_4BSD_SENDMSG_RECVMSG)
+ cmsgptr->cmsg_level = SOL_SOCKET;
+ cmsgptr->cmsg_type = SCM_RIGHTS;
+ cmsgptr->cmsg_len = sizeof cmsgbuf;
+ send_msg.msg_control = cmsgbuf;
+ send_msg.msg_controllen = sizeof cmsgbuf;
+ *(ACE_HANDLE *) CMSG_DATA (cmsgptr) = handle;
+ send_msg.msg_flags = 0 ;
+#else
+ send_msg.msg_accrights = (char *) &handle;
+ send_msg.msg_accrightslen = sizeof handle;
+#endif /* ACE_HAS_4_4BSD_SENDMSG_RECVMSG */
return ACE_OS::sendmsg (this->ACE_SOCK_Stream::get_handle (),
- &send_msg, 0);
+ &send_msg, 0);
}
// Read a readv-style vector of buffers, along with an open I/O
@@ -56,20 +71,34 @@ ACE_LSOCK_Stream::send_msg (const iovec iov[],
ssize_t
ACE_LSOCK_Stream::recv_msg (iovec iov[],
size_t n,
- int &fd)
+ ACE_HANDLE &handle)
{
ACE_TRACE ("ACE_LSOCK_Stream::recv_msg");
msghdr recv_msg;
+#if defined (ACE_HAS_4_4BSD_SENDMSG_RECVMSG)
+ char cmsgbuf[ACE_BSD_CONTROL_MSG_LEN];
+ cmsghdr *cmsgptr = (cmsghdr *) cmsgbuf;
+#endif /* ACE_HAS_4_4BSD_SENDMSG_RECVMSG */
recv_msg.msg_iov = (iovec *) iov;
recv_msg.msg_iovlen = n;
recv_msg.msg_name = 0;
recv_msg.msg_namelen = 0;
- recv_msg.msg_accrights = (char *) &fd;
- recv_msg.msg_accrightslen = sizeof fd;
+
+#if defined (ACE_HAS_4_4BSD_SENDMSG_RECVMSG)
+ recv_msg.msg_control = cmsgbuf;
+ recv_msg.msg_controllen = sizeof cmsgbuf;
+ ssize_t result = ACE_OS::recvmsg (this->ACE_SOCK_Stream::get_handle (),
+ &recv_msg, 0);
+ handle = *(ACE_HANDLE*) CMSG_DATA (cmsgptr) ;
+ return result;
+#else
+ recv_msg.msg_accrights = (char *) &handle;
+ recv_msg.msg_accrightslen = sizeof handle;
return ACE_OS::recvmsg (this->ACE_SOCK_Stream::get_handle (),
- &recv_msg, 0);
+ &recv_msg, 0);
+#endif /* ACE_HAS_4_4BSD_SENDMSG_RECVMSG */
}
#endif /* ACE_HAS_MSG */
#endif /* ACE_LACKS_UNIX_DOMAIN_SOCKETS */
diff --git a/ace/LSOCK_Stream.h b/ace/LSOCK_Stream.h
index 4903787777e..13bda9b8b8b 100644
--- a/ace/LSOCK_Stream.h
+++ b/ace/LSOCK_Stream.h
@@ -30,10 +30,10 @@ class ACE_Export ACE_LSOCK_Stream : public ACE_SOCK_Stream, public ACE_LSOCK
{
public:
// = Send/recv methods.
- ssize_t send_msg (const iovec iov[], size_t n, int fd);
+ ssize_t send_msg (const iovec iov[], size_t n, ACE_HANDLE handle);
// Send iovecs via <::writev>.
- ssize_t recv_msg (iovec iov[], size_t n, int &fd);
+ ssize_t recv_msg (iovec iov[], size_t n, ACE_HANDLE &handle);
// Send iovecs via <::writev>.
ACE_HANDLE get_handle (void) const;
diff --git a/ace/OS.h b/ace/OS.h
index 62d9fbd70bf..d36b663ddf9 100644
--- a/ace/OS.h
+++ b/ace/OS.h
@@ -22,6 +22,11 @@
// configuration file (e.g., config-sunos5-sunc++-4.x.h).
#include "ace/config.h"
+#if defined (ACE_HAS_4_4BSD_SENDMSG_RECVMSG)
+// control message size to pass a file descriptor
+#define ACE_BSD_CONTROL_MSG_LEN sizeof (struct cmsghdr) + sizeof (ACE_HANDLE)
+#endif /* ACE_HAS_4_4BSD_SENDMSG_RECVMSG */
+
// Define the default constants for ACE. Many of these are used for
// the ACE tests and applications. You may want to change some of
// these to correspond to your environment.
diff --git a/ace/OS.i b/ace/OS.i
index ff62980a05d..e18b143e6cf 100644
--- a/ace/OS.i
+++ b/ace/OS.i
@@ -28,6 +28,12 @@ typedef size_t ACE_SOCKET_LEN;
typedef int ACE_SOCKET_LEN;
#endif /* ACE_HAS_SIZET_SOCKET_LEN */
+#if defined (ACE_LACKS_CONST_STRBUF_PTR)
+typedef struct strbuf *ACE_STRBUF_TYPE;
+#else
+typedef const struct strbuf *ACE_STRBUF_TYPE;
+#endif /* ACE_LACKS_CONST_STRBUF_PTR */
+
#if defined (ACE_HAS_VOIDPTR_SOCKOPT)
typedef void *ACE_SOCKOPT_TYPE1;
#elif defined (ACE_HAS_CHARPTR_SOCKOPT)
@@ -2692,7 +2698,7 @@ ACE_OS::select (int width,
(ACE_FD_SET_TYPE *) rfds,
(ACE_FD_SET_TYPE *) wfds,
(ACE_FD_SET_TYPE *) efds,
- (timeval *) timeout) , int, -1);
+ timeout == 0 ? 0 : (timeval *) *timeout) , int, -1);
}
ACE_INLINE int
@@ -5428,7 +5434,10 @@ ACE_OS::putmsg (ACE_HANDLE handle, const struct strbuf *ctl,
{
// ACE_TRACE ("ACE_OS::putmsg");
#if defined (ACE_HAS_STREAM_PIPES)
- ACE_OSCALL_RETURN (::putmsg (handle, ctl, data, flags), int, -1);
+ ACE_OSCALL_RETURN (::putmsg (handle,
+ (ACE_STRBUF_TYPE) ctl,
+ (ACE_STRBUF_TYPE) data,
+ flags), int, -1);
#else
ACE_UNUSED_ARG (flags);
if (ctl == 0 && data == 0)
@@ -5456,12 +5465,18 @@ ACE_OS::putmsg (ACE_HANDLE handle, const struct strbuf *ctl,
}
ACE_INLINE int
-ACE_OS::putpmsg (ACE_HANDLE handle, const struct strbuf *ctl,
- const struct strbuf *data, int band, int flags)
+ACE_OS::putpmsg (ACE_HANDLE handle,
+ const struct strbuf *ctl,
+ const struct strbuf *data,
+ int band,
+ int flags)
{
// ACE_TRACE ("ACE_OS::putpmsg");
#if defined (ACE_HAS_STREAM_PIPES)
- ACE_OSCALL_RETURN (::putpmsg (handle, ctl, data, band, flags), int, -1);
+ ACE_OSCALL_RETURN (::putpmsg (handle,
+ (ACE_STRBUF_TYPE) ctl,
+ (ACE_STRBUF_TYPE) data,
+ band, flags), int, -1);
#else
ACE_UNUSED_ARG (flags);
ACE_UNUSED_ARG (band);
diff --git a/ace/README b/ace/README
index 7bd219bd34e..878cf514643 100644
--- a/ace/README
+++ b/ace/README
@@ -155,6 +155,7 @@ ACE_HAS_WINSOCK2 The Win32 platform supports WinSock 2.0
ACE_HAS_XLI Platform has the XLI version of TLI
ACE_HAS_XT Platform has Xt and Motif
ACE_HAS_YIELD_VOID_PTR Platform requires pthread_yield() to take a NULL.
+ACE_LACKS_CONST_STRBUF_PTR Platform uses struct strbuf * rather than const struct strbuf * (e.g., HP/UX 10.x)
ACE_LACKS_CONST_TIMESPEC_PTR Platform forgot const in cond_timewait (e.g., HP/UX).
ACE_LACKS_COND_T Platform lacks condition variables (e.g., Win32 and VxWorks)
ACE_LACKS_CONDATTR_PSHARED Platform has no implementation of pthread_condattr_setpshared(), even though it supports pthreads!
diff --git a/ace/SOCK_Dgram.cpp b/ace/SOCK_Dgram.cpp
index 97d370d935f..e9728166838 100644
--- a/ace/SOCK_Dgram.cpp
+++ b/ace/SOCK_Dgram.cpp
@@ -131,8 +131,16 @@ ACE_SOCK_Dgram::send (const iovec iov[],
send_msg.msg_name = (char *) addr.get_addr ();
#endif /* ACE_HAS_SOCKADDR_MSG_NAME */
send_msg.msg_namelen = addr.get_size ();
- send_msg.msg_accrights = 0;
+
+#if defined (ACE_HAS_4_4BSD_SENDMSG_RECVMSG)
+ send_msg.msg_control = 0;
+ send_msg.msg_controllen = 0;
+ send_msg.msg_flags = 0;
+#else
+ send_msg.msg_accrights = 0;
send_msg.msg_accrightslen = 0;
+#endif /* ACE_HAS_4_4BSD_SENDMSG_RECVMSG */
+
return ACE_OS::sendmsg (this->get_handle (), &send_msg, flags);
}
@@ -156,8 +164,14 @@ ACE_SOCK_Dgram::recv (iovec iov[],
recv_msg.msg_name = (char *) addr.get_addr ();
#endif /* ACE_HAS_SOCKADDR_MSG_NAME */
recv_msg.msg_namelen = addr.get_size ();
+
+#if defined (ACE_HAS_4_4BSD_SENDMSG_RECVMSG)
+ recv_msg.msg_control = 0 ;
+ recv_msg.msg_controllen = 0 ;
+#else
recv_msg.msg_accrights = 0;
recv_msg.msg_accrightslen = 0;
+#endif /* ACE_HAS_4_4BSD_SENDMSG_RECVMSG */
ssize_t status = ACE_OS::recvmsg (this->get_handle (),
&recv_msg, flags);
diff --git a/ace/Shared_Memory_MM.h b/ace/Shared_Memory_MM.h
index 5b1b96bffd0..daa54737036 100644
--- a/ace/Shared_Memory_MM.h
+++ b/ace/Shared_Memory_MM.h
@@ -28,12 +28,16 @@ class ACE_Export ACE_Shared_Memory_MM : public ACE_Shared_Memory
public:
// = Initialization and termination methods.
ACE_Shared_Memory_MM (void);
+ // Default constructor.
+
ACE_Shared_Memory_MM (ACE_HANDLE handle,
int length = -1,
int prot = PROT_RDWR,
int share = MAP_PRIVATE,
char *addr = 0,
off_t pos = 0);
+ // Constructor.
+
ACE_Shared_Memory_MM (LPTSTR file_name,
int len = -1,
int flags = O_RDWR | O_CREAT,
@@ -41,6 +45,7 @@ public:
int prot = PROT_RDWR,
int share = MAP_SHARED,
char *addr = 0, off_t pos = 0);
+ // Constructor.
int open (ACE_HANDLE handle,
int length = -1,
@@ -48,6 +53,7 @@ public:
int share = MAP_PRIVATE,
char *addr = 0,
off_t pos = 0);
+ // Open method.
int open (LPTSTR file_name,
int len = -1,
@@ -57,6 +63,10 @@ public:
int share = MAP_SHARED,
char *addr = 0,
off_t pos = 0);
+ // Open method.
+
+ const TCHAR *filename (void) const;
+ // Return the name of file that is mapped (if any).
virtual int close (void);
// Close down the shared memory segment.
@@ -69,7 +79,8 @@ public:
// Create a new chuck of memory containing <size> bytes.
virtual int free (void *p);
- // Free a chuck of memory allocated by <ACE_Shared_Memory_MM::malloc>.
+ // Free a chuck of memory allocated by
+ // <ACE_Shared_Memory_MM::malloc>.
virtual int get_segment_size (void) const;
// Return the size of the shared memory segment.
diff --git a/ace/Shared_Memory_MM.i b/ace/Shared_Memory_MM.i
index d654f129a59..ab00abbb61c 100644
--- a/ace/Shared_Memory_MM.i
+++ b/ace/Shared_Memory_MM.i
@@ -3,6 +3,14 @@
// Shared_Memory_MM.i
+// Return the name of file that is mapped (if any).
+
+ACE_INLINE const TCHAR *
+ACE_Shared_Memory_MM::filename (void) const;
+{
+ return this->shared_memory_.filename ();
+}
+
ACE_INLINE int
ACE_Shared_Memory_MM::open (ACE_HANDLE handle,
int length,
diff --git a/ace/Signal.h b/ace/Signal.h
index f95703de081..77d458cfcd6 100644
--- a/ace/Signal.h
+++ b/ace/Signal.h
@@ -271,7 +271,7 @@ private:
// This is a normal C function.
};
-#if !defined (HPUX)
+#if !defined (ACE_HAS_BROKEN_HPUX_TEMPLATES)
class ACE_Export ACE_Sig_Handlers : public ACE_Sig_Handler
// = TITLE
// This is an alternative signal handling dispatcher for ACE. It
@@ -339,7 +339,7 @@ private:
// If this is > 0 then a 3rd party library has registered a
// handler...
};
-#endif /* HPUX */
+#endif /* ACE_HAS_BROKEN_HPUX_TEMPLATES */
#if defined (__ACE_INLINE__)
#include "ace/Signal.i"
diff --git a/ace/Task_T.cpp b/ace/Task_T.cpp
index dbeee24fbed..33c9584c142 100644
--- a/ace/Task_T.cpp
+++ b/ace/Task_T.cpp
@@ -6,7 +6,7 @@
#define ACE_BUILD_DLL
#include "ace/Task_T.h"
-#if !defined (HPUX) || defined (__GNUG_) || defined (ACE_HAS_BROKEN_HPUX_TEMPLATES)
+#if !defined (HPUX) || defined (__GNUG__) || defined (ACE_HAS_BROKEN_HPUX_TEMPLATES)
#include "ace/Module.h"
#endif /* !defined (HPUX) || defined (__GNUG__) || defined (ACE_HAS_BROKEN_HPUX_TEMPLATES) */
#include "ace/Service_Config.h"
diff --git a/ace/config-hpux-10.x-aCC.h b/ace/config-hpux-10.x-aCC.h
index de121fa323c..a87926e5f33 100644
--- a/ace/config-hpux-10.x-aCC.h
+++ b/ace/config-hpux-10.x-aCC.h
@@ -23,6 +23,9 @@
#define ACE_HAS_BROKEN_CONVERSIONS
+// They forgot a const in the prototype of putmsg and putpmsg...
+#define ACE_LACKS_CONST_STRBUF_PTR
+
// They forgot a const in the prototype of const_timewait...
#define ACE_LACKS_CONST_TIMESPEC_PTR
@@ -83,6 +86,19 @@
// Compiler/platform has thread-specific storage
// #define ACE_HAS_THREAD_SPECIFIC_STORAGE
+// Platform supports getpagesize() call.
+#define ACE_HAS_GETPAGESIZE
+
+// Platform supports reentrant functions (i.e., all the POSIX *_r
+// functions).
+#define ACE_HAS_REENTRANT_FUNCTIONS
+
+// Platform supports the tid_t type (e.g., AIX and Irix 6.2)
+#define ACE_HAS_TID_T
+
+// Platform supports IP multicast
+#define ACE_HAS_IP_MULTICAST
+
// Platform supports POSIX 1.b clock_gettime ()
#define ACE_HAS_CLOCK_GETTIME
diff --git a/ace/config-hpux-10.x-g++.h b/ace/config-hpux-10.x-g++.h
index c3bf2b57fdf..5eef7dc7869 100644
--- a/ace/config-hpux-10.x-g++.h
+++ b/ace/config-hpux-10.x-g++.h
@@ -15,6 +15,9 @@
#define ACE_HAS_BROKEN_CONVERSIONS
#define ACE_HAS_STREAMS
+// They forgot a const in the prototype of putmsg and putpmsg...
+#define ACE_LACKS_CONST_STRBUF_PTR
+
// They forgot a const in the prototype of const_timewait...
#define ACE_LACKS_CONST_TIMESPEC_PTR
@@ -27,10 +30,24 @@
#define ACE_TEMPLATES_REQUIRE_SPECIALIZATION
#define ACE_LACKS_SYSCALL
-#define ACE_LACKS_STRRECVFD
#define ACE_HAS_POSIX_TIME
#define ACE_HAS_CLOCK_GETTIME
+// Compiler/platform supports struct strbuf.
+#define ACE_HAS_STRBUF_T
+#define ACE_HAS_STREAM_PIPES
+#define ACE_HAS_STREAMS
+
+// Platform supports getpagesize() call.
+#define ACE_HAS_GETPAGESIZE
+
+// Platform supports reentrant functions (i.e., all the POSIX *_r
+// functions).
+#define ACE_HAS_REENTRANT_FUNCTIONS
+
+// Platform supports the tid_t type (e.g., AIX and Irix 6.2)
+#define ACE_HAS_TID_T
+
// Platform supports System V IPC (most versions of UNIX, but not Win32)
#define ACE_HAS_SYSV_IPC
#define ACE_HAS_IP_MULTICAST