summaryrefslogtreecommitdiff
path: root/ace/SV_Shared_Memory.inl
diff options
context:
space:
mode:
Diffstat (limited to 'ace/SV_Shared_Memory.inl')
-rw-r--r--ace/SV_Shared_Memory.inl39
1 files changed, 21 insertions, 18 deletions
diff --git a/ace/SV_Shared_Memory.inl b/ace/SV_Shared_Memory.inl
index f01f5b2c969..3aaa41414e0 100644
--- a/ace/SV_Shared_Memory.inl
+++ b/ace/SV_Shared_Memory.inl
@@ -1,12 +1,13 @@
-/* -*- C++ -*- */
+// -*- C++ -*-
+//
// $Id$
-// SV_Shared_Memory.i
-
#include "ace/OS_NS_sys_shm.h"
#include "ace/Global_Macros.h"
#include "ace/OS_NS_errno.h"
+ACE_BEGIN_VERSIONED_NAMESPACE_DECL
+
ACE_INLINE size_t
ACE_SV_Shared_Memory::round_up (size_t len)
{
@@ -17,15 +18,15 @@ ACE_SV_Shared_Memory::round_up (size_t len)
// Creates a shared memory segment of SIZE bytes. Does *not* attach
// this memory segment...
-ACE_INLINE int
+ACE_INLINE int
ACE_SV_Shared_Memory::open (key_t external_id, size_t sz, int create, int perms)
{
ACE_TRACE ("ACE_SV_Shared_Memory::open");
#if defined (ACE_WIN32)
- ACE_UNUSED_ARG(perms);
- ACE_UNUSED_ARG(create);
- ACE_UNUSED_ARG(sz);
- ACE_UNUSED_ARG(external_id);
+ ACE_UNUSED_ARG(perms);
+ ACE_UNUSED_ARG(create);
+ ACE_UNUSED_ARG(sz);
+ ACE_UNUSED_ARG(external_id);
ACE_NOTSUP_RETURN (-1);
#else
this->segment_ptr_ = 0;
@@ -37,15 +38,15 @@ ACE_SV_Shared_Memory::open (key_t external_id, size_t sz, int create, int perms)
#endif /* ACE_WIN32 */
}
-// Attachs to the shared memory segment.
+// Attachs to the shared memory segment.
ACE_INLINE int
ACE_SV_Shared_Memory::attach (void *virtual_addr, int flags)
{
ACE_TRACE ("ACE_SV_Shared_Memory::attach");
#if defined (ACE_WIN32)
- ACE_UNUSED_ARG(flags);
- ACE_UNUSED_ARG(virtual_addr);
+ ACE_UNUSED_ARG(flags);
+ ACE_UNUSED_ARG(virtual_addr);
ACE_NOTSUP_RETURN (-1);
#else
this->segment_ptr_ = ACE_OS::shmat (this->internal_id_, virtual_addr, flags);
@@ -53,23 +54,23 @@ ACE_SV_Shared_Memory::attach (void *virtual_addr, int flags)
#endif /* ACE_WIN32 */
}
-// Interface to the underlying shared memory control function.
+// Interface to the underlying shared memory control function.
ACE_INLINE int
ACE_SV_Shared_Memory::control (int cmd, void *buf)
{
ACE_TRACE ("ACE_SV_Shared_Memory::control");
#if defined (ACE_WIN32)
- ACE_UNUSED_ARG(cmd);
- ACE_UNUSED_ARG(buf);
-
- ACE_NOTSUP_RETURN (-1);
+ ACE_UNUSED_ARG(cmd);
+ ACE_UNUSED_ARG(buf);
+
+ ACE_NOTSUP_RETURN (-1);
#else
return ACE_OS::shmctl (this->internal_id_, cmd, (struct shmid_ds *) buf);
#endif /* ACE_WIN32 */
}
-// The overall size of the segment.
+// The overall size of the segment.
ACE_INLINE size_t
ACE_SV_Shared_Memory::get_segment_size (void) const
@@ -78,7 +79,7 @@ ACE_SV_Shared_Memory::get_segment_size (void) const
return this->size_;
}
-// Removes the shared memory segment.
+// Removes the shared memory segment.
ACE_INLINE int
ACE_SV_Shared_Memory::remove (void)
@@ -114,3 +115,5 @@ ACE_SV_Shared_Memory::get_id (void) const
ACE_TRACE ("ACE_SV_Shared_Memory::get_id");
return this->internal_id_;
}
+
+ACE_END_VERSIONED_NAMESPACE_DECL