* [Openvpn-devel] stray USE_SSL in crypto_openssl.c
@ 2013-04-14 10:07 Gert Doering
2013-04-15 9:55 ` Steffan Karger
0 siblings, 1 reply; 3+ messages in thread
From: Gert Doering @ 2013-04-14 10:07 UTC (permalink / raw)
To: openvpn-devel
[-- Attachment #1: Type: text/plain, Size: 944 bytes --]
Hi,
this is something for Adriaan or Steffan, I think... in crypto_openssl.c,
we have two stray uses of #ifdef USE_SSL...
void
crypto_init_lib (void)
{
#ifndef USE_SSL
#ifndef ENABLE_SMALL
ERR_load_crypto_strings ();
#endif
OpenSSL_add_all_algorithms ();
#endif
...
void
crypto_uninit_lib (void)
{
#ifndef USE_SSL
EVP_cleanup ();
#ifndef ENABLE_SMALL
ERR_free_strings ();
#endif
#endif
... should this be ENABLE_SSL? Or not be there at all?
I won't claim to understand the code, but I can say for sure that we
do not have a "USE_SSL" conditional anymore :-) - this is now ENABLE_SSL.
Please check and send patch :-)
gert
--
USENET is *not* the non-clickable part of WWW!
//www.muc.de/~gert/
Gert Doering - Munich, Germany gert@...1296...
fax: +49-89-35655025 gert@...1297...
[-- Attachment #2: Type: application/pgp-signature, Size: 305 bytes --]
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [Openvpn-devel] stray USE_SSL in crypto_openssl.c
2013-04-14 10:07 [Openvpn-devel] stray USE_SSL in crypto_openssl.c Gert Doering
@ 2013-04-15 9:55 ` Steffan Karger
2013-04-15 17:03 ` [Openvpn-devel] [PATCH applied] Re: Fixed usage of stale define USE_SSL to ENABLE_SSL Gert Doering
0 siblings, 1 reply; 3+ messages in thread
From: Steffan Karger @ 2013-04-15 9:55 UTC (permalink / raw)
To: openvpn-devel
[-- Attachment #1: Type: text/plain, Size: 889 bytes --]
Hi Gert,
On 04/14/2013 12:07 PM, Gert Doering wrote:
> this is something for Adriaan or Steffan, I think... in crypto_openssl.c,
> we have two stray uses of #ifdef USE_SSL...
>
> void
> crypto_init_lib (void)
> {
> #ifndef USE_SSL
> #ifndef ENABLE_SMALL
> ERR_load_crypto_strings ();
> #endif
> OpenSSL_add_all_algorithms ();
> #endif
>
> ...
> void
> crypto_uninit_lib (void)
> {
> #ifndef USE_SSL
> EVP_cleanup ();
> #ifndef ENABLE_SMALL
> ERR_free_strings ();
> #endif
> #endif
>
>
> ... should this be ENABLE_SSL? Or not be there at all?
It should indeed be ENABLE_SSL. The #ifndef confused me at first, so I
also added some comments to clarify.
> I won't claim to understand the code, but I can say for sure that we
> do not have a "USE_SSL" conditional anymore :-) - this is now ENABLE_SSL.
>
> Please check and send patch :-)
Yes sir ;) I attached the patch.
-Steffan
[-- Attachment #2: 0001-Fixed-usage-of-stale-define-USE_SSL-to-ENABLE_SSL.patch --]
[-- Type: text/x-patch, Size: 1905 bytes --]
From a4d045dd3acd78999371db8d87c320aa0d0669e5 Mon Sep 17 00:00:00 2001
From: Steffan Karger <steffan.karger@...1435...>
Date: Mon, 15 Apr 2013 10:45:28 +0200
Subject: [PATCH] Fixed usage of stale define USE_SSL to ENABLE_SSL
Signed-off-by: Steffan Karger <steffan.karger@...1435...>
---
doc/doxygen/openvpn.doxyfile | 2 +-
src/openvpn/crypto_openssl.c | 6 ++++--
2 files changed, 5 insertions(+), 3 deletions(-)
diff --git a/doc/doxygen/openvpn.doxyfile b/doc/doxygen/openvpn.doxyfile
index 5d87172..cf26c42 100644
--- a/doc/doxygen/openvpn.doxyfile
+++ b/doc/doxygen/openvpn.doxyfile
@@ -235,7 +235,7 @@ EXPAND_ONLY_PREDEF = NO
SEARCH_INCLUDES = YES
INCLUDE_PATH =
INCLUDE_FILE_PATTERNS =
-PREDEFINED = WIN32 NTLM USE_LZO ENABLE_FRAGMENT P2MP P2MP_SERVER USE_CRYPTO USE_SSL ENABLE_PLUGIN ENABLE_MANAGEMENT ENABLE_OCC HAVE_GETTIMEOFDAY
+PREDEFINED = WIN32 NTLM USE_LZO ENABLE_FRAGMENT P2MP P2MP_SERVER ENABLE_CRYPTO ENABLE_CRYPTO_OPENSSL ENABLE_SSL ENABLE_PLUGIN ENABLE_MANAGEMENT ENABLE_OCC HAVE_GETTIMEOFDAY
EXPAND_AS_DEFINED =
SKIP_FUNCTION_MACROS = YES
#---------------------------------------------------------------------------
diff --git a/src/openvpn/crypto_openssl.c b/src/openvpn/crypto_openssl.c
index 21d1762..1501bc8 100644
--- a/src/openvpn/crypto_openssl.c
+++ b/src/openvpn/crypto_openssl.c
@@ -194,7 +194,8 @@ crypto_init_lib_engine (const char *engine_name)
void
crypto_init_lib (void)
{
-#ifndef USE_SSL
+#ifndef ENABLE_SSL
+ /* If SSL is enabled init is taken care of in ssl_openssl.c */
#ifndef ENABLE_SMALL
ERR_load_crypto_strings ();
#endif
@@ -215,7 +216,8 @@ crypto_init_lib (void)
void
crypto_uninit_lib (void)
{
-#ifndef USE_SSL
+#ifndef ENABLE_SSL
+ /* If SSL is enabled cleanup is taken care of in ssl_openssl.c */
EVP_cleanup ();
#ifndef ENABLE_SMALL
ERR_free_strings ();
--
1.7.9.5
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [Openvpn-devel] [PATCH applied] Re: Fixed usage of stale define USE_SSL to ENABLE_SSL
2013-04-15 9:55 ` Steffan Karger
@ 2013-04-15 17:03 ` Gert Doering
0 siblings, 0 replies; 3+ messages in thread
From: Gert Doering @ 2013-04-15 17:03 UTC (permalink / raw)
To: Steffan Karger <steffan.karger@; +Cc: openvpn-devel
ACK (since this matches what I assumed it should be :-) - thanks for
the extra explanation).
Your patch has been applied to the master and release/2.3 branches.
commit 1d561d4eaebe8652768270b6373023177b8d706d (master)
commit eb16a92894b3d93c69b6f56a5b852c5089a5304f (master)
Author: Steffan Karger
Date: Mon Apr 15 10:45:28 2013 +0200
Fixed usage of stale define USE_SSL to ENABLE_SSL
Signed-off-by: Steffan Karger <steffan.karger@...1435...>
Acked-by: Gert Doering <gert@...1296...>
Message-Id: <516BCEA2.6000608@...1435...>
URL: http://article.gmane.org/gmane.network.openvpn.devel/7509
Signed-off-by: Gert Doering <gert@...1296...>
--
kind regards,
Gert Doering
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2013-04-15 17:03 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-04-14 10:07 [Openvpn-devel] stray USE_SSL in crypto_openssl.c Gert Doering
2013-04-15 9:55 ` Steffan Karger
2013-04-15 17:03 ` [Openvpn-devel] [PATCH applied] Re: Fixed usage of stale define USE_SSL to ENABLE_SSL Gert Doering
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.