You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

36 lines
1.2 KiB

  1. From 77fe5635037ebaf411cae46cf5045ca819b5c145 Mon Sep 17 00:00:00 2001
  2. From: Zdenek Styblik <stybla@turnovfree.net>
  3. Date: Sun, 15 Jan 2017 15:11:25 +0100
  4. Subject: [PATCH 2/4] ID:461 - Make compiler happier about changes related to
  5. OpenSSL 1.1
  6. Complaint was that ctx isn't initialized.
  7. ---
  8. src/plugins/lanplus/lanplus_crypt_impl.c | 4 ++--
  9. 1 file changed, 2 insertions(+), 2 deletions(-)
  10. diff --git a/src/plugins/lanplus/lanplus_crypt_impl.c b/src/plugins/lanplus/lanplus_crypt_impl.c
  11. index 3c0df23..d12d0e3 100644
  12. --- a/src/plugins/lanplus/lanplus_crypt_impl.c
  13. +++ b/src/plugins/lanplus/lanplus_crypt_impl.c
  14. @@ -164,7 +164,7 @@ lanplus_encrypt_aes_cbc_128(const uint8_t * iv,
  15. uint8_t * output,
  16. uint32_t * bytes_written)
  17. {
  18. - EVP_CIPHER_CTX* ctx;
  19. + EVP_CIPHER_CTX *ctx = NULL;
  20. EVP_CIPHER_CTX_init(ctx);
  21. EVP_EncryptInit_ex(ctx, EVP_aes_128_cbc(), NULL, key, iv);
  22. EVP_CIPHER_CTX_set_padding(ctx, 0);
  23. @@ -239,7 +239,7 @@ lanplus_decrypt_aes_cbc_128(const uint8_t * iv,
  24. uint8_t * output,
  25. uint32_t * bytes_written)
  26. {
  27. - EVP_CIPHER_CTX* ctx;
  28. + EVP_CIPHER_CTX *ctx = NULL;
  29. EVP_CIPHER_CTX_init(ctx);
  30. EVP_DecryptInit_ex(ctx, EVP_aes_128_cbc(), NULL, key, iv);
  31. EVP_CIPHER_CTX_set_padding(ctx, 0);
  32. --
  33. 2.16.1