• Vakul Garg's avatar
    selftests/tls: Fix recv(MSG_PEEK) & splice() test cases · 0ed3015c
    Vakul Garg authored
    TLS test cases splice_from_pipe, send_and_splice &
    recv_peek_multiple_records expect to receive a given nummber of bytes
    and then compare them against the number of bytes which were sent.
    Therefore, system call recv() must not return before receiving the
    requested number of bytes, otherwise the subsequent memcmp() fails.
    This patch passes MSG_WAITALL flag to recv() so that it does not return
    prematurely before requested number of bytes are copied to receive
    buffer.
    Signed-off-by: default avatarVakul Garg <vakul.garg@nxp.com>
    Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
    0ed3015c
tls.c 18.3 KB