--- libaitrpc/inc/defs.h 2011/08/29 22:37:06 1.3 +++ libaitrpc/inc/defs.h 2012/03/14 13:29:11 1.3.6.3 @@ -3,7 +3,7 @@ * by Michael Pounov * * $Author: misho $ -* $Id: defs.h,v 1.3 2011/08/29 22:37:06 misho Exp $ +* $Id: defs.h,v 1.3.6.3 2012/03/14 13:29:11 misho Exp $ * ************************************************************************** The ELWIX and AITNET software is distributed under the following @@ -12,7 +12,7 @@ terms: All of the documentation and software included in the ELWIX and AITNET Releases is copyrighted by ELWIX - Sofia/Bulgaria -Copyright 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011 +Copyright 2004, 2005, 2006, 2007, 2008, 2009, 2010, 2011, 2012 by Michael Pounov . All rights reserved. Redistribution and use in source and binary forms, with or without @@ -48,6 +48,7 @@ SUCH DAMAGE. #define DEF_RPC_TIMEOUT 3 +#define RPC_ERROR(x) htonl((x)) #define STRSIZ 256 @@ -59,6 +60,14 @@ SUCH DAMAGE. rpc_Errno = errno; \ strlcpy(rpc_Error, strerror(errno), STRSIZ); \ } while(0) + +#ifdef NDEBUG +#define FTRACE() +#define LOGGER() +#else +#define FTRACE() ioTRACE(0) +#define LOGGER(fmt, ...) ioLOGGER(LOG_NOTICE, (fmt), ## __VA_ARGS__) +#endif extern int rpc_Errno;