xref: /freebsd/crypto/krb5/src/util/et/error_table.h (revision 7f2fe78b9dd5f51c821d771b63d2e096f6fd49e9)
1*7f2fe78bSCy Schubert /* -*- mode: c; c-basic-offset: 4; indent-tabs-mode: nil -*- */
2*7f2fe78bSCy Schubert /*
3*7f2fe78bSCy Schubert  * Copyright 1988 by the Student Information Processing Board of the
4*7f2fe78bSCy Schubert  * Massachusetts Institute of Technology.
5*7f2fe78bSCy Schubert  *
6*7f2fe78bSCy Schubert  * For copyright info, see mit-sipb-copyright.h.
7*7f2fe78bSCy Schubert  */
8*7f2fe78bSCy Schubert 
9*7f2fe78bSCy Schubert #ifndef _ET_H
10*7f2fe78bSCy Schubert 
11*7f2fe78bSCy Schubert #include <errno.h>
12*7f2fe78bSCy Schubert 
13*7f2fe78bSCy Schubert #define ET_EBUFSIZ 1024
14*7f2fe78bSCy Schubert 
15*7f2fe78bSCy Schubert struct et_list {
16*7f2fe78bSCy Schubert     struct et_list *next;
17*7f2fe78bSCy Schubert     const struct error_table *table;
18*7f2fe78bSCy Schubert };
19*7f2fe78bSCy Schubert 
20*7f2fe78bSCy Schubert #define ERRCODE_RANGE   8       /* # of bits to shift table number */
21*7f2fe78bSCy Schubert #define BITS_PER_CHAR   6       /* # bits to shift per character in name */
22*7f2fe78bSCy Schubert #define ERRCODE_MAX   0xFFFFFFFFUL      /* Mask for maximum error table */
23*7f2fe78bSCy Schubert 
24*7f2fe78bSCy Schubert const char *error_table_name(unsigned long);
25*7f2fe78bSCy Schubert const char *error_table_name_r(unsigned long, char *outbuf);
26*7f2fe78bSCy Schubert 
27*7f2fe78bSCy Schubert #include "k5-thread.h"
28*7f2fe78bSCy Schubert extern k5_mutex_t com_err_hook_lock;
29*7f2fe78bSCy Schubert int com_err_finish_init(void);
30*7f2fe78bSCy Schubert 
31*7f2fe78bSCy Schubert #define _ET_H
32*7f2fe78bSCy Schubert #endif
33