Changes to attempt to silence bcc64x
[ACE_TAO.git] / ACE / ace / LSOCK_CODgram.cpp
blob51f51b31b903a9956085beb6e6775b8992e48e4e
1 #include "ace/LSOCK_CODgram.h"
2 #if !defined (ACE_LACKS_UNIX_DOMAIN_SOCKETS)
4 #include "ace/Log_Category.h"
5 #if defined (ACE_HAS_ALLOC_HOOKS)
6 # include "ace/Malloc_Base.h"
7 #endif /* ACE_HAS_ALLOC_HOOKS */
9 #if !defined (__ACE_INLINE__)
10 #include "ace/LSOCK_CODgram.inl"
11 #endif /* __ACE_INLINE__ */
13 ACE_BEGIN_VERSIONED_NAMESPACE_DECL
15 ACE_ALLOC_HOOK_DEFINE(ACE_LSOCK_CODgram)
17 void
18 ACE_LSOCK_CODgram::dump () const
20 #if defined (ACE_HAS_DUMP)
21 ACE_TRACE ("ACE_LSOCK_CODgram::dump");
23 ACELIB_DEBUG ((LM_DEBUG, ACE_BEGIN_DUMP, this));
24 ACE_SOCK_CODgram::dump ();
25 ACE_LSOCK::dump ();
26 ACELIB_DEBUG ((LM_DEBUG, ACE_END_DUMP));
27 #endif /* ACE_HAS_DUMP */
30 /* Here's the general-purpose open routine. */
32 int
33 ACE_LSOCK_CODgram::open (const ACE_Addr &remote,
34 const ACE_Addr &local,
35 int protocol_family,
36 int protocol)
38 ACE_TRACE ("ACE_LSOCK_CODgram::open");
39 if (ACE_SOCK_CODgram::open (remote, local, protocol_family,
40 protocol) == -1)
41 return -1;
42 ACE_LSOCK::set_handle (this->get_handle ());
43 return 0;
46 /* Create a local ACE_SOCK datagram. */
48 ACE_LSOCK_CODgram::ACE_LSOCK_CODgram (const ACE_Addr &remote,
49 const ACE_Addr &local,
50 int protocol_family,
51 int protocol)
53 ACE_TRACE ("ACE_LSOCK_CODgram::ACE_LSOCK_CODgram");
54 if (this->open (remote, local, protocol_family,
55 protocol) == -1)
56 ACELIB_ERROR ((LM_ERROR, ACE_TEXT ("%p\n"), ACE_TEXT ("ACE_LSOCK_CODgram")));
59 ACE_END_VERSIONED_NAMESPACE_DECL
61 #endif /* ACE_LACKS_UNIX_DOMAIN_SOCKETS */