X-Git-Url: http://wagner.pp.ru/gitweb/?a=blobdiff_plain;f=test_keyexpimp.c;h=0e61b6f43c3d0453331416278ecdfbc9cdbdf61a;hb=97b3db1ebf985b73718faaae6c425782d526d44f;hp=7c40927cc9f03f91e36f009bc53a02e3263f4cbd;hpb=a90ad6ce8f4cd876b5a8897b66ef49fb50b378cd;p=openssl-gost%2Fengine.git diff --git a/test_keyexpimp.c b/test_keyexpimp.c index 7c40927..0e61b6f 100644 --- a/test_keyexpimp.c +++ b/test_keyexpimp.c @@ -4,7 +4,15 @@ * Contents licensed under the terms of the OpenSSL license * See https://www.openssl.org/source/license.html for details */ -#include +#ifdef _MSC_VER +# pragma warning(push, 3) +# include +# pragma warning(pop) +# include +# include +#else +# include +#endif #include #include #include @@ -15,9 +23,10 @@ #include "e_gost_err.h" #include "gost_grasshopper_cipher.h" -#define T(e) if (!(e)) {\ - ERR_print_errors_fp(stderr);\ - OpenSSLDie(__FILE__, __LINE__, #e);\ +#define T(e) \ + if (!(e)) { \ + ERR_print_errors_fp(stderr); \ + OpenSSLDie(__FILE__, __LINE__, #e); \ } static void hexdump(FILE *f, const char *title, const unsigned char *s, int l) @@ -103,7 +112,11 @@ int main(void) unsigned char tlsseq[8]; unsigned char out[32]; +#ifdef _MSC_VER + _putenv_s("OPENSSL_ENGINES", ENGINE_DIR); +#else setenv("OPENSSL_ENGINES", ENGINE_DIR, 0); +#endif OPENSSL_add_all_algorithms_conf(); ERR_load_crypto_strings(); ENGINE *eng;