xref: /illumos-gate/usr/src/lib/krb5/dyn/dynP.h (revision 201ceb75ab95f9bf1f42ea1dc9ab363b43ba47cf)
1 /*
2  * Copyright (c) 1997-2000 by Sun Microsystems, Inc.
3  * All rights reserved.
4  */
5 
6 #ifndef _KRB5_DYN_DYNP_H
7 #define	_KRB5_DYN_DYNP_H
8 
9 #ifdef	__cplusplus
10 extern "C" {
11 #endif
12 
13 
14 /*
15  * This file is part of libdyn.a, the C Dynamic Object library.  It
16  * contains the private header file.
17  *
18  * There are no restrictions on this code; however, if you make any
19  * changes, I request that you document them so that I do not get
20  * credit or blame for your modifications.
21  *
22  * Written by Barr3y Jaspan, Student Information Processing Board (SIPB)
23  * and MIT-Project Athena, 1989.
24  */
25 
26 
27 /*
28  * dynP.h -- private header file included by source files for libdyn.a.
29  */
30 
31 
32 #include "dyn.h"
33 #ifdef USE_DBMALLOC
34 #include <sys/stdtypes.h>
35 #include <malloc.h>
36 #endif
37 
38 /*
39  * Rep invariant:
40  * 1) el_size is the number of bytes per element in the object
41  * 2) num_el is the number of elements currently in the object.  It is
42  * one higher than the highest index at which an element lives.
43  * 3) size is the number of elements the object can hold without
44  * resizing.  num_el <= index.
45  * 4) inc is a multiple of the number of elements the object grows by
46  * each time it is reallocated.
47  */
48 
49 typedef struct _DynObject DynObjectRecP, *DynObjectP;
50 
51 /* Internal functions */
52 int _DynRealloc(), _DynResize();
53 
54 /*
55  * N.B. The original code had the following comment line after that last #endif:
56  * DON'T ADD STUFF AFTER THIS #endif *
57  * Ignoring the fact that this line itself was after the #endif, the line
58  * caused unacceptable hdrchk breakage. If this results in a build breakage,
59  * the build MUST be fixed in a more acceptable fashion.
60  */
61 
62 #ifdef	__cplusplus
63 }
64 #endif
65 
66 #endif	/* !_KRB5_DYN_DYNP_H */
67