Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 24 Oct 2001 00:50:22 -0700
From:      "Chad R. Larson" <chad@DCFinc.com>
To:        stable@FreeBSD.org
Subject:   Re: pathname length over NFS
Message-ID:  <20011024005022.A21779@freeway.dcfinc.com>
In-Reply-To: <20011023231743.C18073@freeway.dcfinc.com>; from chad@DCFinc.com on Tue, Oct 23, 2001 at 11:17:43PM -0700
References:  <20011020230916.A22304@ecibsd1.eldocomp.com> <200110212102.f9LL2dA88000@lurza.secnetix.de> <20011023231743.C18073@freeway.dcfinc.com>

next in thread | previous in thread | raw e-mail | index | archive | help

--/9DWx/yDrRhgMJTb
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline

> My only defense is the sysexit values overloading the errno values
> sending me down the wrong diagnostic path.

I have a simple-minded program (attached) that displays the text
strings for errno.h values.  Perhaps I need to enhance it to be
sysexits.h aware.

But =really=, shouldn't we adjust the sysexits values so they don't
overload those in errno.h?

	-crl
--
Chad R. Larson (CRL15)   602-953-1392   Brother, can you paradigm?
chad@dcfinc.com         chad@larsons.org          larson1@home.com
DCF, Inc. - 14623 North 49th Place, Scottsdale, Arizona 85254-2207

--/9DWx/yDrRhgMJTb
Content-Type: text/plain; charset=us-ascii
Content-Disposition: attachment; filename="perror.c"

/* $Id: perror.c,v 1.1 1998/08/26 02:09:34 chad Exp $*/

/*
** This program provides a simple command-line interface
** to the system error messages.
*/

/*
** Author:
**   Chad R. Larson			This program is placed in the
**   DCF, Inc.				Public Domain.  You may do with
**   14623 North 49th Place		it as you please.
**   Scottsdale, AZ 85254
*/

main(argc, argv)
    int		argc;
    char	*argv[];
{
    unsigned	index;
    extern int	sys_nerr;
    extern char *sys_errlist[];
    void	exit();

    /* "There can be only one." */
    if (argc != 2)
    {
	(void)printf("Usage: %s errno\n", argv[0]);
	exit (1);
    }

    /* range check it */
    index = (unsigned)atoi(argv[1]);
    if (index > sys_nerr - 1)
    {
	(void)printf("The maximum error number is %d\n", sys_nerr - 1);
	exit(2);
    }

    /* tell 'em what we know */
    (void)printf("The system message for error number %d is:\n", index);
    (void)printf("    %s\n", sys_errlist[index]);
    exit(0);
}

--/9DWx/yDrRhgMJTb--

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-stable" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20011024005022.A21779>