You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Blair Zajac <bl...@orcaware.com> on 2003/04/02 20:13:28 UTC

Safe to remove apr_file_flush?

I'm looking through the source code looking for FIXME's that can
be removed and I ran into this one in subversion/libsvn_ra_dav/util.c:

svn_error_t *svn_ra_dav__set_neon_body_provider(ne_request *req,
                                                apr_file_t *body_file)
{
  apr_status_t status;
  apr_finfo_t finfo;

  /* ### APR bug? apr_file_info_get won't always return the correct
         size for buffered files. */
  /* FIXME: This APR bug has been fixed on both Unix and Win32 for the
     0.9.2 release. Remove this flush once that is part of a released
     httpd (presumably 2.0.45). */
  status = apr_file_flush(body_file);
  if (!status)
    status = apr_file_info_get(&finfo, APR_FINFO_SIZE, body_file);

I normally thought this would be safe to remove, but looking through
APR, only the unix and win32 filestat.c call apr_file_flush.

So, I'm wondering if it's safe to remove code in util.c, because the
netware, os2 filestat.c's don't call apr_file_flush.

Best,
Blair

-- 
Blair Zajac <bl...@orcaware.com>
Plots of your system's performance - http://www.orcaware.com/orca/

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: Safe to remove apr_file_flush?

Posted by Branko Čibej <br...@xbc.nu>.
Michael Wood wrote:

>On Wed, Apr 02, 2003 at 10:17:10PM +0200, Branko ??ibej wrote:
>  
>
>>Blair Zajac wrote:
>>    
>>
>[snip]
>  
>
>>>So, I'm wondering if it's safe to remove code in util.c, because the
>>>netware, os2 filestat.c's don't call apr_file_flush.
>>>      
>>>
>>They don't? Hmmm. Tell you what, since Subversion doesn't run on
>>Netware or OS/2 right now, let's just remove this flush, and file a
>>bug against APR. It's bound to be fixed soon.
>>    
>>
>[snip]
>
>What are the chances of getting the Subversion client running on
>Netware?  Of course, Netware seems to make use of various configuration
>interfaces to configure it instead of just storing stuff in text files.
>At least that's the way it appears based on my limited Netware
>experience.
>  
>

I really haven't the slightest idea. I've never even seen a Netware box.
All I know is that APR runs on Netware, and probably so does httpd. I
don't know about Berkeley DB or Neon, or apr-iconv, either.

-- 
Brane Čibej   <br...@xbc.nu>   http://www.xbc.nu/brane/


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: Safe to remove apr_file_flush?

Posted by Michael Wood <mw...@its.uct.ac.za>.
On Wed, Apr 02, 2003 at 10:17:10PM +0200, Branko ??ibej wrote:
> Blair Zajac wrote:
[snip]
> >So, I'm wondering if it's safe to remove code in util.c, because the
> >netware, os2 filestat.c's don't call apr_file_flush.
> 
> They don't? Hmmm. Tell you what, since Subversion doesn't run on
> Netware or OS/2 right now, let's just remove this flush, and file a
> bug against APR. It's bound to be fixed soon.
[snip]

What are the chances of getting the Subversion client running on
Netware?  Of course, Netware seems to make use of various configuration
interfaces to configure it instead of just storing stuff in text files.
At least that's the way it appears based on my limited Netware
experience.

-- 
Michael Wood <mw...@its.uct.ac.za>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: Safe to remove apr_file_flush?

Posted by Blair Zajac <bl...@orcaware.com>.
Branko ?ibej wrote:
> 
> Blair Zajac wrote:
> 
> >I'm looking through the source code looking for FIXME's that can
> >be removed and I ran into this one in subversion/libsvn_ra_dav/util.c:
> >
> >svn_error_t *svn_ra_dav__set_neon_body_provider(ne_request *req,
> >                                                apr_file_t *body_file)
> >{
> >  apr_status_t status;
> >  apr_finfo_t finfo;
> >
> >  /* ### APR bug? apr_file_info_get won't always return the correct
> >         size for buffered files. */
> >  /* FIXME: This APR bug has been fixed on both Unix and Win32 for the
> >     0.9.2 release. Remove this flush once that is part of a released
> >     httpd (presumably 2.0.45). */
> >  status = apr_file_flush(body_file);
> >  if (!status)
> >    status = apr_file_info_get(&finfo, APR_FINFO_SIZE, body_file);
> >
> >I normally thought this would be safe to remove, but looking through
> >APR, only the unix and win32 filestat.c call apr_file_flush.
> >
> >So, I'm wondering if it's safe to remove code in util.c, because the
> >netware, os2 filestat.c's don't call apr_file_flush.
> >
> >
> 
> They don't? Hmmm. Tell you what, since Subversion doesn't run on Netware
> or OS/2 right now, let's just remove this flush, and file a bug against
> APR. It's bound to be fixed soon.

I've updated the code and will submit a bug to apr.

Best,
Blair

-- 
Blair Zajac <bl...@orcaware.com>
Plots of your system's performance - http://www.orcaware.com/orca/

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: Safe to remove apr_file_flush?

Posted by Branko Čibej <br...@xbc.nu>.
Blair Zajac wrote:

>I'm looking through the source code looking for FIXME's that can
>be removed and I ran into this one in subversion/libsvn_ra_dav/util.c:
>
>svn_error_t *svn_ra_dav__set_neon_body_provider(ne_request *req,
>                                                apr_file_t *body_file)
>{
>  apr_status_t status;
>  apr_finfo_t finfo;
>
>  /* ### APR bug? apr_file_info_get won't always return the correct
>         size for buffered files. */
>  /* FIXME: This APR bug has been fixed on both Unix and Win32 for the
>     0.9.2 release. Remove this flush once that is part of a released
>     httpd (presumably 2.0.45). */
>  status = apr_file_flush(body_file);
>  if (!status)
>    status = apr_file_info_get(&finfo, APR_FINFO_SIZE, body_file);
>
>I normally thought this would be safe to remove, but looking through
>APR, only the unix and win32 filestat.c call apr_file_flush.
>
>So, I'm wondering if it's safe to remove code in util.c, because the
>netware, os2 filestat.c's don't call apr_file_flush.
>  
>

They don't? Hmmm. Tell you what, since Subversion doesn't run on Netware
or OS/2 right now, let's just remove this flush, and file a bug against
APR. It's bound to be fixed soon.

-- 
Brane Čibej   <br...@xbc.nu>   http://www.xbc.nu/brane/


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org