Various Win32 and other fixes for warnings and compilation errors.
authorDr. Stephen Henson <steve@openssl.org>
Tue, 19 Apr 2005 00:12:36 +0000 (00:12 +0000)
committerDr. Stephen Henson <steve@openssl.org>
Tue, 19 Apr 2005 00:12:36 +0000 (00:12 +0000)
Fix Win32 build system to use 'Makefile' instead of 'Makefile.ssl'.

apps/apps.c
apps/apps.h
crypto/pem/pem_info.c
crypto/rand/rand_win.c
crypto/stack/safestack.h
crypto/x509/x509_vfy.c
util/mk1mf.pl
util/mkfiles.pl

index 988bb6e9417aae79e58eef7f7ccc47d42a619fb4..fb9f72fbea8ab779417c329f730dce43eb277da0 100644 (file)
@@ -2146,7 +2146,7 @@ error:
 
 /* This code MUST COME AFTER anything that uses rename() */
 #ifdef OPENSSL_SYS_WIN32
 
 /* This code MUST COME AFTER anything that uses rename() */
 #ifdef OPENSSL_SYS_WIN32
-int WIN32_rename(char *from, char *to)
+int WIN32_rename(const char *from, const char *to)
        {
 #ifndef OPENSSL_SYS_WINCE
        /* Windows rename gives an error if 'to' exists, so delete it
        {
 #ifndef OPENSSL_SYS_WINCE
        /* Windows rename gives an error if 'to' exists, so delete it
index b9bb91c1862565da61dfedc9842b835d65c1fe29..26dcbc5771d5ca1888830468e6d8c66fbcf8fd18 100644 (file)
@@ -136,7 +136,7 @@ long app_RAND_load_files(char *file); /* `file' is a list of files to read,
 
 #ifdef OPENSSL_SYS_WIN32
 #define rename(from,to) WIN32_rename((from),(to))
 
 #ifdef OPENSSL_SYS_WIN32
 #define rename(from,to) WIN32_rename((from),(to))
-int WIN32_rename(char *oldname,char *newname);
+int WIN32_rename(const char *oldname,const char *newname);
 #endif
 
 #ifndef MONOLITH
 #endif
 
 #ifndef MONOLITH
index 14e0643129392b0580e6b5053b7c416c03d16ebf..870e102651b951faeb95d1b081a58a9e28f6aaa9 100644 (file)
@@ -186,7 +186,7 @@ start:
 #ifndef OPENSSL_NO_DSA
                        if (strcmp(name,PEM_STRING_DSA) == 0)
                        {
 #ifndef OPENSSL_NO_DSA
                        if (strcmp(name,PEM_STRING_DSA) == 0)
                        {
-                       (D2I_OF(RSA))d2i=d2i_DSAPrivateKey;
+                       (D2I_OF(DSA))d2i=d2i_DSAPrivateKey;
                        if (xi->x_pkey != NULL) 
                                {
                                if (!sk_X509_INFO_push(ret,xi)) goto err;
                        if (xi->x_pkey != NULL) 
                                {
                                if (!sk_X509_INFO_push(ret,xi)) goto err;
index 29472c6ddd1194c88ab8da30025fa788816e1393..39523d3005a7da238006795585d6b4d92308ea7d 100644 (file)
@@ -558,7 +558,8 @@ int RAND_poll(void)
                        if (module_first(handle, &m))
                                do
                                        RAND_add(&m, m.dwSize, 9);
                        if (module_first(handle, &m))
                                do
                                        RAND_add(&m, m.dwSize, 9);
-                               while (module_next(handle, &m) && GetTickCount < stoptime);
+                               while (module_next(handle, &m)
+                                               && (GetTickCount() < stoptime));
                        if (close_snap)
                                close_snap(handle);
                        else
                        if (close_snap)
                                close_snap(handle);
                        else
index b50149dd96cd5bc9894912025a115ec01001f726..3167e3ec6ea426cc7eea1ae847c550e55aee297c 100644 (file)
@@ -194,14 +194,14 @@ STACK_OF(type) \
        sk_is_sorted(st)
 
 #define        SKM_ASN1_SET_OF_d2i(type, st, pp, length, d2i_func, free_func, ex_tag, ex_class) \
        sk_is_sorted(st)
 
 #define        SKM_ASN1_SET_OF_d2i(type, st, pp, length, d2i_func, free_func, ex_tag, ex_class) \
-       d2i_ASN1_SET(st,pp,length, (char *(*)())d2i_func, (void (*)(void *))free_func, ex_tag,ex_class)
+       d2i_ASN1_SET(st,pp,length, (char *(*)(void ** ,const unsigned char ** ,long))d2i_func, (void (*)(void *))free_func, ex_tag,ex_class)
 #define        SKM_ASN1_SET_OF_i2d(type, st, pp, i2d_func, ex_tag, ex_class, is_set) \
        i2d_ASN1_SET(st,pp,i2d_func,ex_tag,ex_class,is_set)
 
 #define        SKM_ASN1_seq_pack(type, st, i2d_func, buf, len) \
        ASN1_seq_pack(st, i2d_func, buf, len)
 #define        SKM_ASN1_seq_unpack(type, buf, len, d2i_func, free_func) \
 #define        SKM_ASN1_SET_OF_i2d(type, st, pp, i2d_func, ex_tag, ex_class, is_set) \
        i2d_ASN1_SET(st,pp,i2d_func,ex_tag,ex_class,is_set)
 
 #define        SKM_ASN1_seq_pack(type, st, i2d_func, buf, len) \
        ASN1_seq_pack(st, i2d_func, buf, len)
 #define        SKM_ASN1_seq_unpack(type, buf, len, d2i_func, free_func) \
-       ASN1_seq_unpack(buf,len,(char *(*)(void *,unsigned char **,long))d2i_func, (void(*)(void *))free_func)
+       ASN1_seq_unpack(buf,len,(char *(*)(void *,const unsigned char **,long))d2i_func, (void(*)(void *))free_func)
 
 #define SKM_PKCS12_decrypt_d2i(type, algor, d2i_func, free_func, pass, passlen, oct, seq) \
        ((STACK *)PKCS12_decrypt_d2i(algor,(char *(*)())d2i_func, (void(*)(void *))free_func,pass,passlen,oct,seq))
 
 #define SKM_PKCS12_decrypt_d2i(type, algor, d2i_func, free_func, pass, passlen, oct, seq) \
        ((STACK *)PKCS12_decrypt_d2i(algor,(char *(*)())d2i_func, (void(*)(void *))free_func,pass,passlen,oct,seq))
index 6fdc35a617922663d553ea384c75028163fac390..4a30827c83060fb8cd82e8f7ba7d2ce5017bce6b 100644 (file)
@@ -390,7 +390,8 @@ static int check_chain_extensions(X509_STORE_CTX *ctx)
        X509 *x;
        int (*cb)(int ok,X509_STORE_CTX *ctx);
        int proxy_path_length = 0;
        X509 *x;
        int (*cb)(int ok,X509_STORE_CTX *ctx);
        int proxy_path_length = 0;
-       int allow_proxy_certs = !!(ctx->flags & X509_V_FLAG_ALLOW_PROXY_CERTS);
+       int allow_proxy_certs =
+               !!(ctx->param->flags & X509_V_FLAG_ALLOW_PROXY_CERTS);
        cb=ctx->verify_cb;
 
        /* must_be_ca can have 1 of 3 values:
        cb=ctx->verify_cb;
 
        /* must_be_ca can have 1 of 3 values:
index 15813461f0767898a1cdbd06b783e4107705f796..202371c9da41d1becce909c3013dd61b149dc469 100755 (executable)
@@ -10,7 +10,7 @@ $OPTIONS="";
 $ssl_version="";
 $banner="\t\@echo Building OpenSSL";
 
 $ssl_version="";
 $banner="\t\@echo Building OpenSSL";
 
-open(IN,"<Makefile.ssl") || die "unable to open Makefile.ssl!\n";
+open(IN,"<Makefile") || die "unable to open Makefile!\n";
 while(<IN>) {
     $ssl_version=$1 if (/^VERSION=(.*)$/);
     $OPTIONS=$1 if (/^OPTIONS=(.*)$/);
 while(<IN>) {
     $ssl_version=$1 if (/^VERSION=(.*)$/);
     $OPTIONS=$1 if (/^OPTIONS=(.*)$/);
index d8cac3a3b43520ec8e1c5d5382d171ad8ac64669..f0daaecde7b512a646279e6b25910a697a65c871 100755 (executable)
@@ -62,7 +62,7 @@ my @dirs = (
 );
 
 foreach (@dirs) {
 );
 
 foreach (@dirs) {
-       &files_dir ($_, "Makefile.ssl");
+       &files_dir ($_, "Makefile");
 }
 
 exit(0);
 }
 
 exit(0);