make format

pull/5/head
Jeff Becker 6 years ago
parent 18b50f4a74
commit 711cc509a9
No known key found for this signature in database
GPG Key ID: F357B3B42F6F9B05

@ -630,61 +630,60 @@ llarp_dht_context::llarp_dht_context(llarp_router *router)
parent = router;
}
extern "C"
extern "C" {
struct llarp_dht_context *
llarp_dht_context_new(struct llarp_router *router)
{
struct llarp_dht_context *
llarp_dht_context_new(struct llarp_router *router)
{
return new llarp_dht_context(router);
}
return new llarp_dht_context(router);
}
void
llarp_dht_context_free(struct llarp_dht_context *ctx)
{
delete ctx;
}
void
llarp_dht_context_free(struct llarp_dht_context *ctx)
{
delete ctx;
}
void
llarp_dht_put_peer(struct llarp_dht_context *ctx, struct llarp_rc *rc)
void
llarp_dht_put_peer(struct llarp_dht_context *ctx, struct llarp_rc *rc)
{
llarp::dht::RCNode n(rc);
ctx->impl.nodes->PutNode(n);
}
{
llarp::dht::RCNode n(rc);
ctx->impl.nodes->PutNode(n);
}
void
llarp_dht_remove_peer(struct llarp_dht_context *ctx, const byte_t *id)
{
llarp::dht::Key_t k = id;
ctx->impl.nodes->DelNode(k);
}
void
llarp_dht_remove_peer(struct llarp_dht_context *ctx, const byte_t *id)
{
llarp::dht::Key_t k = id;
ctx->impl.nodes->DelNode(k);
}
void
llarp_dht_set_msg_handler(struct llarp_dht_context *ctx,
llarp_dht_msg_handler handler)
{
ctx->impl.custom_handler = handler;
}
void
llarp_dht_set_msg_handler(struct llarp_dht_context *ctx,
llarp_dht_msg_handler handler)
{
ctx->impl.custom_handler = handler;
}
void
llarp_dht_allow_transit(llarp_dht_context *ctx)
{
ctx->impl.allowTransit = true;
}
void
llarp_dht_allow_transit(llarp_dht_context *ctx)
{
ctx->impl.allowTransit = true;
}
void
llarp_dht_context_start(struct llarp_dht_context *ctx, const byte_t *key)
{
ctx->impl.Init(key, ctx->parent);
}
void
llarp_dht_context_start(struct llarp_dht_context *ctx, const byte_t *key)
{
ctx->impl.Init(key, ctx->parent);
}
void
llarp_dht_lookup_router(struct llarp_dht_context *ctx,
struct llarp_router_lookup_job *job)
{
job->dht = ctx;
job->found = false;
llarp_logic_queue_job(ctx->parent->logic,
{job, &llarp::dht::Context::queue_router_lookup});
}
void
llarp_dht_lookup_router(struct llarp_dht_context *ctx,
struct llarp_router_lookup_job *job)
{
job->dht = ctx;
job->found = false;
llarp_logic_queue_job(ctx->parent->logic,
{job, &llarp::dht::Context::queue_router_lookup});
}
}

@ -1404,7 +1404,7 @@ namespace iwp
if(state == eSessionStartSent || state == eIntroAckSent)
{
// llarp::Info("EnterState - ", state==eLIMSent?"eLIMSent":"",
// state==eSessionStartSent?"eSessionStartSent":""); PumpCodelInbound();
// state==eSessionStartSent?"eSessionStartSent":""); PumpCodelInbound();
// PumpCodelOutbound();
PumpCryptoOutbound();
// StartInboundCodel();

Loading…
Cancel
Save