You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@apr.apache.org by Stas Bekman <st...@stason.org> on 2001/12/11 18:53:43 UTC

exposing apr_file_t's buffering struct members?

Are there any portability problems with exposing the buffering members 
of the apr_file_t struct?

I've the PerlIO layer working with APR, but the problem that now it 
reads one char/call, which is unacceptable and I've two choices to solve 
the problem:

1. implement yet another buffering layer in PerlIO layer - this will 
slow things down.

2. let PerlIO work directly with APR's apr_file_t buffer and its other 
flags.

I prefer the second option performance-wise. PerlIO already has a set of 
hooks to snoop on another layer's buffer. I just need them to be exposed.

What should I do?

Another missing method is apr_file_unread (I know there is ungetc, but 
that does only one char), for example if Perl needs to do regex 
lookahead it will read the data from the stream and then put it back.

_____________________________________________________________________
Stas Bekman             JAm_pH      --   Just Another mod_perl Hacker
http://stason.org/      mod_perl Guide   http://perl.apache.org/guide
mailto:stas@stason.org  http://ticketmaster.com http://apacheweek.com
http://singlesheaven.com http://perl.apache.org http://perlmonth.com/