Lines Matching defs:packet

199  * packet is received, then use user-provided transfer timeouts
260 static void setpacketevent(struct tftp_packet *packet, unsigned short num)
262 packet->data[0] = (unsigned char)(num >> 8);
263 packet->data[1] = (unsigned char)(num & 0xff);
267 static void setpacketblock(struct tftp_packet *packet, unsigned short num)
269 packet->data[2] = (unsigned char)(num >> 8);
270 packet->data[3] = (unsigned char)(num & 0xff);
273 static unsigned short getrpacketevent(const struct tftp_packet *packet)
275 return (unsigned short)((packet->data[0] << 8) | packet->data[1]);
278 static unsigned short getrpacketblock(const struct tftp_packet *packet)
280 return (unsigned short)((packet->data[2] << 8) | packet->data[3]);
325 failf(data, "Malformed ACK packet, rejecting");
337 failf(data, "invalid blocksize value in OACK packet");
373 failf(data, "invalid tsize -:%s:- value in OACK packet", value);
442 case TFTP_EVENT_INIT: /* Send the first packet out */
443 case TFTP_EVENT_TIMEOUT: /* Resend the first packet out */
600 infof(data, "Received last DATA packet block %d again.", rblock);
605 "Received unexpected DATA packet block %d, expecting block %d",
623 /* Check if completed (That is, a less than full packet is received) */
717 /* Ack the packet */
738 /* Re-send the data packet */
753 /* This is the expected packet. Reset the counters and send the next
808 /* Re-send the data packet */
1107 /* Receive the packet */
1120 /* Sanity check packet length */
1122 failf(data, "Received too short packet");
1127 /* The event is given by the TFTP packet time */
1167 failf(data, "%s", "Internal error: Unexpected packet");