This is an automated email from the ASF dual-hosted git repository. markt pushed a commit to branch main in repository https://gitbox.apache.org/repos/asf/tomcat-native.git
commit f9ae977f674bcb44d0cc1334646860ae9dc6fb72 Author: Mark Thomas <ma...@apache.org> AuthorDate: Fri Sep 29 10:02:33 2023 +0100 Remove unused function --- native/src/ssl.c | 39 --------------------------------------- 1 file changed, 39 deletions(-) diff --git a/native/src/ssl.c b/native/src/ssl.c index 9b91d57d7..6dd202b0c 100644 --- a/native/src/ssl.c +++ b/native/src/ssl.c @@ -281,45 +281,6 @@ int SSL_rand_seed(const char *file) return RAND_status(); } -static int ssl_rand_make(const char *file, int len, int base64) -{ - int r; - int num = len; - BIO *out = NULL; - - out = BIO_new(BIO_s_file()); - if (out == NULL) - return 0; - if ((r = BIO_write_filename(out, (char *)file)) < 0) { - BIO_free_all(out); - return 0; - } - if (base64) { - BIO *b64 = BIO_new(BIO_f_base64()); - if (b64 == NULL) { - BIO_free_all(out); - return 0; - } - out = BIO_push(b64, out); - } - while (num > 0) { - unsigned char buf[4096]; - int len = num; - if (len > sizeof(buf)) - len = sizeof(buf); - r = RAND_bytes(buf, len); - if (r <= 0) { - BIO_free_all(out); - return 0; - } - BIO_write(out, buf, len); - num -= len; - } - r = BIO_flush(out); - BIO_free_all(out); - return r > 0 ? 1 : 0; -} - TCN_IMPLEMENT_CALL(jint, SSL, initialize)(TCN_STDARGS, jstring engine) { jclass clazz; --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org