More evil cast removal.
[openssl.git] / crypto / dh / dh.h
index 5431725b8da1ba98fea4f4702357d4eb1c09f9ab..affafd256bb1d206a26a5df33dfbf95e167ae6ac 100644 (file)
 extern "C" {
 #endif
 
-#include "bn.h"
+#ifdef NO_DH
+#error DH is disabled.
+#endif
+
+#include <openssl/bn.h>
        
 #define DH_FLAG_CACHE_MONT_P   0x01
 
@@ -104,12 +108,11 @@ typedef struct dh_st
 #define i2d_DHparams_bio(bp,x) ASN1_i2d_bio(i2d_DHparams,(bp), \
                (unsigned char *)(x))
 
-#ifndef NOPROTO
 DH *   DH_new(void);
 void   DH_free(DH *dh);
 int    DH_size(DH *dh);
 DH *   DH_generate_parameters(int prime_len,int generator,
-               void (*callback)(int,int,char *),char *cb_arg);
+               void (*callback)(int,int,void *),void *cb_arg);
 int    DH_check(DH *dh,int *codes);
 int    DH_generate_key(DH *dh);
 int    DH_compute_key(unsigned char *key,BIGNUM *pub_key,DH *dh);
@@ -125,26 +128,11 @@ int       DHparams_print(char *bp, DH *x);
 #endif
 void   ERR_load_DH_strings(void );
 
-#else
-
-DH *   DH_new();
-void   DH_free();
-int    DH_size();
-DH *   DH_generate_parameters();
-int    DH_check();
-int    DH_generate_key();
-int    DH_compute_key();
-DH *   d2i_DHparams();
-int    i2d_DHparams();
-#ifndef NO_FP_API
-int    DHparams_print_fp();
-#endif
-int    DHparams_print();
-void   ERR_load_DH_strings();
-
-#endif
-
 /* BEGIN ERROR CODES */
+/* The following lines are auto generated by the script mkerr.pl. Any changes
+ * made after this point may be overwritten when the script is next run.
+ */
+
 /* Error codes for the DH functions. */
 
 /* Function codes. */
@@ -157,7 +145,7 @@ void        ERR_load_DH_strings();
 
 /* Reason codes. */
 #define DH_R_NO_PRIVATE_VALUE                           100
+
 #ifdef  __cplusplus
 }
 #endif