NetBSD Problem Report #53851
From gson@gson.org Thu Jan 10 11:27:48 2019
Return-Path: <gson@gson.org>
Received: from mail.netbsd.org (mail.netbsd.org [199.233.217.200])
(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
(Client CN "mail.NetBSD.org", Issuer "mail.NetBSD.org CA" (not verified))
by mollari.NetBSD.org (Postfix) with ESMTPS id 95A257A156
for <gnats-bugs@gnats.NetBSD.org>; Thu, 10 Jan 2019 11:27:48 +0000 (UTC)
Message-Id: <20190110112745.078E19892EB@guava.gson.org>
Date: Thu, 10 Jan 2019 13:27:45 +0200 (EET)
From: gson@gson.org (Andreas Gustafsson)
Reply-To: gson@gson.org (Andreas Gustafsson)
To: gnats-bugs@NetBSD.org
Subject: libwrap prints "m" instead of errno
X-Send-Pr-Version: 3.95
>Number: 53851
>Category: lib
>Synopsis: libwrap prints "m" instead of errno
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: lib-bug-people
>State: closed
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Thu Jan 10 11:30:00 +0000 2019
>Closed-Date: Mon Jan 14 06:17:41 +0000 2019
>Last-Modified: Mon Jan 14 10:45:01 +0000 2019
>Originator: Andreas Gustafsson
>Release: NetBSD 8.0_BETA
>Organization:
>Environment:
System: NetBSD
Architecture: i386
Machine: i386
>Description:
Perusing the syslog of a network-facing server, I saw the following
warning messages:
Jan 10 05:58:43 redacted inetd[1291]: warning: can't get client address: m
Jan 10 05:58:43 redacted inetd[1291]: warning: can't get client address: m
That unhelpful "m" apparently aries in src/lib/libwrap/socket.c:
tcpd_warn("can't get client address: %m");
because the changes in src/lib/libwrap/diag.c 1.10 cause tcpd_warn()
to no longer support the "%m" format specifier.
>How-To-Repeat:
>Fix:
>Release-Note:
>Audit-Trail:
From: "Christos Zoulas" <christos@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc:
Subject: PR/53851 CVS commit: src/lib/libwrap
Date: Thu, 10 Jan 2019 08:53:27 -0500
Module Name: src
Committed By: christos
Date: Thu Jan 10 13:53:27 UTC 2019
Modified Files:
src/lib/libwrap: diag.c
Log Message:
PR/53851: Andreas Gustafsson: libwrap prints "m" instead of errno
Handle %m inline if needed, otherwise vasprintf strips the %m and...
To generate a diff of this commit:
cvs rdiff -u -r1.11 -r1.12 src/lib/libwrap/diag.c
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
State-Changed-From-To: open->closed
State-Changed-By: dholland@NetBSD.org
State-Changed-When: Mon, 14 Jan 2019 06:17:41 +0000
State-Changed-Why:
Fixed.
(since this bug has hung around 20+ years before anyone noticed, it
probably doesn't need to be pulled up; but if anyone wants to, note that
not all the related changes made it into the PR)
From: Andreas Gustafsson <gson@gson.org>
To: dholland@NetBSD.org
Cc: gnats-bugs@NetBSD.org
Subject: Re: lib/53851 (libwrap prints "m" instead of errno)
Date: Mon, 14 Jan 2019 11:19:37 +0200
dholland@NetBSD.org wrote:
> (since this bug has hung around 20+ years before anyone noticed,
I believe the bug only appeared with diag.c 1.10, which makes it a bit
less than six years old.
> it probably doesn't need to be pulled up
With this I concur.
--
Andreas Gustafsson, gson@gson.org
From: Andreas Gustafsson <gson@gson.org>
To: dholland@NetBSD.org
Cc: gnats-bugs@NetBSD.org
Subject: Re: lib/53851 (libwrap prints "m" instead of errno)
Date: Mon, 14 Jan 2019 11:21:58 +0200
I said:
> a bit less than six years old
Make that "a bit less than seven years old". Math is hard.
--
Andreas Gustafsson, gson@gson.org
>Unformatted:
(Contact us)
$NetBSD: query-full-pr,v 1.43 2018/01/16 07:36:43 maya Exp $
$NetBSD: gnats_config.sh,v 1.9 2014/08/02 14:16:04 spz Exp $
Copyright © 1994-2017
The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.