Diederik de Haas dixit:

>I proposed my patch to expedite things and (much) prefer that Thorsten would

I’m not the author…

>I can do it, but I would like Thorsten to test the patch and confirm it

It’s obviously correct, it moves the nil check to the correct place.

I tested “the reverse” by doing…

@@ -1275,11 +1275,12 @@ static void htb_destroy_class(struct Qdisc *sch, struct 
htb_class *cl)
                WARN_ON(!cl->leaf.q);
 #if (LINUX_VERSION_CODE < KERNEL_VERSION(4, 20, 0)) && \
     (!defined(JENS_LINUX_4_19_SL) || (JENS_LINUX_4_19_SL < 221))
                qdisc_destroy(cl->leaf.q);
 #else
-               qdisc_put(cl->leaf.q);
+               if (cl->leaf.q)
+                       qdisc_put(cl->leaf.q);
 #endif
        }
        gen_kill_estimator(&cl->rate_est);
        tcf_block_put(cl->block);
        kfree(cl);

… so the net effect is tested.

bye,
//mirabilos
-- 
Infrastrukturexperte • tarent solutions GmbH
Am Dickobskreuz 10, D-53121 Bonn • http://www.tarent.de/
Telephon +49 228 54881-393 • Fax: +49 228 54881-235
HRB AG Bonn 5168 • USt-ID (VAT): DE122264941
Geschäftsführer: Dr. Stefan Barth, Kai Ebenrett, Boris Esser, Alexander Steeg

Reply via email to