/**************************************************************************** | | (C) Copyright 1985, 1991, 1993, 1996 Novell, Inc. | All Rights Reserved. | | This program is free software; you can redistribute it and/or | modify it under the terms of version 2 of the GNU General Public | License as published by the Free Software Foundation. | | This program is distributed in the hope that it will be useful, | but WITHOUT ANY WARRANTY; without even the implied warranty of | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | GNU General Public License for more details. | | You should have received a copy of the GNU General Public License | along with this program; if not, contact Novell, Inc. | | To contact Novell about this file by physical or electronic mail, | you may find current contact information at www.novell.com | |*************************************************************************** | | NetWare Advance File Services (NSS) module | |--------------------------------------------------------------------------- | | $Author: taysom $ | $Date: 2004-12-31 01:10:58 +0530 (Fri, 31 Dec 2004) $ | | $RCSfile$ | $Revision: 465 $ | |--------------------------------------------------------------------------- | This module is used to: | NSS Library Routine | | WARNING! WARNING! WARNING! WARNING! WARNING! WARNING! WARNING! WARNING! | | This header file should ONLY be used for NSS internal development. | This includes Semantic Agents (SA) and Loadable Storage Services (LSS). | Any other use may cause conflicts which NSS will NOT fix. +-------------------------------------------------------------------------*/ #ifndef _NSS_STDLIB_H_ #define _NSS_STDLIB_H_ #if defined(__linux__) && !defined(__KERNEL__) && !defined(NSS_USERSPACE) #include #else // #ifdef linux #ifndef _XSTDLIB_H_ #include #endif #ifdef __cplusplus extern "C" { #endif #define atoi(p1) LB_atoi(p1) #define atol(p1) LB_atol(p1) #define atoq(p1) LB_atoq(p1) #define itoa(p1,p2,p3) LB_itoa(p1,p2,p3) #define utoa(p1,p2,p3) LB_utoa(p1,p2,p3) #define free(p1) LB_free(p1) #define malloc(p1) LB_malloc(p1) #define realloc(p1,p2) LB_realloc(p1,p2) #define strtol(p1,p2,p3) LB_strtol(p1,p2,p3) #define strtoul(p1,p2,p3) LB_strtoul(p1,p2,p3) /*------------------------------ QUAD Routines -----------------------------*/ #define strtoq(p1,p2,p3) LB_strtoq(p1,p2,p3) #define strtouq(p1,p2,p3) LB_strtouq(p1,p2,p3) /*------------------------------ RAND Routines -----------------------------*/ #define rand() LB_rand() #define srand(p1) LB_srand(p1) #define random() LB_random() #define srandom(p1) LB_srandom(p1) /*------------------------------ NSS Routines -----------------------------*/ #define zalloc(p1) LB_zalloc(p1) #define zallocPage(p1) LB_zallocPage(p1) #define mallocPage(p1) LB_mallocPage(p1) #define mallocPageWithFlags(p1,p2) LB_mallocPageWithFlags(p1,p2) #define mallocWithFlags(p1,p2) LB_mallocWithFlags(p1,p2) #define freePage(p1,p2) LB_freePage(p1,p2) #define zrealloc(p1,p2) LB_zrealloc(p1,p2) #define mallocForNCPReply(p1) LB_mallocForNCPReply(p1) #define freeForNCPReply(p1) LB_freeForNCPReply(p1) /*------------------------------ Non-Standard Routines --------------------*/ // Use zMIN and zMAX as these will conflict with Linux header files //#ifndef min //#define min(a, b) (((a) < (b)) ? (a) : (b)) //#endif //#ifndef max //#define max(a, b) (((a) > (b)) ? (a) : (b)) //#endif /*------------------------------ Exported by Others ----------------------*/ extern int atexit(void(*)(void)); #ifdef __cplusplus } #endif #endif // #else #ifdef linux #endif /* _NSS_STDLIB_H_ */