From a507bc0b4fa2428ae5ebec9fe145e8143289f3d0 Mon Sep 17 00:00:00 2001 From: Josh Blum Date: Wed, 14 Jul 2010 11:56:22 -0700 Subject: usrp2: disable buffer resize on platforms that cry about it --- host/lib/transport/udp_zero_copy_asio.cpp | 3 +++ 1 file changed, 3 insertions(+) (limited to 'host') diff --git a/host/lib/transport/udp_zero_copy_asio.cpp b/host/lib/transport/udp_zero_copy_asio.cpp index 98451f188..bfbcf62d8 100644 --- a/host/lib/transport/udp_zero_copy_asio.cpp +++ b/host/lib/transport/udp_zero_copy_asio.cpp @@ -161,10 +161,13 @@ template static void resize_buff_helper( ) % name % MIN_SOCK_BUFF_SIZE << std::endl; } + //only enable on platforms that are happy with the large buffer resize + #if defined(UHD_PLATFORM_LINUX) || defined(UHD_PLATFORM_WIN32) //otherwise, ensure that the buffer is at least the minimum size else if (udp_trans->get_buff_size() < MIN_SOCK_BUFF_SIZE){ resize_buff_helper(udp_trans, MIN_SOCK_BUFF_SIZE, name); } + #endif /*defined(UHD_PLATFORM_LINUX) || defined(UHD_PLATFORM_WIN32)*/ } udp_zero_copy::sptr udp_zero_copy::make( -- cgit v1.2.3