diff --git a/sys/net/altq/altq_fairq.c b/sys/net/altq/altq_fairq.c index b513a671fe1..de00685841a 100644 --- a/sys/net/altq/altq_fairq.c +++ b/sys/net/altq/altq_fairq.c @@ -103,9 +103,12 @@ #include #include +#include #include -#include +#include +#include +#include #include #include @@ -406,24 +409,6 @@ fairq_class_create(struct fairq_if *pif, int pri, int qlimit, #endif /* ALTQ_RED */ return (cl); - -err_buckets: - if (cl->cl_buckets != NULL) - free(cl->cl_buckets, M_DEVBUF); -err_ret: - if (cl->cl_red != NULL) { -#ifdef ALTQ_RIO - if (cl->cl_qtype == Q_RIO) - rio_destroy((rio_t *)cl->cl_red); -#endif -#ifdef ALTQ_RED - if (cl->cl_qtype == Q_RED) - red_destroy(cl->cl_red); -#endif - } - if (cl != NULL) - free(cl, M_DEVBUF); - return (NULL); } static int