Some log on algo rr

This commit is contained in:
Quentin Dufour 2019-03-19 17:16:49 +01:00
parent 3293197860
commit 9a0c78ebbc

View file

@ -257,7 +257,7 @@ co_error:
int rr_on_udp_read(struct evt_core_ctx* ctx, struct evt_core_fdinfo* fdinfo) {
struct buffer_packet* bp;
struct evt_core_fdinfo *to_fdinfo;
struct evt_core_fdinfo *to_fdinfo = NULL;
struct algo_ctx* app_ctx = fdinfo->cat->app_ctx;
struct rr_ctx* rr = app_ctx->misc;
int read_res = FDS_READY;
@ -300,7 +300,10 @@ int rr_on_udp_read(struct evt_core_ctx* ctx, struct evt_core_fdinfo* fdinfo) {
if (!(rr->my_links & (1 << rr->current_link))) continue;
sprintf(url, "tcp:write:127.0.0.1:%d", 7500 + rr->current_link); //@FIXME Hardcoded
to_fdinfo = evt_core_get_from_url (ctx, url);
if (to_fdinfo != NULL) break;
if (to_fdinfo != NULL) {
printf("Selected url %s\n", url);
break;
}
}
rr->emit_time = curr;
rr->sent_id++;