Skip to content

Using Clumsy simulate loss packet 10%,the data is not the same with sent #4249

Answered by yangjiaxiang
yangjiaxiang asked this question in Q&A
Discussion options

You must be logged in to vote

Thank you for your reply。
Well, My English is not so well, I will try to explain more detailly. Using msquic to send video file.

server peer :
send stream:

int QuicServer::SendStream(const uint8_t* data, std::size_t len, bool last /*= false*/)
{
    QUIC_STATUS status;
    QUIC_BUFFER* buffer = (QUIC_BUFFER*)malloc(sizeof(QUIC_BUFFER) + len);
    if (nullptr == buffer)
    {
        return -1;
    }

    buffer->Length = len;
    buffer->Buffer = (uint8_t*)buffer + sizeof(QUIC_BUFFER);
    memcpy(buffer->Buffer, data, len);

    if (QUIC_FAILED(status = _msQuic->StreamSend(_stream, buffer, 1, last ? QUIC_SEND_FLAG_FIN : QUIC_SEND_FLAG_NONE, buffer)))
    {
        free(buffer);
        re…

Replies: 3 comments 12 replies

Comment options

You must be logged in to vote
1 reply
@yangjiaxiang
Comment options

Answer selected by yangjiaxiang
Comment options

You must be logged in to vote
8 replies
@nibanks
Comment options

@yangjiaxiang
Comment options

@nibanks
Comment options

@yangjiaxiang
Comment options

@nibanks
Comment options

Comment options

You must be logged in to vote
3 replies
@nibanks
Comment options

@yangjiaxiang
Comment options

@nibanks
Comment options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants