You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@perl.apache.org by Steve Hay <st...@uk.radan.com> on 2004/08/13 18:55:29 UTC

Win32 fails filter\out_bbs_filebucket

Using current CVS with 2.0.49 / 5.8.4:

C:\Temp\modperl-2.0>perl t/TEST -verbose t\filter\out_bbs_filebucket.t
[...]
t\filter\out_bbs_filebucket....1..10
# Running under perl version 5.008004 for MSWin32
# Current time local: Fri Aug 13 17:48:58 2004
# Current time GMT:   Fri Aug 13 16:48:58 2004
# Using Test.pm version 1.24
# Using Apache/Test.pm version 1.13
# Failed test 1 in t\filter\out_bbs_filebucket.t at line 25
# testing : length
# expected: 1024
# received: 674
not ok 1
# Failed test 2 in t\filter\out_bbs_filebucket.t at line 26
not ok 2
# Failed test 3 in t\filter\out_bbs_filebucket.t at line 25 fail #2
# Failed test 4 in t\filter\out_bbs_filebucket.t at line 26 fail #2
# testing : length
# expected: 102400
# received: 674
not ok 3
not ok 4
# Failed test 5 in t\filter\out_bbs_filebucket.t at line 25 fail #3
# Failed test 6 in t\filter\out_bbs_filebucket.t at line 26 fail #3
# testing : length
# expected: 512000
# received: 674
not ok 5
not ok 6
# Failed test 7 in t\filter\out_bbs_filebucket.t at line 25 fail #4
# Failed test 8 in t\filter\out_bbs_filebucket.t at line 26 fail #4
# testing : length
# expected: 1024000
# received: 674
not ok 7
not ok 8
# Failed test 9 in t\filter\out_bbs_filebucket.t at line 25 fail #5
# Failed test 10 in t\filter\out_bbs_filebucket.t at line 26 fail #5
# testing : length
# expected: 5120000
# received: 674
not ok 9
not ok 10
FAILED tests 1-10
        Failed 10/10 tests, 0.00% okay
Failed Test                   Stat Wstat Total Fail  Failed  List of Failed
-------------------------------------------------------------------------------
t\filter\out_bbs_filebucket.t               10   10 100.00%  1-10
Failed 1/1 test scripts, 0.00% okay. 10/10 subtests failed, 0.00% okay.

error_log contains:

[Fri Aug 13 17:48:59 2004] [error] [client 127.0.0.1] 
Apache::RequestIO::sendfile: (720002) The system cannot find the file 
specified.   at 
C:\\Temp\\modperl-2.0\\t\\filter/TestFilter/out_bbs_filebucket.pm line 62
[Fri Aug 13 17:48:59 2004] [error] [client 127.0.0.1] 
Apache::RequestIO::sendfile: (720002) The system cannot find the file 
specified.   at 
C:\\Temp\\modperl-2.0\\t\\filter/TestFilter/out_bbs_filebucket.pm line 62
[Fri Aug 13 17:48:59 2004] [error] [client 127.0.0.1] 
Apache::RequestIO::sendfile: (720002) The system cannot find the file 
specified.   at 
C:\\Temp\\modperl-2.0\\t\\filter/TestFilter/out_bbs_filebucket.pm line 62
[Fri Aug 13 17:48:59 2004] [error] [client 127.0.0.1] 
Apache::RequestIO::sendfile: (720002) The system cannot find the file 
specified.   at 
C:\\Temp\\modperl-2.0\\t\\filter/TestFilter/out_bbs_filebucket.pm line 62
[Fri Aug 13 17:48:59 2004] [error] [client 127.0.0.1] 
Apache::RequestIO::sendfile: (720002) The system cannot find the file 
specified.   at 
C:\\Temp\\modperl-2.0\\t\\filter/TestFilter/out_bbs_filebucket.pm line 62




------------------------------------------------
Radan Computational Ltd.

The information contained in this message and any files transmitted with it are confidential and intended for the addressee(s) only.  If you have received this message in error or there are any problems, please notify the sender immediately.  The unauthorized use, disclosure, copying or alteration of this message is strictly forbidden.  Note that any views or opinions presented in this email are solely those of the author and do not necessarily represent those of Radan Computational Ltd.  The recipient(s) of this message should check it and any attached files for viruses: Radan Computational will accept no liability for any damage caused by any virus transmitted by this email.


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Re: Win32 fails filter\out_bbs_filebucket

Posted by Stas Bekman <st...@stason.org>.
Markus Wichitill wrote:
> Stas Bekman wrote:
> 
>> How about this patch?
>>
>> Index: t/filter/TestFilter/out_bbs_filebucket.pm
>> ===================================================================
>> RCS file: 
>> /home/cvs/modperl-2.0/t/filter/TestFilter/out_bbs_filebucket.pm,v
>> retrieving revision 1.3
>> diff -u -r1.3 out_bbs_filebucket.pm
>> --- t/filter/TestFilter/out_bbs_filebucket.pm   15 Aug 2004 07:55:52 
>> -0000     1.3
>> +++ t/filter/TestFilter/out_bbs_filebucket.pm   19 Aug 2004 00:46:56 
>> -0000
>> @@ -37,6 +37,7 @@
>>              my $nb = APR::Bucket->new(uc $data);
>>              $b->insert_before($nb);
>>              $b->remove;
>> +            $b = $nb;
>>          }
>>      }
> 
> 
> No change.

That sounds like a bug in apr then :( $nb should definitely give the right 
pointer.

-- 
__________________________________________________________________
Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/     mod_perl Guide ---> http://perl.apache.org
mailto:stas@stason.org http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://ticketmaster.com

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Re: Win32 fails filter\out_bbs_filebucket

Posted by Markus Wichitill <ma...@gmx.de>.
Stas Bekman wrote:
> How about this patch?
> 
> Index: t/filter/TestFilter/out_bbs_filebucket.pm
> ===================================================================
> RCS file: /home/cvs/modperl-2.0/t/filter/TestFilter/out_bbs_filebucket.pm,v
> retrieving revision 1.3
> diff -u -r1.3 out_bbs_filebucket.pm
> --- t/filter/TestFilter/out_bbs_filebucket.pm   15 Aug 2004 07:55:52 
> -0000     1.3
> +++ t/filter/TestFilter/out_bbs_filebucket.pm   19 Aug 2004 00:46:56 -0000
> @@ -37,6 +37,7 @@
>              my $nb = APR::Bucket->new(uc $data);
>              $b->insert_before($nb);
>              $b->remove;
> +            $b = $nb;
>          }
>      }

No change.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Re: Win32 fails filter\out_bbs_filebucket

Posted by Stas Bekman <st...@stason.org>.
How about this patch?

Index: t/filter/TestFilter/out_bbs_filebucket.pm
===================================================================
RCS file: /home/cvs/modperl-2.0/t/filter/TestFilter/out_bbs_filebucket.pm,v
retrieving revision 1.3
diff -u -r1.3 out_bbs_filebucket.pm
--- t/filter/TestFilter/out_bbs_filebucket.pm   15 Aug 2004 07:55:52 -0000 
     1.3
+++ t/filter/TestFilter/out_bbs_filebucket.pm   19 Aug 2004 00:46:56 -0000
@@ -37,6 +37,7 @@
              my $nb = APR::Bucket->new(uc $data);
              $b->insert_before($nb);
              $b->remove;
+            $b = $nb;
          }
      }


-- 
__________________________________________________________________
Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/     mod_perl Guide ---> http://perl.apache.org
mailto:stas@stason.org http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://ticketmaster.com

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Re: Win32 fails filter\out_bbs_filebucket

Posted by Stas Bekman <st...@stason.org>.
Markus Wichitill wrote:
> Steve Hay wrote:
> 
>> This allows the test to run successfully in isolation for me, but 
>> "nmake test" now hangs when it reaches this test.
>>
>> Even reverting this change I still find that "nmake test" hangs when 
>> it gets to that test.  Must be something else that's changed since 
>> Friday...
> 
> 
> Same here.
> 
> apr_brigade_cleanup(void * 0x06370718) line 45
> brigade_cleanup(void * 0x06370718) line 34
> run_cleanups(cleanup_t * * 0x0636c080) line 1951 + 13 bytes
> apr_pool_destroy(apr_pool_t * 0x0636c070) line 730 + 12 bytes
> apr_pool_clear(apr_pool_t * 0x00a0f258) line 690 + 12 bytes
> mpm_recycle_completion_context(CompContext * 0x009ce040) line 82
> winnt_get_connection(CompContext * 0x009ce040) line 639
> worker_main(long 1) line 694 + 9 bytes
> _threadstartex(void * 0x0028d2a0) line 227 + 13 bytes
> KERNEL32! 7c80b50b()
> 
> This is the infinite loop:
> 
>     /*
>      * Bah! We can't use APR_RING_FOREACH here because this bucket has
>      * gone away when we dig inside it to get the next one.
>      */
>     while (!APR_BRIGADE_EMPTY(b)) {
>         e = APR_BRIGADE_FIRST(b);
>         apr_bucket_delete(e);
>     }

Yeah, thanks, I'll go over these again and see how to fix them. I wish 
they were failing for me.

-- 
__________________________________________________________________
Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/     mod_perl Guide ---> http://perl.apache.org
mailto:stas@stason.org http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://ticketmaster.com

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Re: Win32 fails filter\out_bbs_filebucket

Posted by Markus Wichitill <ma...@gmx.de>.
Steve Hay wrote:
> This allows the test to run successfully in isolation for me, but "nmake 
> test" now hangs when it reaches this test.
> 
> Even reverting this change I still find that "nmake test" hangs when it 
> gets to that test.  Must be something else that's changed since Friday...

Same here.

apr_brigade_cleanup(void * 0x06370718) line 45
brigade_cleanup(void * 0x06370718) line 34
run_cleanups(cleanup_t * * 0x0636c080) line 1951 + 13 bytes
apr_pool_destroy(apr_pool_t * 0x0636c070) line 730 + 12 bytes
apr_pool_clear(apr_pool_t * 0x00a0f258) line 690 + 12 bytes
mpm_recycle_completion_context(CompContext * 0x009ce040) line 82
winnt_get_connection(CompContext * 0x009ce040) line 639
worker_main(long 1) line 694 + 9 bytes
_threadstartex(void * 0x0028d2a0) line 227 + 13 bytes
KERNEL32! 7c80b50b()

This is the infinite loop:

     /*
      * Bah! We can't use APR_RING_FOREACH here because this bucket has
      * gone away when we dig inside it to get the next one.
      */
     while (!APR_BRIGADE_EMPTY(b)) {
         e = APR_BRIGADE_FIRST(b);
         apr_bucket_delete(e);
     }

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Re: Win32 fails filter\out_bbs_filebucket

Posted by Steve Hay <st...@uk.radan.com>.
Stas Bekman wrote:

>>>out_bbs_filebucket.pm @ 1.3, rest @ Sunday: works
>>>out_bbs_filebucket.pm @ 1.3, rest @ Monday: not anymore
>>>      
>>>
>
>I reverted all related changes in cvs, please confirm that the current cvs 
>all works fine and I'll post a release candidate tomorrow.
>
Yes -- all works fine for me now.

- Steve



------------------------------------------------
Radan Computational Ltd.

The information contained in this message and any files transmitted with it are confidential and intended for the addressee(s) only.  If you have received this message in error or there are any problems, please notify the sender immediately.  The unauthorized use, disclosure, copying or alteration of this message is strictly forbidden.  Note that any views or opinions presented in this email are solely those of the author and do not necessarily represent those of Radan Computational Ltd.  The recipient(s) of this message should check it and any attached files for viruses: Radan Computational will accept no liability for any damage caused by any virus transmitted by this email.


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Re: Win32 fails filter\out_bbs_filebucket

Posted by Stas Bekman <st...@stason.org>.
>> out_bbs_filebucket.pm @ 1.3, rest @ Sunday: works
>> out_bbs_filebucket.pm @ 1.3, rest @ Monday: not anymore

I reverted all related changes in cvs, please confirm that the current cvs 
all works fine and I'll post a release candidate tomorrow.


-- 
__________________________________________________________________
Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/     mod_perl Guide ---> http://perl.apache.org
mailto:stas@stason.org http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://ticketmaster.com

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Re: Win32 fails filter\out_bbs_filebucket

Posted by Stas Bekman <st...@stason.org>.
Markus Wichitill wrote:
> Stas Bekman wrote:
> 
>>>>> Even reverting this change I still find that "nmake test" hangs 
>>>>> when it gets to that test.  Must be something else that's changed 
>>>>> since Friday...
>>>>
>>>>
>>>> Yes, this change?
>>>> http://cvs.apache.org/viewcvs.cgi/modperl-2.0/t/filter/TestFilter/out_bbs_filebucket.pm?r1=1.2&r2=1.3 
>>>
>>>
>>>
>>> I've reverted that one too, but it still doesn't stop it from hanging.
>>
>>
>> Hmm, so if you checkout the cvs from Friday, does it work fine?
> 
> 
> out_bbs_filebucket.pm @ 1.3, rest @ Sunday: works
> out_bbs_filebucket.pm @ 1.3, rest @ Monday: not anymore
> 
> Changed files between those revisions:
> 
> P Changes
> P Makefile.PL
> P docs/api/APR/Bucket.pod
> P docs/api/Apache/Const.pod
> P docs/api/Apache/Module.pod
> P docs/api/Apache/PerlSections.pod
> P docs/devel/porting/porting.pod
> P docs/user/handlers/filters.pod
> P docs/user/handlers/http.pod
> P docs/user/handlers/protocols.pod
> P docs/user/install/install.pod
> P lib/Apache/Build.pm
> P lib/ModPerl/BuildMM.pm
> P src/modules/perl/modperl_handler.c
> P src/modules/perl/modperl_util.c
> P src/modules/perl/modperl_util.h
> P t/error/syntax.t
> P t/filter/TestFilter/in_bbs_body.pm
> P t/filter/TestFilter/in_bbs_inject_header.pm
> P t/filter/TestFilter/in_bbs_msg.pm
> P t/filter/TestFilter/out_bbs_basic.pm
> P t/filter/TestFilter/out_bbs_ctx.pm
> P t/protocol/echo_bbs.t
> P t/protocol/TestProtocol/echo_bbs.pm
> P t/response/TestAPR/bucket.pm
> P t/response/TestError/syntax.pm
> P todo/api_status
> P todo/release
> P xs/Apache/RequestIO/Apache__RequestIO.h
> 
> Some random test combinations involving changed files with fairly varied 
> results:
> 
> perl t\TEST t\filter\out_bbs_filebucket.t
> -> ok
> 
> perl t\TEST t\filter\out_bbs_basic.t t\filter\out_bbs_filebucket.t
> -> ok
> 
> perl t\TEST t\filter\out_bbs_body.t t\filter\out_bbs_filebucket.t
> -> ok
> 
> perl t\TEST t\filter\out_bbs_ctx.t t\filter\out_bbs_filebucket.t
> -> out_bbs_filebucket.t hangs
> 
> perl t\TEST t\filter\in_bbs_msg.t t\filter\out_bbs_filebucket.t
> -> in_bbs_msg.t crashes Apache like in_bbs_inject_header.t
> 
> perl t\TEST -v t\protocol\echo_bbs.t t\filter\out_bbs_filebucket.t
> -> [...]
> ok 6
> # Failed test 7 in t\filter\out_bbs_filebucket.t at line 25 fail #4
> # Failed test 8 in t\filter\out_bbs_filebucket.t at line 26 fail #4
> # testing : length
> # expected: 1024000
> # received: 18
> not ok 7
> not ok 8
> # testing : length
> # expected: 5120000
> # received: 5120000
> ok 9
> [...]

I suppose these are the changes that broke things:

diff -ru --exclude=docs --exclude=CVS 
mp2-20040815/t/filter/TestFilter/in_bbs_body.pm 
mp2-20040816/t/filter/TestFilter/in_bbs_body.pm
--- mp2-20040815/t/filter/TestFilter/in_bbs_body.pm	2004-08-14 
23:30:51.000000000 -0700
+++ mp2-20040816/t/filter/TestFilter/in_bbs_body.pm	2004-08-15 
00:55:52.000000000 -0700
@@ -19,27 +19,17 @@
      #warn "Called!";
      my $ba = $filter->r->connection->bucket_alloc;

-    my $ctx_bb = APR::Brigade->new($filter->r->pool, $ba);
+    $filter->next->get_brigade($bb, $mode, $block, $readbytes);
+    for (my $b = $bb->first; $b; $b = $bb->next($b)) {

-    $filter->next->get_brigade($ctx_bb, $mode, $block, $readbytes);
-
-    while (!$ctx_bb->is_empty) {
-        my $b = $ctx_bb->first;
-
-        $b->remove;
-
-        if ($b->is_eos) {
-            #warn "EOS!!!!";
-            $bb->insert_tail($b);
-            last;
-        }
+        last if $b->is_eos;

          if ($b->read(my $data)) {
              #warn"[$data]\n";
-            $b = APR::Bucket->new(scalar reverse $data);
+            my $nb = APR::Bucket->new(scalar reverse $data);
+            $b->insert_before($nb);
+            $b->remove;
          }
-
-        $bb->insert_tail($b);
      }

      Apache::OK;
diff -ru --exclude=docs --exclude=CVS 
mp2-20040815/t/filter/TestFilter/in_bbs_msg.pm 
mp2-20040816/t/filter/TestFilter/in_bbs_msg.pm
--- mp2-20040815/t/filter/TestFilter/in_bbs_msg.pm	2004-08-14 
23:30:50.000000000 -0700
+++ mp2-20040816/t/filter/TestFilter/in_bbs_msg.pm	2004-08-15 
00:55:52.000000000 -0700
@@ -23,35 +23,24 @@

      debug "FILTER CALLED";
      my $c = $filter->c;
-    my $ctx_bb = APR::Brigade->new($c->pool, $c->bucket_alloc);

-    $filter->next->get_brigade($ctx_bb, $mode, $block, $readbytes);
+    $filter->next->get_brigade($bb, $mode, $block, $readbytes);
+    for (my $b = $bb->first; $b; $b = $bb->next($b)) {

-    while (!$ctx_bb->is_empty) {
-        my $b = $ctx_bb->first;
+        last if $b->is_eos;

-        $b->remove;
-
-        if ($b->is_eos) {
-            debug "EOS!!!";
-            $bb->insert_tail($b);
-            last;
-        }
-
-        $b->read(my $data);
-        debug "FILTER READ:\n$data";
-
-        if ($data and $data =~ s,GET $from_url,GET $to_url,) {
-            debug "GET line rewritten to be:\n$data";
-            $b = APR::Bucket->new($data);
+        if ($b->read(my $data)) {
+            next unless $data =~ s|GET $from_url|GET $to_url|;
+            debug "new GET line:\n$data";
+            my $nb = APR::Bucket->new($data);
+            $b->insert_before($nb);
+            $b->remove;
              # XXX: currently a bug in httpd doesn't allow to remove
              # the first connection filter. once it's fixed adjust the test
              # to test that it was invoked only once.
              # debug "removing the filter";
              # $filter->remove; # this filter is no longer needed
          }
-
-        $bb->insert_tail($b);
      }

      Apache::OK;
diff -ru --exclude=docs --exclude=CVS 
mp2-20040815/t/filter/TestFilter/out_bbs_ctx.pm 
mp2-20040816/t/filter/TestFilter/out_bbs_ctx.pm
--- mp2-20040815/t/filter/TestFilter/out_bbs_ctx.pm	2004-08-14 
23:30:50.000000000 -0700
+++ mp2-20040816/t/filter/TestFilter/out_bbs_ctx.pm	2004-08-15 
00:55:52.000000000 -0700
@@ -31,7 +31,6 @@
      my $data = exists $ctx->{data} ? $ctx->{data} : '';

      while (my $b = $bb->first) {
-        $b->remove;

          if ($b->is_eos) {
              # flush the remainings and send a stats signature
@@ -44,6 +43,7 @@
          }

          if ($b->read(my $bdata)) {
+            $b->remove;
              $data .= $bdata;
              my $len = length $data;

@@ -59,6 +59,12 @@
                  $bb_ctx->insert_tail($b);
              }
          }
+        else {
+            # insert META buckets as is
+            $b->remove;
+            $bb_ctx->insert_tail($b);
+        }
+
      }

      $ctx->{data} = $data;
diff -ru --exclude=docs --exclude=CVS 
mp2-20040815/t/filter/TestFilter/out_bbs_filebucket.pm 
mp2-20040816/t/filter/TestFilter/out_bbs_filebucket.pm
--- mp2-20040815/t/filter/TestFilter/out_bbs_filebucket.pm	2004-08-14 
11:46:01.000000000 -0700
+++ mp2-20040816/t/filter/TestFilter/out_bbs_filebucket.pm	2004-08-15 
00:55:52.000000000 -0700
@@ -23,9 +23,6 @@
  sub handler {
      my($filter, $bb) = @_;

-    my $c = $filter->c;
-    my $bb_ctx = APR::Brigade->new($c->pool, $c->bucket_alloc);
-
      debug "FILTER INVOKED";

      my $cnt = 0;
@@ -34,19 +31,16 @@
          $cnt++;
          debug "reading bucket #$cnt";

-        if ($b->is_eos) {
-            $b->remove;
-            $bb_ctx->insert_tail($b);
-            last;
-        }
+        last if $b->is_eos;

          if (my $len = $b->read(my $data)) {
              my $nb = APR::Bucket->new(uc $data);
-            $bb_ctx->insert_tail($nb);
+            $b->insert_before($nb);
+            $b->remove;
          }
      }

-    my $rv = $filter->next->pass_brigade($bb_ctx);
+    my $rv = $filter->next->pass_brigade($bb);
      return $rv unless $rv == APR::SUCCESS;

      return Apache::OK;
diff -ru --exclude=docs --exclude=CVS 
mp2-20040815/t/protocol/TestProtocol/echo_bbs.pm 
mp2-20040816/t/protocol/TestProtocol/echo_bbs.pm
--- mp2-20040815/t/protocol/TestProtocol/echo_bbs.pm	2004-06-30 
19:01:21.000000000 -0700
+++ mp2-20040816/t/protocol/TestProtocol/echo_bbs.pm	2004-08-15 
00:55:52.000000000 -0700
@@ -4,6 +4,9 @@
  # manipulations on the buckets inside the connection handler, rather
  # then using filter

+# it also demonstrates how to use a single bucket bridade to do all
+# the manipulation
+
  use strict;
  use warnings FATAL => 'all';

@@ -23,38 +26,31 @@
      # the socket to a blocking IO mode
      $c->client_socket->opt_set(APR::SO_NONBLOCK, 0);

-    my $bb_in  = APR::Brigade->new($c->pool, $c->bucket_alloc);
-    my $bb_out = APR::Brigade->new($c->pool, $c->bucket_alloc);
+    my $bb = APR::Brigade->new($c->pool, $c->bucket_alloc);

      while (1) {
-        my $rc = $c->input_filters->get_brigade($bb_in,
+        my $rc = $c->input_filters->get_brigade($bb,
                                                  Apache::MODE_GETLINE);
          last if $rc == APR::EOF;
          die APR::Error::strerror($rc) unless $rc == APR::SUCCESS;

-        while (!$bb_in->is_empty) {
-            my $bucket = $bb_in->first;
-
-            $bucket->remove;
+        for (my $b = $bb->first; $b; $b = $bb->next($b)) {

-            if ($bucket->is_eos) {
-                $bb_out->insert_tail($bucket);
-                last;
-            }
+            last if $b->is_eos;

-            if ($bucket->read(my $data)) {
+            if ($b->read(my $data)) {
                  last if $data =~ /^[\r\n]+$/;
-                $bucket = APR::Bucket->new(uc $data);
+                my $nb = APR::Bucket->new(uc $data);
+                # head->...->$nb->$b ->...->tail
+                $b->insert_before($nb);
+                $b->remove;
              }
-
-            $bb_out->insert_tail($bucket);
          }

-        $c->output_filters->fflush($bb_out);
+        $c->output_filters->fflush($bb);
      }

-    $bb_in->destroy;
-    $bb_out->destroy;
+    $bb->destroy;

      Apache::OK;
  }

-- 
__________________________________________________________________
Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/     mod_perl Guide ---> http://perl.apache.org
mailto:stas@stason.org http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://ticketmaster.com

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Re: Win32 fails filter\out_bbs_filebucket

Posted by Markus Wichitill <ma...@gmx.de>.
Stas Bekman wrote:
>>>> Even reverting this change I still find that "nmake test" hangs when 
>>>> it gets to that test.  Must be something else that's changed since 
>>>> Friday...
>>>
>>> Yes, this change?
>>> http://cvs.apache.org/viewcvs.cgi/modperl-2.0/t/filter/TestFilter/out_bbs_filebucket.pm?r1=1.2&r2=1.3 
>>
>> I've reverted that one too, but it still doesn't stop it from hanging.
> 
> Hmm, so if you checkout the cvs from Friday, does it work fine?

out_bbs_filebucket.pm @ 1.3, rest @ Sunday: works
out_bbs_filebucket.pm @ 1.3, rest @ Monday: not anymore

Changed files between those revisions:

P Changes
P Makefile.PL
P docs/api/APR/Bucket.pod
P docs/api/Apache/Const.pod
P docs/api/Apache/Module.pod
P docs/api/Apache/PerlSections.pod
P docs/devel/porting/porting.pod
P docs/user/handlers/filters.pod
P docs/user/handlers/http.pod
P docs/user/handlers/protocols.pod
P docs/user/install/install.pod
P lib/Apache/Build.pm
P lib/ModPerl/BuildMM.pm
P src/modules/perl/modperl_handler.c
P src/modules/perl/modperl_util.c
P src/modules/perl/modperl_util.h
P t/error/syntax.t
P t/filter/TestFilter/in_bbs_body.pm
P t/filter/TestFilter/in_bbs_inject_header.pm
P t/filter/TestFilter/in_bbs_msg.pm
P t/filter/TestFilter/out_bbs_basic.pm
P t/filter/TestFilter/out_bbs_ctx.pm
P t/protocol/echo_bbs.t
P t/protocol/TestProtocol/echo_bbs.pm
P t/response/TestAPR/bucket.pm
P t/response/TestError/syntax.pm
P todo/api_status
P todo/release
P xs/Apache/RequestIO/Apache__RequestIO.h

Some random test combinations involving changed files with fairly varied 
results:

perl t\TEST t\filter\out_bbs_filebucket.t
-> ok

perl t\TEST t\filter\out_bbs_basic.t t\filter\out_bbs_filebucket.t
-> ok

perl t\TEST t\filter\out_bbs_body.t t\filter\out_bbs_filebucket.t
-> ok

perl t\TEST t\filter\out_bbs_ctx.t t\filter\out_bbs_filebucket.t
-> out_bbs_filebucket.t hangs

perl t\TEST t\filter\in_bbs_msg.t t\filter\out_bbs_filebucket.t
-> in_bbs_msg.t crashes Apache like in_bbs_inject_header.t

perl t\TEST -v t\protocol\echo_bbs.t t\filter\out_bbs_filebucket.t
-> [...]
ok 6
# Failed test 7 in t\filter\out_bbs_filebucket.t at line 25 fail #4
# Failed test 8 in t\filter\out_bbs_filebucket.t at line 26 fail #4
# testing : length
# expected: 1024000
# received: 18
not ok 7
not ok 8
# testing : length
# expected: 5120000
# received: 5120000
ok 9
[...]


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Re: Win32 fails filter\out_bbs_filebucket

Posted by Stas Bekman <st...@stason.org>.
Steve Hay wrote:
> Stas Bekman wrote:
> 
> 
>>Steve Hay wrote:
>> 
>>
>>
>>>Even reverting this change I still find that "nmake test" hangs when it 
>>>gets to that test.  Must be something else that's changed since Friday...
>>>   
>>>
>>
>>Yes, this change?
>>http://cvs.apache.org/viewcvs.cgi/modperl-2.0/t/filter/TestFilter/out_bbs_filebucket.pm?r1=1.2&r2=1.3
>>
> 
> I've reverted that one too, but it still doesn't stop it from hanging.

Hmm, so if you checkout the cvs from Friday, does it work fine?

-- 
__________________________________________________________________
Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/     mod_perl Guide ---> http://perl.apache.org
mailto:stas@stason.org http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://ticketmaster.com

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Re: Win32 fails filter\out_bbs_filebucket

Posted by Steve Hay <st...@uk.radan.com>.
Stas Bekman wrote:

>Steve Hay wrote:
>  
>
>>Even reverting this change I still find that "nmake test" hangs when it 
>>gets to that test.  Must be something else that's changed since Friday...
>>    
>>
>
>Yes, this change?
>http://cvs.apache.org/viewcvs.cgi/modperl-2.0/t/filter/TestFilter/out_bbs_filebucket.pm?r1=1.2&r2=1.3
>
I've reverted that one too, but it still doesn't stop it from hanging.




------------------------------------------------
Radan Computational Ltd.

The information contained in this message and any files transmitted with it are confidential and intended for the addressee(s) only.  If you have received this message in error or there are any problems, please notify the sender immediately.  The unauthorized use, disclosure, copying or alteration of this message is strictly forbidden.  Note that any views or opinions presented in this email are solely those of the author and do not necessarily represent those of Radan Computational Ltd.  The recipient(s) of this message should check it and any attached files for viruses: Radan Computational will accept no liability for any damage caused by any virus transmitted by this email.


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Re: Win32 fails filter\out_bbs_filebucket

Posted by Stas Bekman <st...@stason.org>.
Steve Hay wrote:

> This allows the test to run successfully in isolation for me, but "nmake 
> test" now hangs when it reaches this test.

great!

> Even reverting this change I still find that "nmake test" hangs when it 
> gets to that test.  Must be something else that's changed since Friday...

Yes, this change?
http://cvs.apache.org/viewcvs.cgi/modperl-2.0/t/filter/TestFilter/out_bbs_filebucket.pm?r1=1.2&r2=1.3

-- 
__________________________________________________________________
Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/     mod_perl Guide ---> http://perl.apache.org
mailto:stas@stason.org http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://ticketmaster.com

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Re: Win32 fails filter\out_bbs_filebucket

Posted by Steve Hay <st...@uk.radan.com>.
Stas Bekman wrote:

>Markus Wichitill wrote:
>  
>
>>Stas Bekman wrote:
>>
>>    
>>
>>>Index: t/filter/TestFilter/out_bbs_filebucket.pm
>>>===================================================================
>>>RCS file: 
>>>/home/cvs/modperl-2.0/t/filter/TestFilter/out_bbs_filebucket.pm,v
>>>retrieving revision 1.1
>>>diff -u -r1.1 out_bbs_filebucket.pm
>>>--- t/filter/TestFilter/out_bbs_filebucket.pm   13 Aug 2004 01:51:14 
>>>-0000     1.1
>>>+++ t/filter/TestFilter/out_bbs_filebucket.pm   13 Aug 2004 17:24:19 
>>>-0000
>>>@@ -58,6 +58,9 @@
>>>
>>>     $r->content_type('text/plain');
>>>     my $file = $r->args;
>>>+    warn "file: $file\n";
>>>+
>>>+    $file =~ s|\\|/|g; # sendfile wants a unix style separator?
>>>
>>>     $r->sendfile($file);
>>>      
>>>
>>The backslashes are URL-escaped, either of the following works:
>>
>>$file =~ s|%5C|\\|g;
>>$file =~ s|%5C|/|g;
>>    
>>
>
>Excellent, committed. Thanks Markus.
>
This allows the test to run successfully in isolation for me, but "nmake 
test" now hangs when it reaches this test.

Even reverting this change I still find that "nmake test" hangs when it 
gets to that test.  Must be something else that's changed since Friday...

- Steve



------------------------------------------------
Radan Computational Ltd.

The information contained in this message and any files transmitted with it are confidential and intended for the addressee(s) only.  If you have received this message in error or there are any problems, please notify the sender immediately.  The unauthorized use, disclosure, copying or alteration of this message is strictly forbidden.  Note that any views or opinions presented in this email are solely those of the author and do not necessarily represent those of Radan Computational Ltd.  The recipient(s) of this message should check it and any attached files for viruses: Radan Computational will accept no liability for any damage caused by any virus transmitted by this email.


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Re: Win32 fails filter\out_bbs_filebucket

Posted by Stas Bekman <st...@stason.org>.
Markus Wichitill wrote:
> Stas Bekman wrote:
> 
>> Index: t/filter/TestFilter/out_bbs_filebucket.pm
>> ===================================================================
>> RCS file: 
>> /home/cvs/modperl-2.0/t/filter/TestFilter/out_bbs_filebucket.pm,v
>> retrieving revision 1.1
>> diff -u -r1.1 out_bbs_filebucket.pm
>> --- t/filter/TestFilter/out_bbs_filebucket.pm   13 Aug 2004 01:51:14 
>> -0000     1.1
>> +++ t/filter/TestFilter/out_bbs_filebucket.pm   13 Aug 2004 17:24:19 
>> -0000
>> @@ -58,6 +58,9 @@
>>
>>      $r->content_type('text/plain');
>>      my $file = $r->args;
>> +    warn "file: $file\n";
>> +
>> +    $file =~ s|\\|/|g; # sendfile wants a unix style separator?
>>
>>      $r->sendfile($file);
> 
> 
> The backslashes are URL-escaped, either of the following works:
> 
> $file =~ s|%5C|\\|g;
> $file =~ s|%5C|/|g;

Excellent, committed. Thanks Markus.

I'm adding a better sendfile failure message, so it now tells which file 
it has failed to open :)

-- 
__________________________________________________________________
Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/     mod_perl Guide ---> http://perl.apache.org
mailto:stas@stason.org http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://ticketmaster.com

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Re: Win32 fails filter\out_bbs_filebucket

Posted by Markus Wichitill <ma...@gmx.de>.
Markus Wichitill wrote:
> The backslashes are URL-escaped

Same issue in lookup_misc.

Index: t/filter/TestFilter/out_bbs_filebucket.pm
===================================================================
RCS file: 
/home/cvspublic/modperl-2.0/t/filter/TestFilter/out_bbs_filebucket.pm,v
retrieving revision 1.1
diff -u -r1.1 out_bbs_filebucket.pm
--- t/filter/TestFilter/out_bbs_filebucket.pm	13 Aug 2004 01:51:14 -0000	1.1
+++ t/filter/TestFilter/out_bbs_filebucket.pm	14 Aug 2004 15:38:31 -0000
@@ -8,6 +8,7 @@
  use Apache::RequestRec ();
  use Apache::RequestIO ();
  use Apache::Filter;
+use Apache::URI ();

  use APR::Brigade ();
  use APR::Bucket ();
@@ -58,7 +59,7 @@

      $r->content_type('text/plain');
      my $file = $r->args;
-
+    Apache::URI::unescape_url($file);
      $r->sendfile($file);

      return Apache::OK;
Index: t/response/TestAPI/lookup_misc.pm
===================================================================
RCS file: /home/cvspublic/modperl-2.0/t/response/TestAPI/lookup_misc.pm,v
retrieving revision 1.1
diff -u -r1.1 lookup_misc.pm
--- t/response/TestAPI/lookup_misc.pm	14 Aug 2004 05:10:12 -0000	1.1
+++ t/response/TestAPI/lookup_misc.pm	14 Aug 2004 15:42:02 -0000
@@ -11,6 +11,7 @@
  use Apache::RequestIO ();
  use Apache::Filter ();
  use Apache::SubRequest ();
+use Apache::URI ();

  use Apache::TestTrace;

@@ -25,6 +26,7 @@

      if ($args{subreq} eq 'lookup_file') {
          debug "lookup_file($args{file})";
+        Apache::URI::unescape_url($args{file});
          my $subr = $r->lookup_file($args{file});
          $subr->run;
      }


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Re: Win32 fails filter\out_bbs_filebucket

Posted by Markus Wichitill <ma...@gmx.de>.
Stas Bekman wrote:
> Index: t/filter/TestFilter/out_bbs_filebucket.pm
> ===================================================================
> RCS file: /home/cvs/modperl-2.0/t/filter/TestFilter/out_bbs_filebucket.pm,v
> retrieving revision 1.1
> diff -u -r1.1 out_bbs_filebucket.pm
> --- t/filter/TestFilter/out_bbs_filebucket.pm   13 Aug 2004 01:51:14 
> -0000     1.1
> +++ t/filter/TestFilter/out_bbs_filebucket.pm   13 Aug 2004 17:24:19 -0000
> @@ -58,6 +58,9 @@
> 
>      $r->content_type('text/plain');
>      my $file = $r->args;
> +    warn "file: $file\n";
> +
> +    $file =~ s|\\|/|g; # sendfile wants a unix style separator?
> 
>      $r->sendfile($file);

The backslashes are URL-escaped, either of the following works:

$file =~ s|%5C|\\|g;
$file =~ s|%5C|/|g;

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Re: Win32 fails filter\out_bbs_filebucket

Posted by Stas Bekman <st...@stason.org>.
And this will show the filename when it fails to open it.

Index: xs/Apache/RequestIO/Apache__RequestIO.h
===================================================================
RCS file: /home/cvs/modperl-2.0/xs/Apache/RequestIO/Apache__RequestIO.h,v
retrieving revision 1.54
diff -u -r1.54 Apache__RequestIO.h
--- xs/Apache/RequestIO/Apache__RequestIO.h     12 Jul 2004 08:17:09 
-0000     1.54
+++ xs/Apache/RequestIO/Apache__RequestIO.h     13 Aug 2004 17:33:21 -0000
@@ -325,7 +325,10 @@

      if (rc != APR_SUCCESS) {
          if (GIMME_V == G_VOID) {
-            modperl_croak(aTHX_ rc, "Apache::RequestIO::sendfile");
+            modperl_croak(aTHX_ rc,
+                          apr_psprintf(r->pool,
+                                       "Apache::RequestIO::sendfile('%s')",
+                                       filename));
          }
          else {
              return rc;


-- 
__________________________________________________________________
Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/     mod_perl Guide ---> http://perl.apache.org
mailto:stas@stason.org http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://ticketmaster.com

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Re: Win32 fails filter\out_bbs_filebucket

Posted by Stas Bekman <st...@stason.org>.
sorry, wrong slash:

Index: t/filter/TestFilter/out_bbs_filebucket.pm
===================================================================
RCS file: /home/cvs/modperl-2.0/t/filter/TestFilter/out_bbs_filebucket.pm,v
retrieving revision 1.1
diff -u -r1.1 out_bbs_filebucket.pm
--- t/filter/TestFilter/out_bbs_filebucket.pm   13 Aug 2004 01:51:14 
-0000     1.1
+++ t/filter/TestFilter/out_bbs_filebucket.pm   13 Aug 2004 17:24:19 -0000
@@ -58,6 +58,9 @@

      $r->content_type('text/plain');
      my $file = $r->args;
+    warn "file: $file\n";
+
+    $file =~ s|\\|/|g; # sendfile wants a unix style separator?

      $r->sendfile($file);



-- 
__________________________________________________________________
Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/     mod_perl Guide ---> http://perl.apache.org
mailto:stas@stason.org http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://ticketmaster.com

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Re: Win32 fails filter\out_bbs_filebucket

Posted by Stas Bekman <st...@stason.org>.
Steve Hay wrote:
> Stas Bekman wrote:
> 
> 
>>Steve Hay wrote:
>> 
>>
>>
>>>error_log contains:
>>>
>>>[Fri Aug 13 17:48:59 2004] [error] [client 127.0.0.1] 
>>>Apache::RequestIO::sendfile: (720002) The system cannot find the file 
>>>specified.   at 
>>>   
>>>
>>
>>Steve, could you change the client t\filter\out_bbs_filebucket.t to pass 
>>a filename so that win32 will like it?
>>
>>       my $file = catfile $dir, "data_${size}k.txt";
>>
>>I don't know what sendfile wants on win32, does it want the file to be / 
>>separated?
>>
> 
> Ah ha!  That's it -- it works OK with this:
> 
> Index: t/filter/out_bbs_filebucket.t
> ===================================================================
> RCS file: /home/cvspublic/modperl-2.0/t/filter/out_bbs_filebucket.t,v
> retrieving revision 1.1
> diff -u -u -r1.1 out_bbs_filebucket.t
> --- t/filter/out_bbs_filebucket.t       13 Aug 2004 01:51:15 -0000      1.1
> +++ t/filter/out_bbs_filebucket.t       13 Aug 2004 17:11:26 -0000
> @@ -33,6 +33,7 @@
>      my $data = "ABCD" x ($size * 256);
> 
>      my $file = catfile $dir, "data_${size}k.txt";
> +    $file =~ s/\\/\//g;
>      open my $fh, ">$file" or die "can't open $file: $!";
>      # need binmode on Win32 so as not to strip \r, which
>      # are included when sending with sendfile().

Good, but that's a workaround. Any idea why can't it open the win32 file?

static MP_INLINE
apr_status_t mpxs_Apache__RequestRec_sendfile(pTHX_ request_rec *r,
                                               const char *filename,
                                               apr_off_t offset,
                                               apr_size_t len)
{
     apr_size_t nbytes;
     apr_status_t rc;
     apr_file_t *fp;

     rc = apr_file_open(&fp, filename, APR_READ|APR_BINARY,
                        APR_OS_DEFAULT, r->pool);

that's where it fails. it's supposed to handle win32 files just fine.

please revert your patch and try this one:

Index: t/filter/TestFilter/out_bbs_filebucket.pm
===================================================================
RCS file: /home/cvs/modperl-2.0/t/filter/TestFilter/out_bbs_filebucket.pm,v
retrieving revision 1.1
diff -u -r1.1 out_bbs_filebucket.pm
--- t/filter/TestFilter/out_bbs_filebucket.pm   13 Aug 2004 01:51:14 
-0000     1.1
+++ t/filter/TestFilter/out_bbs_filebucket.pm   13 Aug 2004 17:21:51 -0000
@@ -58,6 +58,9 @@

      $r->content_type('text/plain');
      my $file = $r->args;
+    warn "file: $file\n";
+
+    $file =~ s|//|/|g; # sendfile wants a unix style separator?

      $r->sendfile($file);

what does warn say? Doesn't \\ => break things like C:\\?

-- 
__________________________________________________________________
Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/     mod_perl Guide ---> http://perl.apache.org
mailto:stas@stason.org http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://ticketmaster.com

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Re: Win32 fails filter\out_bbs_filebucket

Posted by Steve Hay <st...@uk.radan.com>.
Stas Bekman wrote:

>Steve Hay wrote:
>  
>
>>error_log contains:
>>
>>[Fri Aug 13 17:48:59 2004] [error] [client 127.0.0.1] 
>>Apache::RequestIO::sendfile: (720002) The system cannot find the file 
>>specified.   at 
>>    
>>
>
>Steve, could you change the client t\filter\out_bbs_filebucket.t to pass 
>a filename so that win32 will like it?
>
>        my $file = catfile $dir, "data_${size}k.txt";
>
>I don't know what sendfile wants on win32, does it want the file to be / 
>separated?
>
Ah ha!  That's it -- it works OK with this:

Index: t/filter/out_bbs_filebucket.t
===================================================================
RCS file: /home/cvspublic/modperl-2.0/t/filter/out_bbs_filebucket.t,v
retrieving revision 1.1
diff -u -u -r1.1 out_bbs_filebucket.t
--- t/filter/out_bbs_filebucket.t       13 Aug 2004 01:51:15 -0000      1.1
+++ t/filter/out_bbs_filebucket.t       13 Aug 2004 17:11:26 -0000
@@ -33,6 +33,7 @@
     my $data = "ABCD" x ($size * 256);

     my $file = catfile $dir, "data_${size}k.txt";
+    $file =~ s/\\/\//g;
     open my $fh, ">$file" or die "can't open $file: $!";
     # need binmode on Win32 so as not to strip \r, which
     # are included when sending with sendfile().




------------------------------------------------
Radan Computational Ltd.

The information contained in this message and any files transmitted with it are confidential and intended for the addressee(s) only.  If you have received this message in error or there are any problems, please notify the sender immediately.  The unauthorized use, disclosure, copying or alteration of this message is strictly forbidden.  Note that any views or opinions presented in this email are solely those of the author and do not necessarily represent those of Radan Computational Ltd.  The recipient(s) of this message should check it and any attached files for viruses: Radan Computational will accept no liability for any damage caused by any virus transmitted by this email.


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Re: Win32 fails filter\out_bbs_filebucket

Posted by Stas Bekman <st...@stason.org>.
Steve Hay wrote:
> Using current CVS with 2.0.49 / 5.8.4:
> 
> C:\Temp\modperl-2.0>perl t/TEST -verbose t\filter\out_bbs_filebucket.t
> [...]
> t\filter\out_bbs_filebucket....1..10
> # Running under perl version 5.008004 for MSWin32
> # Current time local: Fri Aug 13 17:48:58 2004
> # Current time GMT:   Fri Aug 13 16:48:58 2004
> # Using Test.pm version 1.24
> # Using Apache/Test.pm version 1.13
> # Failed test 1 in t\filter\out_bbs_filebucket.t at line 25
> # testing : length
> # expected: 1024
> # received: 674
> not ok 1
> # Failed test 2 in t\filter\out_bbs_filebucket.t at line 26
> not ok 2
> # Failed test 3 in t\filter\out_bbs_filebucket.t at line 25 fail #2
> # Failed test 4 in t\filter\out_bbs_filebucket.t at line 26 fail #2
> # testing : length
> # expected: 102400
> # received: 674
> not ok 3
> not ok 4
> # Failed test 5 in t\filter\out_bbs_filebucket.t at line 25 fail #3
> # Failed test 6 in t\filter\out_bbs_filebucket.t at line 26 fail #3
> # testing : length
> # expected: 512000
> # received: 674
> not ok 5
> not ok 6
> # Failed test 7 in t\filter\out_bbs_filebucket.t at line 25 fail #4
> # Failed test 8 in t\filter\out_bbs_filebucket.t at line 26 fail #4
> # testing : length
> # expected: 1024000
> # received: 674
> not ok 7
> not ok 8
> # Failed test 9 in t\filter\out_bbs_filebucket.t at line 25 fail #5
> # Failed test 10 in t\filter\out_bbs_filebucket.t at line 26 fail #5
> # testing : length
> # expected: 5120000
> # received: 674
> not ok 9
> not ok 10
> FAILED tests 1-10
>         Failed 10/10 tests, 0.00% okay
> Failed Test                   Stat Wstat Total Fail  Failed  List of Failed
> -------------------------------------------------------------------------------
> t\filter\out_bbs_filebucket.t               10   10 100.00%  1-10
> Failed 1/1 test scripts, 0.00% okay. 10/10 subtests failed, 0.00% okay.
> 
> error_log contains:
> 
> [Fri Aug 13 17:48:59 2004] [error] [client 127.0.0.1] 
> Apache::RequestIO::sendfile: (720002) The system cannot find the file 
> specified.   at 

Steve, could you change the client t\filter\out_bbs_filebucket.t to pass 
a filename so that win32 will like it?

        my $file = catfile $dir, "data_${size}k.txt";

I don't know what sendfile wants on win32, does it want the file to be / 
separated? The error message is bad (I'll see if I can print out the 
path as well).

-- 
__________________________________________________________________
Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/     mod_perl Guide ---> http://perl.apache.org
mailto:stas@stason.org http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://ticketmaster.com

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org