Return-Path: Delivered-To: apmail-apr-dev-archive@www.apache.org Received: (qmail 68450 invoked from network); 12 Jan 2004 17:03:57 -0000 Received: from daedalus.apache.org (HELO mail.apache.org) (208.185.179.12) by minotaur-2.apache.org with SMTP; 12 Jan 2004 17:03:57 -0000 Received: (qmail 38617 invoked by uid 500); 12 Jan 2004 17:03:49 -0000 Delivered-To: apmail-apr-dev-archive@apr.apache.org Received: (qmail 38580 invoked by uid 500); 12 Jan 2004 17:03:49 -0000 Mailing-List: contact dev-help@apr.apache.org; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: Delivered-To: mailing list dev@apr.apache.org Received: (qmail 38567 invoked from network); 12 Jan 2004 17:03:48 -0000 In-Reply-To: <4002CE6E.6000500@attglobal.net> References: <4002CE6E.6000500@attglobal.net> Mime-Version: 1.0 (Apple Message framework v609) Content-Type: text/plain; charset=US-ASCII; format=flowed Message-Id: <4BABCC60-4521-11D8-871D-000393D76AB8@jagunet.com> Content-Transfer-Encoding: 7bit Cc: dev@apr.apache.org From: Jim Jagielski Subject: Re: [1.3 PATCH] log error if returning 500 Date: Mon, 12 Jan 2004 12:03:51 -0500 To: Jeff Trawick X-Mailer: Apple Mail (2.609) X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N +1 On Jan 12, 2004, at 11:42 AM, Jeff Trawick wrote: > 2.x already does this > > Index: src/modules/standard/mod_mime_magic.c > =================================================================== > RCS file: /home/cvs/apache-1.3/src/modules/standard/mod_mime_magic.c,v > retrieving revision 1.51 > diff -u -r1.51 mod_mime_magic.c > --- src/modules/standard/mod_mime_magic.c 1 Jan 2004 13:32:56 > -0000 1.51 > +++ src/modules/standard/mod_mime_magic.c 12 Jan 2004 16:38:45 -0000 > @@ -832,9 +832,13 @@ > r->content_encoding = tmp; > } > > - /* detect memory allocation errors */ > + /* detect memory allocation or other errors */ > if (!r->content_type || > (state == rsl_encoding && !r->content_encoding)) { > + ap_log_rerror(APLOG_MARK, APLOG_NOERRNO | APLOG_ERR, r, > + MODNAME ": unexpected state %d; could be caused > by bad " > + "data in magic file", > + state); > return HTTP_INTERNAL_SERVER_ERROR; > } >