Changes in uspace/srv/net/tl/udp/udp.c [348c589:5fe7692] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/srv/net/tl/udp/udp.c
r348c589 r5fe7692 499 499 device_id_t device_id; 500 500 packet_dimension_t *packet_dimension; 501 size_t size;502 501 int rc; 503 504 /* In case of error, do not update the data fragment size. */505 *data_fragment_size = 0;506 502 507 503 rc = tl_get_address_port(addr, addrlen, &dest_port); … … 543 539 packet_dimension = &udp_globals.packet_dimension; 544 540 // } 545 546 /*547 * Update the data fragment size based on what the lower layers can548 * handle without fragmentation, but not more than the maximum allowed549 * for UDP.550 */551 size = MAX_UDP_FRAGMENT_SIZE;552 if (packet_dimension->content < size)553 size = packet_dimension->content;554 *data_fragment_size = size;555 541 556 542 /* Read the first packet fragment */ … … 754 740 int socket_id; 755 741 size_t addrlen; 756 size_t size ;742 size_t size = 0; 757 743 ipc_call_t answer; 758 744 size_t answer_count; … … 800 786 break; 801 787 802 size = MAX_UDP_FRAGMENT_SIZE;803 788 if (tl_get_ip_packet_dimension(udp_globals.ip_phone, 804 789 &udp_globals.dimensions, DEVICE_INVALID_ID, 805 790 &packet_dimension) == EOK) { 806 if (packet_dimension->content < size)807 size = packet_dimension->content;791 SOCKET_SET_DATA_FRAGMENT_SIZE(answer, 792 packet_dimension->content); 808 793 } 809 SOCKET_SET_DATA_FRAGMENT_SIZE(answer, size); 794 795 // SOCKET_SET_DATA_FRAGMENT_SIZE(answer, 796 // MAX_UDP_FRAGMENT_SIZE); 810 797 SOCKET_SET_HEADER_SIZE(answer, UDP_HEADER_SIZE); 811 798 answer_count = 3;
Note:
See TracChangeset
for help on using the changeset viewer.