Don't garbage collect UDP
This commit is contained in:
parent
5c7f949507
commit
1ee6727a98
2 changed files with 2 additions and 2 deletions
|
@ -346,7 +346,7 @@ void on_timeout_health (struct evt_core_ctx* ctx, void* raw) {
|
||||||
}
|
}
|
||||||
|
|
||||||
int algo_rr_on_err(struct evt_core_ctx* ctx, struct evt_core_fdinfo* fdinfo) {
|
int algo_rr_on_err(struct evt_core_ctx* ctx, struct evt_core_fdinfo* fdinfo) {
|
||||||
// We do nothing
|
if (strstr(fdinfo->cat->name, "udp") != NULL) return 1;
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -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) {
|
enum FD_STATE write_packet_to_tcp(int fd, struct buffer_packet* bp) {
|
||||||
ssize_t nwrite;
|
ssize_t nwrite;
|
||||||
|
|
||||||
// dump_buffer_packet (bp);
|
//dump_buffer_packet (bp);
|
||||||
if (bp->mode != BP_WRITING) return FDS_ERR;
|
if (bp->mode != BP_WRITING) return FDS_ERR;
|
||||||
while (bp->awrite < get_full_size(bp)) {
|
while (bp->awrite < get_full_size(bp)) {
|
||||||
nwrite = send(fd, &(bp->ip.ap.raw) + bp->awrite, get_full_size(bp) - bp->awrite, 0);
|
nwrite = send(fd, &(bp->ip.ap.raw) + bp->awrite, get_full_size(bp) - bp->awrite, 0);
|
||||||
|
|
Loading…
Reference in a new issue