Skip to content

Commit 9e176f4

Browse files
committed
router: remove unnecessary function
Signed-off-by: Eduardo Silva <[email protected]>
1 parent e934e60 commit 9e176f4

File tree

1 file changed

+4
-9
lines changed

1 file changed

+4
-9
lines changed

src/flb_router.c

Lines changed: 4 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -353,17 +353,10 @@ static int router_metrics_create(struct flb_router *router)
353353
return 0;
354354
}
355355

356-
int flb_router_metrics_create(struct flb_config *config, struct flb_router *router)
357-
{
358-
(void) config;
359-
360-
return router_metrics_create(router);
361-
}
362-
363356
struct flb_router *flb_router_create(struct flb_config *config)
364357
{
358+
int ret;
365359
struct flb_router *router;
366-
367360
(void) config;
368361

369362
router = flb_calloc(1, sizeof(struct flb_router));
@@ -378,7 +371,9 @@ struct flb_router *flb_router_create(struct flb_config *config)
378371
return NULL;
379372
}
380373

381-
if (router_metrics_create(router) != 0) {
374+
ret = router_metrics_create(router);
375+
if (ret != 0) {
376+
flb_error("[router] failed to create metrics");
382377
flb_router_destroy(router);
383378
return NULL;
384379
}

0 commit comments

Comments
 (0)