Home | History | Annotate | Download | only in qemu

Lines Matching full:data

21 _packet_is_internal( const uint8_t*  data, size_t  size )
23 const uint8_t* end = data + size;
26 if (data + 40 > end)
29 if (data[12] != 0x08 || data[13] != 0x00 )
33 data += 14;
34 if ((data[0] >> 4) != 4 || (data[0] & 15) < 5)
38 return ( data[12] == 10 && data[16] == 10);
59 void* data;
64 queued_packet_create( const void* data,
82 packet->data = (void*)(packet+1);
83 memcpy( (char*)packet->data, (char*)data, packet->size );
85 packet->data = (void*)data;
146 shaper->send_func( packet->data, packet->size, packet->opaque );
190 shaper->send_func(packet->data, packet->size, packet->opaque);
208 void* data,
214 if (!shaper->active || _packet_is_internal(data, size)) {
215 shaper->send_func( data, size, opaque );
221 shaper->send_func( data, size, opaque );
231 packet = queued_packet_create( data, size, opaque, shaper->do_copy );
259 void* data,
262 netshaper_send_aux(shaper, data, size, NULL);
339 const uint8_t* data = (const uint8_t*)_data;
340 const uint8_t* end = data + size;
343 if (data + 14 > end - 4)
347 if (data[12] != 0x8 || data[13] != 0)
350 data += 14;
353 if (data + 20 > end)
357 if ((data[0] & 0xF) < 5 || (data[0] >> 4) != 4)
361 if (data[8] == 0)
365 if (data[9] != _PROTOCOL_TCP && data[9] != _PROTOCOL_UDP)
368 info->protocol = data[9];
369 info->src_ip = (data[12] << 24) | (data[13] << 16) | (data[14] << 8) | data[15];
370 info->dst_ip = (data[16] << 24) | (data[17] << 16) | (data[18] << 8) | data[19];
372 data += 4*(data[0] & 15);
373 if (data + 20 > end)
376 info->src_port = (unsigned short)((data[0] << 8) | data[1]);
377 info->dst_port = (unsigned short)((data[2] << 8) | data[3]);
379 return (data[13] & 0x1f);
441 delay->send_func( packet->data, packet->size, packet->opaque );
489 delay->send_func( packet->data, packet->size, packet->opaque );
501 netdelay_send( NetDelay delay, const void* data, size_t size )
503 netdelay_send_aux(delay, data, size, NULL);
508 netdelay_send_aux( NetDelay delay, const void* data, size_t size, void* opaque )
510 if (delay->active && !_packet_is_internal(data, size)) {
514 flags = _packet_SYN_flags( data, size, info );
564 session->packet = queued_packet_create( data, size, opaque, 1 );
572 delay->send_func( (void*)data, size, opaque );