Date: Wed, 24 Aug 2016 20:04:38 +0000 From: bugzilla-noreply@freebsd.org To: freebsd-bugs@FreeBSD.org Subject: [Bug 212122] getaddrinfo doesn't implement sort rule 10 deterministically Message-ID: <bug-212122-8@https.bugs.freebsd.org/bugzilla/>
next in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=212122 Bug ID: 212122 Summary: getaddrinfo doesn't implement sort rule 10 deterministically Product: Base System Version: CURRENT Hardware: Any OS: Any Status: New Severity: Affects Many People Priority: --- Component: bin Assignee: freebsd-bugs@FreeBSD.org Reporter: Herbie.Robinson@stratus.com The formal behavior of qsort is unstable with regard to objects that are equal. Unfortunately, the standard requires that otherwise equal objects remain in the order supplied by the DNS server. The present code attempts to deal with this by returning -1 for objects that are equal (i.e., returns that the first parameter is less then the second parameter). Unfortunately, the qsort API does not state that the first parameter passed in is in any particular position in the list. Assuming I can get it uploaded, the patch I have for it will be against Revision 304034. Again, while this affects a lot or people, I don't think many will notice. It's been this way for years and I only just noticed... -- You are receiving this mail because: You are the assignee for the bug.
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-212122-8>
