Only copy as much data as the provided buffer can hold. Continue to return
the length provided from recvfrom as per documentation.
Fixes lp#1023438. Thanks to Robert Uhl for the fix.
comparisons, particularly on almost-sorted inputs.
* bug fix: Reading floats with large exponents no longer takes too much time
before reporting that the exponent is too large.
+ * bug fix: SB-BSD-SOCKETS:SOCKET-RECEIVE with a UDP socket now works
+ correctly when the received datagram is larger than the provided buffer.
+ (lp#1023438, thanks to Robert Uhl)
* documentation: a section on random number generation has been added to the
manual. (lp#656839)
(list sockint::EAGAIN sockint::EINTR)))
nil)
((= len -1) (socket-error "recvfrom"))
- (t (loop for i from 0 below len
+ (t (loop for i from 0 below (min len length)
do (setf (elt buffer i)
(cond
((or (eql element-type 'character) (eql element-type 'base-char))