File:  [Research Unix] / researchv10no / cmd / odist / pax / include / error.h
Revision 1.1.1.1 (vendor branch): download - view: text, annotated - select for diffs
Tue Apr 24 17:21:35 2018 UTC (8 years, 1 month ago) by root
Branches: belllabs, MAIN
CVS tags: researchv10, HEAD
researchv10 Norman

/*
 * G. S. Fowler
 * AT&T Bell Laboratories
 *
 * option, error and message formatter external definitions
 */

#ifndef ERROR_INFO

#include <option.h>
#include <errno.h>

#ifndef VOID
#define VOID	char
#endif

#define ERROR_INFO	0		/* info message -- no err_id	*/
#define ERROR_WARNING	1		/* warning message		*/
#define ERROR_ERROR	2		/* error message -- no err_exit	*/
#define ERROR_FATAL	3		/* error message with err_exit	*/
#define ERROR_PANIC	ERROR_LEVEL	/* panic message with err_exit	*/

#define ERROR_LEVEL	000077		/* level portion of status	*/
#define ERROR_SYSTEM	000100		/* report system errno message	*/
#define ERROR_OUTPUT	000200		/* next arg is error fd		*/
#define ERROR_SOURCE	000400		/* next 2 args are FILE,LINE	*/
#define ERROR_USAGE	001000		/* usage message		*/
#define ERROR_PROMPT	002000		/* omit trailing newline	*/
#define ERROR_NOID	004000		/* omit err_id			*/
#define ERROR_LIBRARY	010000		/* library routine error	*/

#if __cplusplus
extern "C" {
#endif

extern int	errno;			/* system call error status	*/

#if __cplusplus
}
#endif

#if __STDC__ || __cplusplus || c_plusplus
#include <stdarg.h>
#if __cplusplus
extern "C" {
#endif
extern char*	seterror(int, ...);
extern void	error(int, ...);
extern void	liberror(const char*, int, ...);
extern void	verror(const char*, int, va_list);
#if __cplusplus
}
#endif
#else
extern char*	seterror();
extern void	error();
extern void	liberror();
extern void	verror();
#endif

#endif

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.