libc: Sorting is not needed when there are less than two elements
If there are less than two elements avoid executing the first
sorting loop. No functional change intended.
Reviewed by: kib@
Sponsored by: NVIDIA Networking
Differential Revision: https://reviews.freebsd.org/D39691
(cherry picked from commit ecb2ce3a51e9b09a57cd42262fc798ae089c0758)