[bwm-tools-devel] COMMIT - r15 - in trunk: include lib
Brought to you by:
nkukard
From: Dr. N. K. <sv...@li...> - 2005-01-01 07:31:02
|
Author: nkukard Date: 2005-01-01 08:54:26 +0200 (Sat, 01 Jan 2005) New Revision: 15 Modified: trunk/include/flow.h trunk/lib/flow.c trunk/lib/ipq.c Log: * Removed all compiler warnings that seem to have crept in Modified: trunk/include/flow.h =================================================================== --- trunk/include/flow.h 2004-12-29 21:11:51 UTC (rev 14) +++ trunk/include/flow.h 2005-01-01 06:54:26 UTC (rev 15) @@ -206,7 +206,7 @@ // Check if we will exceed flow queuing limits -static inline will_exceed_flow_queue(struct flow_t *flow, unsigned int pktSize) +static inline int will_exceed_flow_queue(struct flow_t *flow, unsigned int pktSize) { return ((flow->curQueueLen >= flow->maxQueueLen && flow->maxQueueLen != 0) || (flow->curQueueSize + pktSize >= flow->maxQueueSize && flow->maxQueueSize != 0)); Modified: trunk/lib/flow.c =================================================================== --- trunk/lib/flow.c 2004-12-29 21:11:51 UTC (rev 14) +++ trunk/lib/flow.c 2005-01-01 06:54:26 UTC (rev 15) @@ -375,7 +375,6 @@ else { unsigned int accumCredit; - unsigned int accumBurst; // Add up accumulated time @@ -509,9 +508,6 @@ */ if (ok && bursted) { - double parentCur = 0, parentCurBurst = 0; - - // Calculate parent credits calculate_flow_credit(flow->parent,PKT_SIZE(packet)); Modified: trunk/lib/ipq.c =================================================================== --- trunk/lib/ipq.c 2004-12-29 21:11:51 UTC (rev 14) +++ trunk/lib/ipq.c 2005-01-01 06:54:26 UTC (rev 15) @@ -76,7 +76,7 @@ // Check if we will exceed our queue -static inline will_exceed_pkt_queue(struct pktQueue_t *pktQueue, unsigned int pktSize) +static inline int will_exceed_pkt_queue(struct pktQueue_t *pktQueue, unsigned int pktSize) { return ((pktQueue->curLen >= pktQueue->maxLen && pktQueue->maxLen != 0) || (pktQueue->curSize + pktSize >= pktQueue->maxSize && pktQueue->maxSize != 0)); @@ -162,8 +162,9 @@ // Process a ICMP packet if (ip_packet->protocol == IPPROTO_ICMP) { +/* struct icmphdr *icmph = (struct icmphdr *) (packet->payload->payload + (ip_packet->ihl * 4)); -/* + fprintf(stderr,"something: icmp = %i, type = %i\n", icmph->code, icmph->type); */ bandNum = 5; |