]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - net/ipv4/ip_options.c
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/roland...
[linux-2.6-omap-h63xx.git] / net / ipv4 / ip_options.c
index 251346828cb4ceca55d2f3b5622698b4fbd26249..2f14745a9e1fb0aa5bdc779421d9376049963884 100644 (file)
@@ -513,11 +513,8 @@ void ip_options_undo(struct ip_options * opt)
 
 static struct ip_options *ip_options_get_alloc(const int optlen)
 {
-       struct ip_options *opt = kmalloc(sizeof(*opt) + ((optlen + 3) & ~3),
-                                        GFP_KERNEL);
-       if (opt)
-               memset(opt, 0, sizeof(*opt));
-       return opt;
+       return kzalloc(sizeof(struct ip_options) + ((optlen + 3) & ~3),
+                      GFP_KERNEL);
 }
 
 static int ip_options_get_finish(struct ip_options **optp,