From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 15069 invoked by alias); 14 Jul 2015 22:05:16 -0000 Mailing-List: contact glibc-bugs-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Post: List-Help: , Sender: glibc-bugs-owner@sourceware.org Received: (qmail 15012 invoked by uid 48); 14 Jul 2015 22:05:11 -0000 From: "rhollida at ciena dot com" To: glibc-bugs@sourceware.org Subject: [Bug network/18665] In send_dg, the recvfrom function is NOT always using the buffer size of a newly created buffer. Date: Tue, 14 Jul 2015 22:05:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: glibc X-Bugzilla-Component: network X-Bugzilla-Version: 2.20 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: rhollida at ciena dot com X-Bugzilla-Status: NEW X-Bugzilla-Resolution: X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: unassigned at sourceware dot org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: http://sourceware.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2015-07/txt/msg00107.txt.bz2 https://sourceware.org/bugzilla/show_bug.cgi?id=18665 --- Comment #5 from Robert --- I assume this is happening because this code was never sufficiently tested with large packets. I had done some statistics which show typical packet lengths received for DNS queries. Received packet lengths: 122, 128, 47, 80, 59, 73, 226, 50, 161 It looks like the code that allocates more buffer space starting on line 1271, is not used much, so probably does not get a lot of testing, because most of the time the default buffer of 2048 bytes is less than the largest packet I received of 161 bytes. -- You are receiving this mail because: You are on the CC list for the bug.