#define CRYPTO_add(a,b,c) ((*(a))+=(b))
#endif
+/* Some applications as well as some parts of OpenSSL need to allocate
+ and deallocate locks in a dynamic fashion. The following typedef
+ makes this possible in a type-safe manner. */
+typedef struct CRYPTO_dynlock_value CRYPTO_dynlock;
+
+
/* The following can be used to detect memory leaks in the SSLeay library.
* It used, it turns on malloc checking */
const char *CRYPTO_get_lock_name(int type);
int CRYPTO_add_lock(int *pointer,int amount,int type, const char *file,
int line);
+void CRYPTO_set_dynlock_create_callback(CRYPTO_dynlock *(*dyn_create_function)
+ (char *file, int line));
+void CRYPTO_set_dynlock_lock_callback(void (*dyn_lock_function)
+ (int mode, CRYPTO_dynlock *l, const char *file, int line));
+void CRYPTO_set_dynlock_destroy_callback(void (*dyn_destroy_function)
+ (CRYPTO_dynlock *l, const char *file, int line));
+void CRYPTO_set_dynlock_size(int dynlock_size);
+int CRYPTO_get_new_dynlockid(void);
+void CRYPTO_destroy_dynlockid(int i);
+CRYPTO_dynlock *CRYPTO_get_dynlock_value(int i);
/* CRYPTO_set_mem_functions includes CRYPTO_set_locked_mem_functions --
* call the latter last if you need different functions */
/* Function codes. */
#define CRYPTO_F_CRYPTO_GET_EX_NEW_INDEX 100
+#define CRYPTO_F_CRYPTO_GET_NEW_DYNLOCKID 103
#define CRYPTO_F_CRYPTO_GET_NEW_LOCKID 101
#define CRYPTO_F_CRYPTO_SET_EX_DATA 102
/* Reason codes. */
+#define CRYPTO_R_NO_DYNLOCK_CREATE_CALLBACK 100
#ifdef __cplusplus
}
#endif
#endif
+