From fc5bb308c77a211a796b4bb5de7952dc7a5630ed Mon Sep 17 00:00:00 2001 From: Jeffrey Altman Date: Sat, 18 Feb 2006 06:01:27 +0000 Subject: [PATCH] rx-dpf-20060217 typo ==================== This delta was composed from multiple commits as part of the CVS->Git migration. The checkin message with each commit was inconsistent. The following are the additional commit messages. ==================== conditionalize rx_intentionallyDroppedOnReadPer100 --- src/rx/rx.c | 2 +- src/rx/rx_packet.c | 8 ++++++-- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/src/rx/rx.c b/src/rx/rx.c index 0f4defca3a..206b589988 100644 --- a/src/rx/rx.c +++ b/src/rx/rx.c @@ -2435,7 +2435,7 @@ rxi_ReceivePacket(register struct rx_packet *np, osi_socket socket, packetType = (np->header.type > 0 && np->header.type < RX_N_PACKET_TYPES) ? rx_packetTypes[np->header.type - 1] : "*UNKNOWN*"; dpf(("R %d %s: %x.%d.%d.%d.%d.%d.%d flags %d, packet %x", - np->header.serial, packetType, ntohl(host), htohs(port), np->header.serviceId, + np->header.serial, packetType, ntohl(host), ntohs(port), np->header.serviceId, np->header.epoch, np->header.cid, np->header.callNumber, np->header.seq, np->header.flags, np)); #endif diff --git a/src/rx/rx_packet.c b/src/rx/rx_packet.c index ec2436b892..0af351b52e 100644 --- a/src/rx/rx_packet.c +++ b/src/rx/rx_packet.c @@ -1409,7 +1409,9 @@ rxi_ReadPacket(osi_socket socket, register struct rx_packet *p, afs_uint32 * hos ntohs(from.sin_port), nbytes)); } return 0; - } else if ((rx_intentionallyDroppedOnReadPer100 > 0) + } +#ifdef RXDEBUG + else if ((rx_intentionallyDroppedOnReadPer100 > 0) && (random() % 100 < rx_intentionallyDroppedOnReadPer100)) { rxi_DecodePacketHeader(p); @@ -1422,7 +1424,9 @@ rxi_ReadPacket(osi_socket socket, register struct rx_packet *p, afs_uint32 * hos p->length)); rxi_TrimDataBufs(p, 1); return 0; - } else { + } +#endif + else { /* Extract packet header. */ rxi_DecodePacketHeader(p);