Subject: Re: CVS commit: basesrc
To: Luke Mewburn <lukem@wasabisystems.com>
From: Jim Wise <jwise@draga.com>
List: source-changes
Date: 01/10/2001 22:17:35
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On Thu, 11 Jan 2001, Luke Mewburn wrote:
>On Wed, Jan 10, 2001 at 05:47:21PM -0800, Jason R Thorpe wrote:
>> On Thu, Jan 11, 2001 at 03:35:54AM +0200, Luke Mewburn wrote:
>>
>> > Modified Files:
>> > basesrc/usr.sbin/apmd: apmd.c
>> >
>> > Log Message:
>> > use explicit name rather than __progname in openlog
>>
>> What's the point of this?
>
>because we're very inconsistent in the tree about whether we use
>__progname or the explicit name, with the explicit name seeming to
>have more use.
>
>also, there has been various discussions about using a more portable
>solution that __progname (since code that uses it isn't that portable
>outside of NetBSD and its __progname support in lib/csu (?))
>
>i've been doing an audit of the various uses of bits of syslog, and
>inconsistencies like these have popped up so i've been fixing them.
I have no problem with the portability argument. The general question
about whether to use __progname or a hardcoded string is harder: one
can imagine real use for __progname in this case.
As a (contrived, of course) example, suppose I run a chrooted copy of a
daemon, copied to daemon.chroot. If we use openlog(__progname), that
will show in the log message. If we use openlog("daemon") it will not.
I guess I'm not sure if we care, but we might...
- --
Jim Wise
jwise@draga.com
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.4 (NetBSD)
Comment: For info see http://www.gnupg.org
iD8DBQE6XSXV2JhG4/qi8rQRAtHjAJ4tDWVDtlySEg2kOytEdxDcyqBG2QCgxlcg
3AzJiuz8V7KjF+qObma9jvs=
=mroc
-----END PGP SIGNATURE-----