ngtcp2_ccerr_set_application_error

Synopsis

#include <ngtcp2/ngtcp2.h>

void ngtcp2_ccerr_set_application_error(ngtcp2_ccerr *ccerr, uint64_t error_code, const uint8_t *reason, size_t reasonlen)

ngtcp2_ccerr_set_application_error() sets ccerr->type to ngtcp2_ccerr_type.NGTCP2_CCERR_TYPE_APPLICATION, and ccerr->error_code to error_code. reason is the reason phrase of length reasonlen. This function does not make a copy of the reason phrase.