}
/* create a new socket */
- if ((rv = apr_socket_create(&sock, APR_INET, SOCK_STREAM, r->pool)) != APR_SUCCESS) {
+ if ((rv = apr_socket_create(&sock, APR_INET, SOCK_STREAM,APR_INHERIT, r->pool)) != APR_SUCCESS) {
ap_log_rerror(APLOG_MARK, APLOG_ERR, rv, r,
"proxy: error creating socket");
return HTTP_INTERNAL_SERVER_ERROR;
}
- if ((rv = apr_socket_create(&sock, APR_INET, SOCK_STREAM, r->pool)) != APR_SUCCESS) {
+ if ((rv = apr_socket_create(&sock, APR_INET, SOCK_STREAM, APR_INHERIT, r->pool)) != APR_SUCCESS) {
ap_log_rerror(APLOG_MARK, APLOG_ERR, rv, r,
"proxy: FTP: error creating socket");
return HTTP_INTERNAL_SERVER_ERROR;
"proxy: FTP: EPSV contacting remote host on port %d",
remote_port);
- if ((rv = apr_socket_create(&remote_sock, APR_INET, SOCK_STREAM, r->pool)) != APR_SUCCESS) {
+ if ((rv = apr_socket_create(&remote_sock, APR_INET, SOCK_STREAM, APR_INHERIT, r->pool)) != APR_SUCCESS) {
ap_log_rerror(APLOG_MARK, APLOG_ERR, rv, r,
"proxy: FTP: error creating EPSV socket");
return HTTP_INTERNAL_SERVER_ERROR;
"proxy: FTP: PASV contacting host %d.%d.%d.%d:%d",
h3, h2, h1, h0, pasvport);
- if ((rv = apr_socket_create(&remote_sock, APR_INET, SOCK_STREAM, r->pool)) != APR_SUCCESS) {
+ if ((rv = apr_socket_create(&remote_sock, APR_INET, SOCK_STREAM, APR_INHERIT, r->pool)) != APR_SUCCESS) {
ap_log_rerror(APLOG_MARK, APLOG_ERR, rv, r,
"proxy: error creating PASV socket");
return HTTP_INTERNAL_SERVER_ERROR;
apr_port_t local_port;
unsigned int h0, h1, h2, h3, p0, p1;
- if ((rv = apr_socket_create(&local_sock, APR_INET, SOCK_STREAM, r->pool)) != APR_SUCCESS) {
+ if ((rv = apr_socket_create(&local_sock, APR_INET, SOCK_STREAM, APR_INHERIT, r->pool)) != APR_SUCCESS) {
ap_log_rerror(APLOG_MARK, APLOG_ERR, rv, r,
"proxy: FTP: error creating local socket");
return HTTP_INTERNAL_SERVER_ERROR;
backend->connection = NULL;
/* see memory note above */
- if ((rv = apr_socket_create(&sock, APR_INET, SOCK_STREAM, c->pool)) != APR_SUCCESS) {
+ if ((rv = apr_socket_create(&sock, APR_INET, SOCK_STREAM, APR_INHERIT, c->pool)) != APR_SUCCESS) {
ap_log_error(APLOG_MARK, APLOG_ERR, rv, r->server,
"proxy: error creating socket");
return HTTP_INTERNAL_SERVER_ERROR;
close += ap_proxy_liststr(apr_table_get(r->headers_in, "Connection"), "close");
ap_proxy_clear_connection(p, r->headers_in);
if (close) {
- apr_table_mergen(r->headers_in, "Connection", "close");
+ apr_table_setn(r->headers_in, "Connection", "close");
origin->keepalive = 0;
}