diff options
author | schmidt <douglascraigschmidt@users.noreply.github.com> | 2006-08-21 16:45:49 +0000 |
---|---|---|
committer | schmidt <douglascraigschmidt@users.noreply.github.com> | 2006-08-21 16:45:49 +0000 |
commit | 70635781379ec665cf150979d92f15dbfa55de0c (patch) | |
tree | 73762f8d07e4dcea006cd014826a56bb8aeb852d /ACE/ace/INET_Addr.h | |
parent | b5e188c33ce475d8d7fd5f86f71f82bbba44081f (diff) | |
download | ATCD-70635781379ec665cf150979d92f15dbfa55de0c.tar.gz |
ChangeLogTag:Mon
Diffstat (limited to 'ACE/ace/INET_Addr.h')
-rw-r--r-- | ACE/ace/INET_Addr.h | 26 |
1 files changed, 21 insertions, 5 deletions
diff --git a/ACE/ace/INET_Addr.h b/ACE/ace/INET_Addr.h index fd7f5159627..fe5522d6fbb 100644 --- a/ACE/ace/INET_Addr.h +++ b/ACE/ace/INET_Addr.h @@ -279,15 +279,31 @@ public: #endif /* ACE_HAS_WCHAR */ /** - * Return the character representation of the hostname (this version - * is non-reentrant since it returns a pointer to a static data - * area). + * Return the character representation of the hostname. This + * version is non-reentrant since it returns a pointer to a static + * data area. You should therefore either (1) do a "deep copy" of + * the address returned by get_host_name(), e.g., using strdup() or + * (2) use the "reentrant" version of get_host_name() described + * above. */ const char *get_host_name (void) const; - /// Return the "dotted decimal" Internet address. + /** + * Return the "dotted decimal" Internet address representation of + * the hostname storing it in the <addr> (which is assumed to be + * <addr_size> bytes long). This version is reentrant. + */ + const char *get_host_addr (char *addr, int addr_size) const; + + /** + * Return the "dotted decimal" Internet address representation of + * the hostname. This version is non-reentrant since it returns a + * pointer to a static data area. You should therefore either + * (1) do a "deep copy" of the address returned by get_host_addr(), e.g., + * using strdup() or (2) use the "reentrant" version of + * get_host_addr() described above. + */ const char *get_host_addr (void) const; - const char *get_host_addr (char *dst, int size) const; /// Return the 4-byte IP address, converting it into host byte /// order. |