diff --git a/src/algo_rr.c b/src/algo_rr.c index 248a5af..b822c5e 100644 --- a/src/algo_rr.c +++ b/src/algo_rr.c @@ -205,7 +205,7 @@ int algo_rr_on_datagram(struct evt_core_ctx* ctx, struct evt_core_fdinfo* fdinfo struct evt_core_fdinfo *to_fdinfo = NULL; uint16_t min_pkt; char url[255]; - size_t health_packet_size = sizeof(bp->ip.ap.fmt.headers) - sizeof(bp->ip.ap.fmt.content.health); + size_t health_packet_size = sizeof(bp->ip.ap.fmt.headers) + sizeof(bp->ip.ap.fmt.content.health); size_t max_size = sizeof(struct internet_packet) - health_packet_size; if (ctx->verbose > 1) fprintf(stderr, " [algo/rr] Read a UDP packet on URL %s\n", fdinfo->url); diff --git a/src/packet.c b/src/packet.c index fd59c70..ccf33c3 100644 --- a/src/packet.c +++ b/src/packet.c @@ -39,7 +39,7 @@ enum FD_STATE read_packet_from_tcp(int fd, struct buffer_packet* bp) { enum FD_STATE write_packet_to_tcp(int fd, struct buffer_packet* bp) { ssize_t nwrite; - dump_buffer_packet (bp); + // dump_buffer_packet (bp); if (bp->mode != BP_WRITING) return FDS_ERR; while (bp->awrite < get_full_size(bp)) { nwrite = send(fd, &(bp->ip.ap.raw) + bp->awrite, get_full_size(bp) - bp->awrite, 0);