Browse Source

seafile-ccnet: fixed deprecated API patch

RSA key generation failure check was backwards.

Signed-off-by: Eneas U de Queiroz <cote2004-github@yahoo.com>
lilik-openwrt-22.03
Eneas U de Queiroz 7 years ago
parent
commit
c5012d6788
1 changed files with 5 additions and 5 deletions
  1. +5
    -5
      net/seafile-ccnet/patches/020-Remove-API-deprecated-in-openssl-1.1.patch

+ 5
- 5
net/seafile-ccnet/patches/020-Remove-API-deprecated-in-openssl-1.1.patch View File

@ -46,14 +46,14 @@ index 7cca150..23abb82 100644
+ private = RSA_new();
+ e = BN_new();
+ if (private == NULL || e == NULL || !BN_set_word(e, 35) ||
+ !RSA_generate_key_ex(private, bits, e, NULL)) {
+ !RSA_generate_key_ex(private, bits, e, NULL)) {
+ RSA_free(private);
+ BN_free(e);
+ return private;
+ g_error ("rsa_generate_private_key: key generation failed.");
+ return NULL;
+ }
+ BN_free(e);
+ RSA_free(private);
+ g_error ("rsa_generate_private_key: key generation failed.");
+ return NULL;
+ return private;
}
diff --git a/net/common/processors/keepalive-proc.c b/net/common/processors/keepalive-proc.c
index 609d102..42a0c23 100644


Loading…
Cancel
Save