ASF Bugzilla – Attachment 32543 Details for
Bug 57653
APR/native crash during HTTP upgrade
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Safety patch for tcnative 1.1.x branch
57653.patch (text/plain), 1.23 KB, created by
Christopher Schultz
on 2015-03-03 21:24:25 UTC
(
hide
)
Description:
Safety patch for tcnative 1.1.x branch
Filename:
MIME Type:
Creator:
Christopher Schultz
Created:
2015-03-03 21:24:25 UTC
Size:
1.23 KB
patch
obsolete
>Index: native/src/poll.c >=================================================================== >--- native/src/poll.c (revision 1662089) >+++ native/src/poll.c (working copy) >@@ -294,6 +294,11 @@ > UNREFERENCED(o); > TCN_ASSERT(pollset != 0); > >+ // xxx >+ if(!p) { >+ tcn_ThrowAPRException(e, APR_ENOPOLL); >+ return -(jint)APR_ENOPOLL; >+ } > #ifdef TCN_DO_STATISTICS > p->sp_poll++; > #endif >@@ -307,6 +312,10 @@ > { > apr_interval_time_t socket_timeout = 0; > tcn_socket_t *s = (tcn_socket_t *)ep->fd.client_data; >+ if(!s) { >+ tcn_ThrowAPRException(e, APR_EINVALSOCK); >+ return -(jint)APR_EINVALSOCK; >+ } > if (s->timeout == TCN_NO_SOCKET_TIMEOUT) { > socket_timeout = p->default_timeout; > } >@@ -358,6 +367,10 @@ > now = apr_time_now(); > for (i = 0; i < num; i++) { > tcn_socket_t *s = (tcn_socket_t *)fd->client_data; >+ if(!s) { >+ tcn_ThrowAPRException(e, APR_EINVALSOCK); >+ return -(jint)APR_EINVALSOCK; >+ } > p->set[i*2+0] = (jlong)(fd->rtnevents); > p->set[i*2+1] = P2J(s); > if (remove) { >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 57653
:
32539
| 32543