diff options
author | levine <levine@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 1998-08-14 02:32:59 +0000 |
---|---|---|
committer | levine <levine@ae88bc3d-4319-0410-8dbf-d08b4c9d3795> | 1998-08-14 02:32:59 +0000 |
commit | 8127933c002d3fab445ef2b164afbcc0e017fbff (patch) | |
tree | 071326e534b00b4025d7692c5c25489d7fc6507b /tests/Conn_Test.cpp | |
parent | 7421c5bd335dffd2a5b66b3ca36e9eabe485d19b (diff) | |
download | ATCD-8127933c002d3fab445ef2b164afbcc0e017fbff.tar.gz |
disabled ACE_Hash_Addr template specialization on non-egcs g++
Diffstat (limited to 'tests/Conn_Test.cpp')
-rw-r--r-- | tests/Conn_Test.cpp | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/tests/Conn_Test.cpp b/tests/Conn_Test.cpp index fb3617adcf5..26a590f43fb 100644 --- a/tests/Conn_Test.cpp +++ b/tests/Conn_Test.cpp @@ -160,13 +160,17 @@ Svc_Handler::idle (u_long flags) // **************************************** -// Template specializations! +// Template specializations. Older versions of g++, such as 2.7.2.3, +// can't deal with them, though. +#if defined (ACE_HAS_TEMPLATE_SPECIALIZATION) && \ + (!defined (__GNUG__) || (__GNUC__ > 2 || __GNUC_MINOR__ >= 90)) size_t ACE_Hash_Addr<ACE_INET_Addr>::hash_i (const ACE_INET_Addr &addr) const { return addr.get_ip_address () + addr.get_port_number (); } +#endif /* ACE_HAS_TEMPLATE_SPECIALIZATION && egcs, if __GNUG__ */ // **************************************** @@ -412,7 +416,7 @@ server (void *arg) for (;;) { // Create a new <Svc_Handler> to consume the data. - + #if defined (ACE_LACKS_FORK) int result = acceptor->accept (svc_handler, &cli_addr, @@ -422,7 +426,7 @@ server (void *arg) &cli_addr); ACE_UNUSED_ARG (options); #endif /* ! ACE_LACKS_FORK */ - + // Timing out is the only way for threads to stop accepting, // since we don't have signals @@ -439,7 +443,7 @@ server (void *arg) svc_handler->recv_data (); } - + ACE_NOTREACHED(return 0); } |