diff options
author | Panagiotis Issaris <takis@issaris.org> | 2006-07-21 17:51:30 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2006-07-21 17:51:30 -0400 |
commit | 0da974f4f303a6842516b764507e3c0a03f41e5a (patch) | |
tree | 8872aec792f02040269c6769dd1009b20f71d186 /net/sched/sch_hfsc.c | |
parent | a0ee7c70b22f78593957f99faa06acb4747b8bc0 (diff) |
[NET]: Conversions from kmalloc+memset to k(z|c)alloc.
Signed-off-by: Panagiotis Issaris <takis@issaris.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/sched/sch_hfsc.c')
-rw-r--r-- | net/sched/sch_hfsc.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/net/sched/sch_hfsc.c b/net/sched/sch_hfsc.c index 6b1b4a981e88..6a6735a2ed35 100644 --- a/net/sched/sch_hfsc.c +++ b/net/sched/sch_hfsc.c | |||
@@ -1123,10 +1123,9 @@ hfsc_change_class(struct Qdisc *sch, u32 classid, u32 parentid, | |||
1123 | if (rsc == NULL && fsc == NULL) | 1123 | if (rsc == NULL && fsc == NULL) |
1124 | return -EINVAL; | 1124 | return -EINVAL; |
1125 | 1125 | ||
1126 | cl = kmalloc(sizeof(struct hfsc_class), GFP_KERNEL); | 1126 | cl = kzalloc(sizeof(struct hfsc_class), GFP_KERNEL); |
1127 | if (cl == NULL) | 1127 | if (cl == NULL) |
1128 | return -ENOBUFS; | 1128 | return -ENOBUFS; |
1129 | memset(cl, 0, sizeof(struct hfsc_class)); | ||
1130 | 1129 | ||
1131 | if (rsc != NULL) | 1130 | if (rsc != NULL) |
1132 | hfsc_change_rsc(cl, rsc, 0); | 1131 | hfsc_change_rsc(cl, rsc, 0); |