]> granicus.if.org Git - openssl/commitdiff
Fix compilation failure for some tool chains
authorMatt Caswell <matt@openssl.org>
Tue, 2 Jun 2015 19:18:05 +0000 (20:18 +0100)
committerMatt Caswell <matt@openssl.org>
Tue, 2 Jun 2015 22:35:28 +0000 (23:35 +0100)
Some tool chains (e.g. android) do not define IP_PMTUDISC_PROBE, and so
this build breaks.

Reviewed-by: Tim Hudson <tjh@openssl.org>
crypto/bio/bss_dgram.c

index 7cd57bf5e479e8658084d2ec282480a0c05a43e4..3f6cd50db75723f5423ac02dd524e6c7784456bd 100644 (file)
@@ -882,7 +882,7 @@ static long dgram_ctrl(BIO *b, int cmd, long num, void *ptr)
                 perror("setsockopt");
                 ret = -1;
             }
-# elif defined(OPENSSL_SYS_LINUX) && defined(IP_MTU_DISCOVER)
+# elif defined(OPENSSL_SYS_LINUX) && defined(IP_MTU_DISCOVER) && defined (IP_PMTUDISC_PROBE)
             if ((sockopt_val = num ? IP_PMTUDISC_PROBE : IP_PMTUDISC_DONT),
                 (ret = setsockopt(b->num, IPPROTO_IP, IP_MTU_DISCOVER,
                                   &sockopt_val, sizeof(sockopt_val))) < 0) {