]> The Tcpdump Group git mirrors - tcpdump/commitdiff
finalize the evp.h bugfix (#46)
authorDenis Ovsienko <[email protected]>
Sun, 9 Jun 2013 08:26:04 +0000 (12:26 +0400)
committerDenis Ovsienko <[email protected]>
Sun, 9 Jun 2013 08:26:04 +0000 (12:26 +0400)
print-esp.c
print-isakmp.c

index 0bb5cdd16ec12fdf149d44d6d8d5e71bce811430..5e8f282cc1f1c5d4dcb24eaa63a5bfd8248cddd1 100644 (file)
@@ -36,6 +36,10 @@ static const char rcsid[] _U_ =
 
 #include <stdlib.h>
 
+/* Any code in this file that depends on HAVE_LIBCRYPTO depends on
+ * HAVE_OPENSSL_EVP_H too. Undefining the former when the latter isn't defined
+ * is the simplest way of handling the dependency.
+ */
 #ifdef HAVE_LIBCRYPTO
 #ifdef HAVE_OPENSSL_EVP_H
 #include <openssl/evp.h>
index 4f96afe38115032fc2b753261e055c5d2d1c1db1..ee82f5b75b3648ba150acb73d34385db67b6bbf6 100644 (file)
@@ -38,6 +38,13 @@ static const char rcsid[] _U_ =
 #include "config.h"
 #endif
 
+/* The functions from print-esp.c used in this file are only defined when both
+ * OpenSSL and evp.h are detected. Employ the same preprocessor device here.
+ */
+#ifndef HAVE_OPENSSL_EVP_H
+#undef HAVE_LIBCRYPTO
+#endif
+
 #include <tcpdump-stdinc.h>
 
 #include <string.h>