stas 2004/05/06 20:46:27
Modified: t/filter/TestFilter both_str_con_add.pm t/protocol/TestProtocol echo_filter.pm echo_timeout.pm Log: workaround to a problem on some platforms (solaris, bsd, etc), where Apache 2.0.49+ forgets to set the blocking mode on the socket
Joe, I've committed a workaround for the non-blocking socket issue so people won't send complaints. But the bug in Apache didn't go away, so we still need that to get fixed. Thanks. To expose it back, just unroll this change.
Revision Changes Path
1.11 +7 -0 modperl-2.0/t/filter/TestFilter/both_str_con_add.pm
Index: both_str_con_add.pm
===================================================================
RCS file: /home/cvs/modperl-2.0/t/filter/TestFilter/both_str_con_add.pm,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -u -r1.10 -r1.11
--- both_str_con_add.pm 4 May 2004 06:19:11 -0000 1.10
+++ both_str_con_add.pm 7 May 2004 03:46:27 -0000 1.11
@@ -53,6 +53,13 @@
sub handler {
my Apache::Connection $c = shift;
+ # XXX: workaround to a problem on some platforms (solaris, bsd,
+ # etc), where Apache 2.0.49+ forgets to set the blocking mode on
+ # the socket
+ require APR::Socket;
+ BEGIN { use APR::Const -compile => qw(SO_NONBLOCK); }
+ $c->client_socket->opt_set(APR::SO_NONBLOCK => 0);
+
my $bb = APR::Brigade->new($c->pool, $c->bucket_alloc);
for (;;) {
1.10 +7 -0 modperl-2.0/t/protocol/TestProtocol/echo_filter.pm
Index: echo_filter.pm
===================================================================
RCS file: /home/cvs/modperl-2.0/t/protocol/TestProtocol/echo_filter.pm,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -u -r1.9 -r1.10
--- echo_filter.pm 4 May 2004 06:14:44 -0000 1.9
+++ echo_filter.pm 7 May 2004 03:46:27 -0000 1.10
@@ -16,6 +16,13 @@
sub handler {
my Apache::Connection $c = shift;
+ # XXX: workaround to a problem on some platforms (solaris, bsd,
+ # etc), where Apache 2.0.49+ forgets to set the blocking mode on
+ # the socket
+ require APR::Socket;
+ BEGIN { use APR::Const -compile => qw(SO_NONBLOCK); }
+ $c->client_socket->opt_set(APR::SO_NONBLOCK => 0);
+
my $bb = APR::Brigade->new($c->pool, $c->bucket_alloc);
for (;;) {
1.3 +6 -0 modperl-2.0/t/protocol/TestProtocol/echo_timeout.pm
Index: echo_timeout.pm
===================================================================
RCS file: /home/cvs/modperl-2.0/t/protocol/TestProtocol/echo_timeout.pm,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -u -r1.2 -r1.3
--- echo_timeout.pm 4 May 2004 06:14:44 -0000 1.2
+++ echo_timeout.pm 7 May 2004 03:46:27 -0000 1.3
@@ -20,6 +20,12 @@
my Apache::Connection $c = shift;
my APR::Socket $socket = $c->client_socket;
+ # XXX: workaround to a problem on some platforms (solaris, bsd,
+ # etc), where Apache 2.0.49+ forgets to set the blocking mode on
+ # the socket
+ BEGIN { use APR::Const -compile => qw(SO_NONBLOCK) }
+ $c->client_socket->opt_set(APR::SO_NONBLOCK => 0);
+
# set timeout (20 sec) so later we can do error checking on
# read/write timeouts
$socket->timeout_set(20_000_000);
-- __________________________________________________________________ Stas Bekman JAm_pH ------> Just Another mod_perl Hacker http://stason.org/ mod_perl Guide ---> http://perl.apache.org mailto:[EMAIL PROTECTED] http://use.perl.org http://apacheweek.com http://modperlbook.org http://apache.org http://ticketmaster.com
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
