On Thu, Feb 19, 2015 at 08:01:01PM -0500, Ted Unangst wrote:
> Yes. That is consistent with other callers.

OK bluhm@

> Index: pf_ioctl.c
> ===================================================================
> RCS file: /cvs/src/sys/net/pf_ioctl.c,v
> retrieving revision 1.282
> diff -u -p -r1.282 pf_ioctl.c
> --- pf_ioctl.c        10 Feb 2015 06:45:55 -0000      1.282
> +++ pf_ioctl.c        20 Feb 2015 01:00:29 -0000
> @@ -1032,10 +1032,14 @@ pfioctl(dev_t dev, u_long cmd, caddr_t a
>               bcopy(&q->queue, qs, sizeof(*qs));
>               qs->qid = pf_qname2qid(qs->qname, 1);
>               if (qs->parent[0] && (qs->parent_qid =
> -                 pf_qname2qid(qs->parent, 0)) == 0)
> -                     return (ESRCH);
> +                 pf_qname2qid(qs->parent, 0)) == 0) {
> +                     pool_put(&pf_queue_pl, qs);
> +                     error = ESRCH;
> +                     break;
> +             }
>               qs->kif = pfi_kif_get(qs->ifname);
> -             if (!qs->kif->pfik_ifp) {
> +             if (qs->kif == NULL) {
> +                     pool_put(&pf_queue_pl, qs);
>                       error = ESRCH;
>                       break;
>               }

Reply via email to