]> www.wagner.pp.ru Git - openssl-gost/engine.git/blobdiff - gost_crypt.c
Fixes of error codes. Check result of EC_POINT_mul
[openssl-gost/engine.git] / gost_crypt.c
index 668e881be38a1c7be8966336c2653a38c122ddba..52263953c0c31ec563ad8c657197144e25ab55ef 100644 (file)
@@ -464,8 +464,7 @@ int gost_cipher_ctl(EVP_CIPHER_CTX *ctx, int type, int arg, void *ptr)
     case EVP_CTRL_RAND_KEY:
         {
             if (RAND_bytes((unsigned char *)ptr, ctx->key_len) <= 0) {
-                GOSTerr(GOST_F_GOST_CIPHER_CTL,
-                        GOST_R_RANDOM_GENERATOR_ERROR);
+                GOSTerr(GOST_F_GOST_CIPHER_CTL, GOST_R_RNG_ERROR);
                 return -1;
             }
             break;