1*7c478bd9Sstevel@tonic-gate /* 2*7c478bd9Sstevel@tonic-gate * CDDL HEADER START 3*7c478bd9Sstevel@tonic-gate * 4*7c478bd9Sstevel@tonic-gate * The contents of this file are subject to the terms of the 5*7c478bd9Sstevel@tonic-gate * Common Development and Distribution License, Version 1.0 only 6*7c478bd9Sstevel@tonic-gate * (the "License"). You may not use this file except in compliance 7*7c478bd9Sstevel@tonic-gate * with the License. 8*7c478bd9Sstevel@tonic-gate * 9*7c478bd9Sstevel@tonic-gate * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE 10*7c478bd9Sstevel@tonic-gate * or http://www.opensolaris.org/os/licensing. 11*7c478bd9Sstevel@tonic-gate * See the License for the specific language governing permissions 12*7c478bd9Sstevel@tonic-gate * and limitations under the License. 13*7c478bd9Sstevel@tonic-gate * 14*7c478bd9Sstevel@tonic-gate * When distributing Covered Code, include this CDDL HEADER in each 15*7c478bd9Sstevel@tonic-gate * file and include the License file at usr/src/OPENSOLARIS.LICENSE. 16*7c478bd9Sstevel@tonic-gate * If applicable, add the following below this CDDL HEADER, with the 17*7c478bd9Sstevel@tonic-gate * fields enclosed by brackets "[]" replaced with your own identifying 18*7c478bd9Sstevel@tonic-gate * information: Portions Copyright [yyyy] [name of copyright owner] 19*7c478bd9Sstevel@tonic-gate * 20*7c478bd9Sstevel@tonic-gate * CDDL HEADER END 21*7c478bd9Sstevel@tonic-gate */ 22*7c478bd9Sstevel@tonic-gate /* 23*7c478bd9Sstevel@tonic-gate * Copyright 1989 Sun Microsystems, Inc. All rights reserved. 24*7c478bd9Sstevel@tonic-gate * Use is subject to license terms. 25*7c478bd9Sstevel@tonic-gate */ 26*7c478bd9Sstevel@tonic-gate 27*7c478bd9Sstevel@tonic-gate /* Copyright (c) 1983, 1984, 1985, 1986, 1987, 1988, 1989 AT&T */ 28*7c478bd9Sstevel@tonic-gate /* All Rights Reserved */ 29*7c478bd9Sstevel@tonic-gate 30*7c478bd9Sstevel@tonic-gate /* 31*7c478bd9Sstevel@tonic-gate * Portions of this source code were derived from Berkeley 4.3 BSD 32*7c478bd9Sstevel@tonic-gate * under license from the Regents of the University of California. 33*7c478bd9Sstevel@tonic-gate */ 34*7c478bd9Sstevel@tonic-gate 35*7c478bd9Sstevel@tonic-gate #ifndef _SYSEXITS_H 36*7c478bd9Sstevel@tonic-gate #define _SYSEXITS_H 37*7c478bd9Sstevel@tonic-gate 38*7c478bd9Sstevel@tonic-gate #pragma ident "%Z%%M% %I% %E% SMI" 39*7c478bd9Sstevel@tonic-gate 40*7c478bd9Sstevel@tonic-gate #ifdef __cplusplus 41*7c478bd9Sstevel@tonic-gate extern "C" { 42*7c478bd9Sstevel@tonic-gate #endif 43*7c478bd9Sstevel@tonic-gate 44*7c478bd9Sstevel@tonic-gate /* 45*7c478bd9Sstevel@tonic-gate * SYSEXITS.H -- Exit status codes employed by the mail subsystem. 46*7c478bd9Sstevel@tonic-gate * 47*7c478bd9Sstevel@tonic-gate * This include file attempts to categorize possible error 48*7c478bd9Sstevel@tonic-gate * exit statuses for mail subsystem. 49*7c478bd9Sstevel@tonic-gate * 50*7c478bd9Sstevel@tonic-gate * Error numbers begin at EX__BASE to reduce the possibility of 51*7c478bd9Sstevel@tonic-gate * clashing with other exit statuses that random programs may 52*7c478bd9Sstevel@tonic-gate * already return. The meaning of the codes is approximately 53*7c478bd9Sstevel@tonic-gate * as follows: 54*7c478bd9Sstevel@tonic-gate * 55*7c478bd9Sstevel@tonic-gate * EX_USAGE -- The command was used incorrectly, e.g., with 56*7c478bd9Sstevel@tonic-gate * the wrong number of arguments, a bad flag, a bad 57*7c478bd9Sstevel@tonic-gate * syntax in a parameter, or whatever. 58*7c478bd9Sstevel@tonic-gate * EX_DATAERR -- The input data was incorrect in some way. 59*7c478bd9Sstevel@tonic-gate * This should only be used for user's data & not 60*7c478bd9Sstevel@tonic-gate * system files. 61*7c478bd9Sstevel@tonic-gate * EX_NOINPUT -- An input file (not a system file) did not 62*7c478bd9Sstevel@tonic-gate * exist or was not readable. This could also include 63*7c478bd9Sstevel@tonic-gate * errors like "No message" to a mailer (if it cared 64*7c478bd9Sstevel@tonic-gate * to catch it). 65*7c478bd9Sstevel@tonic-gate * EX_NOUSER -- The user specified did not exist. This might 66*7c478bd9Sstevel@tonic-gate * be used for mail addresses or remote logins. 67*7c478bd9Sstevel@tonic-gate * EX_NOHOST -- The host specified did not exist. This is used 68*7c478bd9Sstevel@tonic-gate * in mail addresses or network requests. 69*7c478bd9Sstevel@tonic-gate * EX_UNAVAILABLE -- A service is unavailable. This can occur 70*7c478bd9Sstevel@tonic-gate * if a support program or file does not exist. This 71*7c478bd9Sstevel@tonic-gate * can also be used as a catchall message when something 72*7c478bd9Sstevel@tonic-gate * you wanted to do doesn't work, but you don't know 73*7c478bd9Sstevel@tonic-gate * why. 74*7c478bd9Sstevel@tonic-gate * EX_SOFTWARE -- An internal software error has been detected. 75*7c478bd9Sstevel@tonic-gate * This should be limited to non-operating system related 76*7c478bd9Sstevel@tonic-gate * errors as possible. 77*7c478bd9Sstevel@tonic-gate * EX_OSERR -- An operating system error has been detected. 78*7c478bd9Sstevel@tonic-gate * This is intended to be used for such things as "cannot 79*7c478bd9Sstevel@tonic-gate * fork", "cannot create pipe", or the like. It includes 80*7c478bd9Sstevel@tonic-gate * things like getuid returning a user that does not 81*7c478bd9Sstevel@tonic-gate * exist in the passwd file. 82*7c478bd9Sstevel@tonic-gate * EX_OSFILE -- Some system file (e.g., /etc/passwd, /etc/utmp, 83*7c478bd9Sstevel@tonic-gate * etc.) does not exist, cannot be opened, or has some 84*7c478bd9Sstevel@tonic-gate * sort of error (e.g., syntax error). 85*7c478bd9Sstevel@tonic-gate * EX_CANTCREAT -- A (user specified) output file cannot be 86*7c478bd9Sstevel@tonic-gate * created. 87*7c478bd9Sstevel@tonic-gate * EX_IOERR -- An error occurred while doing I/O on some file. 88*7c478bd9Sstevel@tonic-gate * EX_TEMPFAIL -- temporary failure, indicating something that 89*7c478bd9Sstevel@tonic-gate * is not really an error. In sendmail, this means 90*7c478bd9Sstevel@tonic-gate * that a mailer (e.g.) could not create a connection, 91*7c478bd9Sstevel@tonic-gate * and the request should be reattempted later. 92*7c478bd9Sstevel@tonic-gate * EX_PROTOCOL -- the remote system returned something that 93*7c478bd9Sstevel@tonic-gate * was "not possible" during a protocol exchange. 94*7c478bd9Sstevel@tonic-gate * EX_NOPERM -- You did not have sufficient permission to 95*7c478bd9Sstevel@tonic-gate * perform the operation. This is not intended for 96*7c478bd9Sstevel@tonic-gate * file system problems, which should use NOINPUT or 97*7c478bd9Sstevel@tonic-gate * CANTCREAT, but rather for higher level permissions. 98*7c478bd9Sstevel@tonic-gate * For example, kre uses this to restrict who students 99*7c478bd9Sstevel@tonic-gate * can send mail to. 100*7c478bd9Sstevel@tonic-gate */ 101*7c478bd9Sstevel@tonic-gate 102*7c478bd9Sstevel@tonic-gate #define EX_OK 0 /* successful termination */ 103*7c478bd9Sstevel@tonic-gate 104*7c478bd9Sstevel@tonic-gate #define EX__BASE 64 /* base value for error messages */ 105*7c478bd9Sstevel@tonic-gate 106*7c478bd9Sstevel@tonic-gate #define EX_USAGE 64 /* command line usage error */ 107*7c478bd9Sstevel@tonic-gate #define EX_DATAERR 65 /* data format error */ 108*7c478bd9Sstevel@tonic-gate #define EX_NOINPUT 66 /* cannot open input */ 109*7c478bd9Sstevel@tonic-gate #define EX_NOUSER 67 /* addressee unknown */ 110*7c478bd9Sstevel@tonic-gate #define EX_NOHOST 68 /* host name unknown */ 111*7c478bd9Sstevel@tonic-gate #define EX_UNAVAILABLE 69 /* service unavailable */ 112*7c478bd9Sstevel@tonic-gate #define EX_SOFTWARE 70 /* internal software error */ 113*7c478bd9Sstevel@tonic-gate #define EX_OSERR 71 /* system error (e.g., can't fork) */ 114*7c478bd9Sstevel@tonic-gate #define EX_OSFILE 72 /* critical OS file missing */ 115*7c478bd9Sstevel@tonic-gate #define EX_CANTCREAT 73 /* can't create (user) output file */ 116*7c478bd9Sstevel@tonic-gate #define EX_IOERR 74 /* input/output error */ 117*7c478bd9Sstevel@tonic-gate #define EX_TEMPFAIL 75 /* temp failure; user is invited to retry */ 118*7c478bd9Sstevel@tonic-gate #define EX_PROTOCOL 76 /* remote error in protocol */ 119*7c478bd9Sstevel@tonic-gate #define EX_NOPERM 77 /* permission denied */ 120*7c478bd9Sstevel@tonic-gate #define EX_CONFIG 78 /* configuration error */ 121*7c478bd9Sstevel@tonic-gate 122*7c478bd9Sstevel@tonic-gate #define EX_NOTFOUND 79 /* entry not found */ 123*7c478bd9Sstevel@tonic-gate #define EX__MAX 79 /* maximum listed value */ 124*7c478bd9Sstevel@tonic-gate 125*7c478bd9Sstevel@tonic-gate 126*7c478bd9Sstevel@tonic-gate #ifdef __cplusplus 127*7c478bd9Sstevel@tonic-gate } 128*7c478bd9Sstevel@tonic-gate #endif 129*7c478bd9Sstevel@tonic-gate 130*7c478bd9Sstevel@tonic-gate #endif /* _SYSEXITS_H */ 131