diff options
author | Luiz Otavio O Souza <luiz@netgate.com> | 2016-04-17 22:33:43 -0500 |
---|---|---|
committer | Luiz Otavio O Souza <luiz@netgate.com> | 2016-04-17 22:33:43 -0500 |
commit | 1d938ea999d69d5102bc266c70e3394c64db16ab (patch) | |
tree | 055ca1b37134021bab8ad5c05b1f8bb7eb83e987 | |
parent | 7eddde35b830e61cb42b9a0dda8660cd59a29b41 (diff) | |
download | FreeBSD-src-1d938ea999d69d5102bc266c70e3394c64db16ab.zip FreeBSD-src-1d938ea999d69d5102bc266c70e3394c64db16ab.tar.gz |
Revert "MFC r284814:"
This reverts commit 69cf34d51f20b467d13ccf4f94f79c4e479b26bc.
TAG: FAIRQ
-rw-r--r-- | sys/contrib/altq/altq/altq_fairq.c | 23 |
1 files changed, 19 insertions, 4 deletions
diff --git a/sys/contrib/altq/altq/altq_fairq.c b/sys/contrib/altq/altq/altq_fairq.c index ea812d8..038e6e1 100644 --- a/sys/contrib/altq/altq/altq_fairq.c +++ b/sys/contrib/altq/altq/altq_fairq.c @@ -103,12 +103,9 @@ #include <sys/queue.h> #include <net/if.h> -#include <net/if_var.h> #include <netinet/in.h> -#include <netpfil/pf/pf.h> -#include <netpfil/pf/pf_altq.h> -#include <netpfil/pf/pf_mtag.h> +#include <net/pfvar.h> #include <altq/altq.h> #include <altq/altq_fairq.h> @@ -409,6 +406,24 @@ 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 |