Jean-frederic Clere wrote:
Jim Jagielski wrote:
There's a bug report (37788) regarding allowing AprEndpoint
to use APR IPv6 addresses. Their patch is almost right, but
instead the value should be to use APR_UNSPEC instead
of APR_INET6 (or the current APR_INET) to allow APR
to correctly determine IP version and do a graceful
recovery... As well as handle cases where APR wasn't
built with IPv6 support.
I'd like to commit that change... comments?
-1: It also cores on my machine.
+++
#
# An unexpected error has been detected by HotSpot Virtual Machine:
#
# SIGSEGV (0xb) at pc=0xa808eb5e, pid=10005, tid=3084708160
#
# Java VM: Java HotSpot(TM) Client VM (1.5.0_06-b05 mixed mode)
# Problematic frame:
# C [libapr-1.so.0+0x19b5e] apr_socket_bind+0x2e
#
+++
APR_INET6 works OK with the same configuration.
With the following patch:
+++
Index: src/network.c
===================================================================
--- src/network.c (revision 373299)
+++ src/network.c (working copy)
@@ -280,7 +280,7 @@
GET_S_FAMILY(f, family);
GET_S_TYPE(t, type);
- if (family > 0) {
+ if (family >= 0) {
TCN_THROW_IF_ERR(apr_socket_create(&s,
f, t, protocol, p), a);
}
@@ -290,7 +290,7 @@
a = (tcn_socket_t *)apr_pcalloc(p, sizeof(tcn_socket_t));
a->sock = s;
a->pool = p;
- if (family > 0)
+ if (family >= 0)
a->net = &apr_socket_layer;
a->opaque = s;
apr_pool_cleanup_register(p, (const void *)a,
+++
It works.
Comments?
Cheers
Jean-Frederic
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]