#define lcstring opr_lcstring
#define ucstring opr_ucstring
#define stolower opr_stolower
-#define stoupper opr_stoupper
/* XXX str* is in the implementation namespace when <string.h> is included */
#define strcompose opr_strcompose
extern char *opr_lcstring(char *d, const char *s, int n) AFS_NONNULL((1,2));
extern char *opr_ucstring(char *d, const char *s, int n) AFS_NONNULL((1,2));
extern void opr_stolower(char *s) AFS_NONNULL((1));
-extern void opr_stoupper(char *s) AFS_NONNULL((1));
extern char *opr_strcompose(char *buf, size_t len, ...) AFS_NONNULL((1));
/* threadname.c */
-#ifdef AFS_PTHREAD_ENV
+#if defined(AFS_PTHREAD_ENV) && !defined(AFS_NT40_ENV)
extern void opr_threadname_set(const char *threadname);
#else
static_inline void
}
#endif
+/* cache.c */
+
+struct opr_cache_opts {
+ afs_uint32 max_entries;
+ afs_uint32 n_buckets;
+};
+struct opr_cache;
+
+extern int opr_cache_init(struct opr_cache_opts *opts,
+ struct opr_cache **a_cache) AFS_NONNULL();
+extern void opr_cache_free(struct opr_cache **a_cache) AFS_NONNULL();
+
+extern int opr_cache_get(struct opr_cache *cache, void *key_buf,
+ size_t key_len, void *val_buf, size_t *a_val_len)
+ AFS_NONNULL((4,5));
+extern void opr_cache_put(struct opr_cache *cache, void *key_buf,
+ size_t key_len, void *val_buf, size_t val_len);
+
#endif