Removed type check and debug output.

We will send PKT_PROBE in send_sptps_packet only if handshake has been completed.
This commit is contained in:
thorkill 2016-05-11 19:29:04 +02:00
parent 62064cc5ef
commit ae199d9f2b

View file

@ -139,9 +139,8 @@ static bool send_record_priv(sptps_t *s, uint8_t type, const void *data, uint16_
// Send an application record. // Send an application record.
bool sptps_send_record(sptps_t *s, uint8_t type, const void *data, uint16_t len) { bool sptps_send_record(sptps_t *s, uint8_t type, const void *data, uint16_t len) {
if((!s->outstate) && (type != PKT_PROBE)) if(!s->outstate)
return error(s, EINVAL, "Handshake phase not finished yet (outstate:%x type: %d)", return error(s, EINVAL, "Handshake phase not finished yet");
s->outstate, type);
// Sanity checks: application cannot send data before handshake is finished, // Sanity checks: application cannot send data before handshake is finished,
// and only record types 0..127 are allowed. // and only record types 0..127 are allowed.