stas2004/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
Revision ChangesPath
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 - 1.10
+++ both_str_con_add.pm 7 May 2004 03:46:27 - 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.pm4 May 2004 06:14:44 - 1.9
+++ echo_filter.pm7 May 2004 03:46:27 - 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 - 1.2
+++ echo_timeout.pm 7 May 2004 03:46:27 - 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);