- netdev_read_start(udp_dgram_len-UDP_HEADER_SIZE);
- for (i = 0; i < udp_dgram_len-UDP_HEADER_SIZE; ++i)
- buf[i] = netdev_read_byte();
+ len = udp_dgram_len - UDP_HEADER_SIZE;
+ netdev_read_start(len);
+ leds_matrix_len = len;
+ for (i = 0; i < len; ++i)
+ leds_matrix[i] = udp_read_byte();