Index | Thread | Search

From:
Matthias Pressfreund <mpfr@fn.de>
Subject:
Re: diff httpd: avoid misleading syslog warnings
To:
tech@openbsd.org
Date:
Tue, 13 Feb 2024 18:48:24 +0100

Download raw body.

Thread
  • Theo de Raadt:

    diff httpd: avoid misleading syslog warnings

  • Why not straighten out the comment too?
    
    Index: usr.sbin/httpd/server_http.c
    @@ -1753,8 +1753,8 @@
     }
     
     /*
    - * return -1 on failure, strlen() of read file otherwise.
    - * body is NULL on failure, contents of file with trailing \0 otherwise.
    + * return NULL if file does not exist or on failure,
    + * contents of file with trailing \0 otherwise.
      */
     char *
     read_errdoc(const char *root, const char *file)
    
    
    
    On 2024-02-13 14:46, Claudio Jeker wrote:
    > 
    > I guess it would be better to only call log_warn() if the errno is not
    > ENOENT. That should be enough to silence the common case.
    > 
    
    
    
  • Theo de Raadt:

    diff httpd: avoid misleading syslog warnings