Lines Matching full:received
58 data->tcp.received = 0U; in send_tcp_data()
75 static int compare_tcp_data(struct sample_data *data, const char *buf, uint32_t received) in compare_tcp_data() argument
77 if (data->tcp.received + received > data->tcp.expecting) { in compare_tcp_data()
78 LOG_ERR("Too much data received: TCP %s", data->proto); in compare_tcp_data()
82 if (memcmp(buf, lorem_ipsum + data->tcp.received, received) != 0) { in compare_tcp_data()
83 LOG_ERR("Invalid data received: TCP %s", data->proto); in compare_tcp_data()
185 int ret, received; in process_tcp_proto() local
189 received = recv(data->tcp.sock, buf, sizeof(buf), MSG_DONTWAIT); in process_tcp_proto()
192 if (received == 0) { in process_tcp_proto()
195 } else if (received < 0) { in process_tcp_proto()
204 ret = compare_tcp_data(data, buf, received); in process_tcp_proto()
210 data->tcp.received += received; in process_tcp_proto()
211 if (data->tcp.received < data->tcp.expecting) { in process_tcp_proto()
217 LOG_DBG("%s TCP: Received and compared %d bytes, all ok", in process_tcp_proto()
218 data->proto, data->tcp.received); in process_tcp_proto()
228 } while (received > 0); in process_tcp_proto()