1258945Sroberto/* 2258945Sroberto * Copyright (C) 2004, 2007 Internet Systems Consortium, Inc. ("ISC") 3258945Sroberto * Copyright (C) 1999-2001 Internet Software Consortium. 4258945Sroberto * 5258945Sroberto * Permission to use, copy, modify, and/or distribute this software for any 6258945Sroberto * purpose with or without fee is hereby granted, provided that the above 7258945Sroberto * copyright notice and this permission notice appear in all copies. 8258945Sroberto * 9258945Sroberto * THE SOFTWARE IS PROVIDED "AS IS" AND ISC DISCLAIMS ALL WARRANTIES WITH 10258945Sroberto * REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY 11258945Sroberto * AND FITNESS. IN NO EVENT SHALL ISC BE LIABLE FOR ANY SPECIAL, DIRECT, 12258945Sroberto * INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM 13258945Sroberto * LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE 14258945Sroberto * OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR 15258945Sroberto * PERFORMANCE OF THIS SOFTWARE. 16258945Sroberto */ 17258945Sroberto 18258945Sroberto/* $Id: int.h,v 1.13 2007/06/19 23:47:20 tbox Exp $ */ 19258945Sroberto 20258945Sroberto#ifndef ISC_INT_H 21258945Sroberto#define ISC_INT_H 1 22258945Sroberto 23258945Sroberto#define _INTEGRAL_MAX_BITS 64 24258945Sroberto#include <limits.h> 25258945Sroberto 26258945Srobertotypedef __int8 isc_int8_t; 27258945Srobertotypedef unsigned __int8 isc_uint8_t; 28258945Srobertotypedef __int16 isc_int16_t; 29258945Srobertotypedef unsigned __int16 isc_uint16_t; 30258945Srobertotypedef __int32 isc_int32_t; 31258945Srobertotypedef unsigned __int32 isc_uint32_t; 32258945Srobertotypedef __int64 isc_int64_t; 33258945Srobertotypedef unsigned __int64 isc_uint64_t; 34258945Sroberto 35258945Sroberto#define ISC_INT8_MIN -128 36258945Sroberto#define ISC_INT8_MAX 127 37258945Sroberto#define ISC_UINT8_MAX 255 38258945Sroberto 39258945Sroberto#define ISC_INT16_MIN -32768 40258945Sroberto#define ISC_INT16_MAX 32767 41258945Sroberto#define ISC_UINT16_MAX 65535 42258945Sroberto 43258945Sroberto/* 44258945Sroberto * Note that "int" is 32 bits on all currently supported Unix-like operating 45258945Sroberto * systems, but "long" can be either 32 bits or 64 bits, thus the 32 bit 46258945Sroberto * constants are not qualified with "L". 47258945Sroberto */ 48258945Sroberto#define ISC_INT32_MIN _I32_MIN 49258945Sroberto#define ISC_INT32_MAX _I32_MAX 50258945Sroberto#define ISC_UINT32_MAX _UI32_MAX 51258945Sroberto 52258945Sroberto#define ISC_INT64_MIN _I64_MIN 53258945Sroberto#define ISC_INT64_MAX _I64_MAX 54258945Sroberto#define ISC_UINT64_MAX _UI64_MAX 55258945Sroberto 56258945Sroberto#endif /* ISC_INT_H */ 57