httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Marc Slemko <ma...@worldgate.com>
Subject Re: [PATCH] Re: general/1491: mmap_handler error_log entry for 0 length files
Date Fri, 28 Nov 1997 20:44:13 GMT
On Fri, 28 Nov 1997, Dean Gaudet wrote:

> One more iteration trying to get the mmap code just right ... don't try to
> mmap zero length files. 

Does this fail on some systems?  Works fine on FreeBSD.

You sure the submitter of the PR isn't just seeing the bogus logging that
is in 1.3b3 in the first place, ie. it has nothing to do with zero length?

> 
> Dean
> 
> Index: http_core.c
> ===================================================================
> RCS file: /export/home/cvs/apachen/src/main/http_core.c,v
> retrieving revision 1.141
> diff -u -r1.141 http_core.c
> --- http_core.c	1997/11/22 01:59:57	1.141
> +++ http_core.c	1997/11/28 19:19:21
> @@ -75,15 +75,15 @@
>   * <http://www.isi.edu/~johnh/SOFTWARE/APACHE/index.html>.
>   */
>  
> -/* Files have to be at least this big before they're mmap()d.  This is to
> - * deal with systems where the expense of doing an mmap() and an munmap()
> - * outweighs the benefit for small files.
> +/* Files have to be at least this big before they're mmap()d.  This is to deal
> + * with systems where the expense of doing an mmap() and an munmap() outweighs
> + * the benefit for small files.  It shouldn't be set lower than 1.
>   */
>  #ifndef MMAP_THRESHOLD
>  #ifdef SUNOS4
>  #define MMAP_THRESHOLD		(8*1024)
>  #else
> -#define MMAP_THRESHOLD		0
> +#define MMAP_THRESHOLD		1
>  #endif
>  #endif
>  #endif
> 


Mime
View raw message