X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=net%2Fsched%2Fsch_hfsc.c;h=f1c7bd29f2cdc3932941c86e529426923484dee1;hb=9464c7cf61b9433057924c36e6e02f303a00e768;hp=6a6735a2ed355b9640e654b28a5ecb96f69906e8;hpb=41689045f6a3cbe0550e1d34e9cc20d2e8c432ba;p=linux-2.6.git diff --git a/net/sched/sch_hfsc.c b/net/sched/sch_hfsc.c index 6a6735a2e..f1c7bd29f 100644 --- a/net/sched/sch_hfsc.c +++ b/net/sched/sch_hfsc.c @@ -50,6 +50,7 @@ */ #include +#include #include #include #include @@ -1123,9 +1124,10 @@ hfsc_change_class(struct Qdisc *sch, u32 classid, u32 parentid, if (rsc == NULL && fsc == NULL) return -EINVAL; - cl = kzalloc(sizeof(struct hfsc_class), GFP_KERNEL); + cl = kmalloc(sizeof(struct hfsc_class), GFP_KERNEL); if (cl == NULL) return -ENOBUFS; + memset(cl, 0, sizeof(struct hfsc_class)); if (rsc != NULL) hfsc_change_rsc(cl, rsc, 0);