Lines Matching defs:opt
719 coap_opt_t *opt;
758 opt = pdu->data -1;
761 opt = pdu->token + pdu->used_size;
765 optsize = coap_opt_encode(opt, pdu->alloc_size - pdu->used_size,
899 * returns the number of bytes opt has been advanced or @c 0
1296 coap_opt_t *opt = pdu->token + pdu->e_token_length;
1299 while (length > 0 && *opt != COAP_PAYLOAD_START) {
1301 coap_opt_t *opt_last = opt;
1303 size_t optsize = next_option_safe(&opt, &length, &pdu->max_opt);
1305 optsize ? coap_opt_length((const uint8_t *)opt - optsize) : 0;
1338 opt = pdu->token + pdu->e_token_length;
1345 while (length > 0 && *opt != COAP_PAYLOAD_START) {
1346 coap_opt_t *opt_last = opt;
1347 size_t optsize = next_option_safe(&opt, &length, &pdu->max_opt);
1349 optsize ? coap_opt_length((const uint8_t *)opt - optsize) : 0;
1356 opt = pdu->token + pdu->used_size;
1362 tlen = opt - opt_last;
1368 if (length && *opt == COAP_PAYLOAD_START) {
1369 ok = ok && write_char(&obp, &outbuflen, *opt, i);
1378 assert(*opt == COAP_PAYLOAD_START);
1379 opt++;
1388 pdu->data = (uint8_t *)opt;