]> git.sur5r.net Git - openldap/blob - include/lber_types.nt
Silence warning in prev commit
[openldap] / include / lber_types.nt
1 /* $OpenLDAP$ */
2 /*
3  * Copyright 1998-2003 The OpenLDAP Foundation, Redwood City, California, USA
4  * All rights reserved.
5  *
6  * Redistribution and use in source and binary forms are permitted only
7  * as authorized by the OpenLDAP Public License.  A copy of this
8  * license is available at http://www.OpenLDAP.org/license.html or
9  * in file LICENSE in the top-level directory of the distribution.
10  */
11
12 /*
13  * LBER types for Windows NT (and Win32)
14  * copied by setup.mak to lber_types.h (when confingure is not used).
15  */
16
17 #ifndef _LBER_TYPES_H
18 #define _LBER_TYPES_H
19
20 #include <ldap_cdefs.h>
21
22 LDAP_BEGIN_DECL
23
24 /*
25  * NT types:
26  *
27  *      bitsof(short) == 2
28  *      bitsof(int)     == 4
29  *      bitsof(long) == 4       (or larger)
30  *
31  *  typedef unsigned int size_t;
32  *      typedef unsigned int SOCKET;
33  *
34  *      we use native C types to avoid sucking in system headers
35  */
36
37 /* LBER boolean, enum, integers - 32 bits or larger*/
38 #define LBER_INT_T      int
39
40 /* LBER tags - 32 bits or larger */
41 #define LBER_TAG_T      long
42
43 /* LBER socket descriptor */
44 #define LBER_SOCKET_T   unsigned int
45
46 /* LBER lengths - 32 bits or larger*/
47 #define LBER_LEN_T              long
48
49 /* ------------------------------------------------------------ */
50
51 /* booleans, enumerations, and integers */
52 typedef LBER_INT_T ber_int_t;
53
54 /* signed and unsigned versions */
55 typedef signed LBER_INT_T ber_sint_t;
56 typedef unsigned LBER_INT_T ber_uint_t;
57
58 /* tags */
59 typedef unsigned LBER_TAG_T ber_tag_t;
60
61 /* "socket" descriptors */
62 typedef LBER_SOCKET_T ber_socket_t;
63
64 /* lengths */
65 typedef unsigned LBER_LEN_T ber_len_t;
66
67 /* signed lengths */
68 typedef signed LBER_LEN_T ber_slen_t;
69
70 LDAP_END_DECL
71
72 #endif /* _LBER_TYPES_H */