Lines Matching refs:len
118 int len, code;
129 len = 65536;
137 len = s[1];
147 if (s + len + 2 > end) {
151 dhcp_options[code].name, len,
170 if (!(t = calloc(1, len + 1)))
177 memcpy(t, &s[2], len);
178 t[len] = 0;
179 packet->options[code].len = len;
187 t = calloc(1, len + packet->options[code].len + 1);
192 packet->options[code].len);
193 memcpy(t + packet->options[code].len,
194 &s[2], len);
195 packet->options[code].len += len;
196 t[packet->options[code].len] = 0;
200 s += len + 2;
226 while (offset < option->len) {
245 while (offset < option->len) {
253 option->len = expanded_len;
265 while (i < option->len) {
276 if (i + 1 >= option->len) {
303 if (i + label_len >= option->len) {
338 while (i < option->len) {
396 (inpacket->options[DHO_DHCP_MAX_MESSAGE_SIZE].len >=
426 inpacket->options[DHO_DHCP_PARAMETER_REQUEST_LIST].len;
558 length = options[code]->len;
625 pretty_print_option(unsigned int code, unsigned char *data, int len,
662 for (k = 0; k < len; k++)
666 if (k == len) {
707 if (hunksize > len) {
709 dhcp_options[code].name, hunksize, len);
713 if (numhunk == -1 && hunksize < len)
715 dhcp_options[code].name, len - hunksize);
719 numhunk = len / hunksize;
721 if (numhunk > 0 && numhunk * hunksize < len)
723 dhcp_options[code].name, len - numhunk * hunksize);
739 for (; dp < data + len; dp++) {
742 if (dp + 1 != data + len ||
863 int len, unsigned int from_port, struct iaddr from, struct hardware *hfrom)
875 tp.packet_length = len;
892 if (tp.options[i].len && tp.options[i].data)