Index: ossp-pkg/rc/rc_private.h RCS File: /v/ossp/cvs/ossp-pkg/rc/rc_private.h,v rcsdiff -q -kk '-r1.1' '-r1.2' -u '/v/ossp/cvs/ossp-pkg/rc/rc_private.h,v' 2>/dev/null --- rc_private.h 2002/02/07 12:35:25 1.1 +++ rc_private.h 2002/02/11 12:34:29 1.2 @@ -27,13 +27,40 @@ ** rc_private.h: Run-command processor ISO C private API header file */ -#ifndef __OSSPRC_P_H__ -#define __OSSPRC_P_H__ +#ifndef __OSSPRC_PRIVATE_H__ +#define __OSSPRC_PRIVATE_H__ -#include "rc_config.h" +#ifdef HAVE_CONFIG_H +#include "ac_config.h" +#endif + +/* Assertion and tracing support */ +#include +#ifndef DEBUG +#define NDEBUG +#define TRACE(expr) ((void)0) +#else +#define TRACE(str) fprintf(stderr, "%s:%d: %s\n", __FILE__, __LINE__, str) +#endif -#ifdef HAVE_SYS_TIME_H /* must come after include rc_config.h */ -#include +/* Memory debugging support */ +#if defined(HAVE_DMALLOC_H) && defined(WITH_DMALLOC) +#include "dmalloc.h" #endif -#endif /* __OSSPRC_P_H__ */ +/* Define the ability to throw OSSP ex exceptions */ +#include "ex.h" /* OSSP ex exception handling library */ +#define RC_THROW(rv) \ + ( (rv) != RC_OK && (ex_catching && !ex_shielding) \ + ? (ex_throw(ossprc_id, NULL, (rv)), (rv)) : (rv)) + +#include "val.h" + + +/* Main rc configuration storage */ +typedef struct { + void *pvCtx; + val_t *pVal; +} rc_config_t; + +#endif /* __OSSPRC_PRIVATE_H__ */