diff options
author | Kenneth G Raeburn <raeburn@mit.edu> | 1991-03-28 22:23:16 +0000 |
---|---|---|
committer | Kenneth G Raeburn <raeburn@mit.edu> | 1991-03-28 22:23:16 +0000 |
commit | c1e3a57d3689446645b8a0389d8d74abe9a6cc22 (patch) | |
tree | c1e183d3db5743bd3fd025458f809e9c4418291c /h/zephyr | |
parent | f42b428b2e0d398ca959b4d4250d6c3ac1c4af52 (diff) |
Declare krb_err_base only if using Kerberos.
New Z_malloc variable and malloc macro are for NO_MALLOC_ZERO
(malloc(0) returns null) workaround.
Diffstat (limited to 'h/zephyr')
-rw-r--r-- | h/zephyr/zephyr_internal.h | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/h/zephyr/zephyr_internal.h b/h/zephyr/zephyr_internal.h index 2712ed0..265af55 100644 --- a/h/zephyr/zephyr_internal.h +++ b/h/zephyr/zephyr_internal.h @@ -80,17 +80,31 @@ extern ZSubscription_t *__subscriptions_list; extern int __subscriptions_num; extern int __subscriptions_next; +#ifdef Z_HaveKerberos extern int krb_err_base; +#endif + +#ifdef NO_MALLOC_ZERO +#ifdef __STDC__ +extern void * (*Z_malloc) (); +#else +extern char * (*Z_malloc) (); +#endif +#undef malloc +#define malloc(N) ((*Z_malloc)(N)) +#endif #ifdef __cplusplus extern "C" { #endif +#ifndef NO_MALLOC_ZERO #if defined(__STDC__) || defined(__cplusplus) extern void *malloc (unsigned); #else extern char *malloc(); #endif +#endif extern time_t time Zproto((time_t *)); extern long random(); |