Browse code

Fix compilation with --disable-lzo and --disable-lz4

struct compress_options is defined under USE_COMP, therefore
compilation fails when it is referenced without that define.

Since function show_compression_warning, which uses aforementioned
struct, is only called under USE_COMP, it is safe to wrap its definition
under USE_COMP, which fixes compilation issue.

Trac: #1308

Signed-off-by: Lev Stipakov <lstipakov@gmail.com>
Acked-by: Gert Doering <gert@greenie.muc.de>
Message-Id: <20200805062548.38082-1-lstipakov@gmail.com>
URL: https://www.mail-archive.com/openvpn-devel@lists.sourceforge.net/msg20637.html
Signed-off-by: Gert Doering <gert@greenie.muc.de>

Lev Stipakov authored on 2020/08/05 15:25:48
Showing 1 changed files
... ...
@@ -5085,6 +5085,7 @@ set_user_script(struct options *options,
5085 5085
 #endif
5086 5086
 }
5087 5087
 
5088
+#ifdef USE_COMP
5088 5089
 static void
5089 5090
 show_compression_warning(struct compress_options *info)
5090 5091
 {
... ...
@@ -5103,6 +5104,7 @@ show_compression_warning(struct compress_options *info)
5103 5103
         }
5104 5104
     }
5105 5105
 }
5106
+#endif
5106 5107
 
5107 5108
 static void
5108 5109
 add_option(struct options *options,