mirror of
https://github.com/asterisk/asterisk.git
synced 2025-09-05 20:20:07 +00:00
use a configure script test for PMTU discovery control instead of just assuming it's available on Linux
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@45027 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
@@ -987,10 +987,10 @@ int ast_dynamic_str_thread_build_va(struct ast_dynamic_str **buf, size_t max_len
|
||||
|
||||
void ast_enable_packet_fragmentation(int sock)
|
||||
{
|
||||
#ifdef __linux__
|
||||
#if defined(HAVE_IP_MTU_DISCOVER)
|
||||
int val = IP_PMTUDISC_DONT;
|
||||
|
||||
if (setsockopt(sock, IPPROTO_IP, IP_MTU_DISCOVER, &val, sizeof(val)))
|
||||
ast_log(LOG_WARNING, "Unable to disable PMTU discovery. Large UDP packets may fail to be delivered when sent from this socket.\n");
|
||||
#endif
|
||||
#endif /* HAVE_IP_MTU_DISCOVER */
|
||||
}
|
||||
|
Reference in New Issue
Block a user