diff options
author | Arnaldo Carvalho de Melo <acme@mandriva.com> | 2006-11-20 22:18:33 -0500 |
---|---|---|
committer | David S. Miller <davem@sunset.davemloft.net> | 2006-12-03 00:30:17 -0500 |
commit | b3ab09f9e1681916df349d54232fbb3f8a79bfa5 (patch) | |
tree | 3eb5667ee2efd5ea0355f881cb02898cd5658192 /net/irda/irqueue.c | |
parent | 8b2ed4bba45b7ca8e378d45f82f3f32f651e0a42 (diff) |
[IRDA]: Use kmemdup where applicable
Signed-off-by: Arnaldo Carvalho de Melo <acme@mandriva.com>
Diffstat (limited to 'net/irda/irqueue.c')
-rw-r--r-- | net/irda/irqueue.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/net/irda/irqueue.c b/net/irda/irqueue.c index 1ba8c7106639..1d26cd33ea13 100644 --- a/net/irda/irqueue.c +++ b/net/irda/irqueue.c | |||
@@ -356,14 +356,13 @@ hashbin_t *hashbin_new(int type) | |||
356 | /* | 356 | /* |
357 | * Allocate new hashbin | 357 | * Allocate new hashbin |
358 | */ | 358 | */ |
359 | hashbin = kmalloc( sizeof(hashbin_t), GFP_ATOMIC); | 359 | hashbin = kzalloc(sizeof(*hashbin), GFP_ATOMIC); |
360 | if (!hashbin) | 360 | if (!hashbin) |
361 | return NULL; | 361 | return NULL; |
362 | 362 | ||
363 | /* | 363 | /* |
364 | * Initialize structure | 364 | * Initialize structure |
365 | */ | 365 | */ |
366 | memset(hashbin, 0, sizeof(hashbin_t)); | ||
367 | hashbin->hb_type = type; | 366 | hashbin->hb_type = type; |
368 | hashbin->magic = HB_MAGIC; | 367 | hashbin->magic = HB_MAGIC; |
369 | //hashbin->hb_current = NULL; | 368 | //hashbin->hb_current = NULL; |