httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Ryan Bloom" <...@covalent.net>
Subject RE: requesting guidance on converting a mod to 2.0
Date Thu, 28 Mar 2002 19:05:56 GMT
I am in the process of converting an apache module that I have working
with Apache 1.3 to work with 2.0. This crufty bit of code handles the
dynamic content portion of Specweb99. I must admit my knowledge of
Apache modules is less than it should be as my first module work was
converting this one from isapi to be a 1.3 Apache module. (BTW anyone
else playing with specweb99 out there?)

 

Things that confuse me in the 2.0 API

 

1) In my handler routine, I am trying to push a file aka ap_send_fd or
ap_send_fd_len in apache 1.3.

 

    I found a modified ap_send_fd and am using it. What is unclear is
that it seems that I should not call apr_file_close() on a sucessfull
send which seems real strange. Can I assume that the bucket brigade
stuff closes the file for me ? The code in mod_asis (which mirrors
ap_send_fd) seems to suggest that is the case.

 

The bucket brigade code will handle closing the file for you, yes.

 

 

2) At the top of the handler routine, I copied from mod_example a

 

  if (strcmp(r->handler, "specweb-handler")) {
      return DECLINED;
  }

Without this, I am finding that the handler get called for every
request, even requests which are outside of the <Location> directive
that enables the handler. Am I missing something or is that just how it
is now ?

 

That's just how it is now.

 

Ryan


Mime
View raw message