Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1432066 > unrolled thread
| Started by | David Miller <davem@davemloft.net> |
|---|---|
| First post | 2016-06-27 16:10 +0200 |
| Last post | 2016-06-27 16:10 +0200 |
| Articles | 1 — 1 participant |
Back to article view | Back to linux.kernel
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
Re: [PATCH] tipc: Use kmemdup instead of kmalloc and memcpy David Miller <davem@davemloft.net> - 2016-06-27 16:10 +0200
| From | David Miller <davem@davemloft.net> |
|---|---|
| Date | 2016-06-27 16:10 +0200 |
| Subject | Re: [PATCH] tipc: Use kmemdup instead of kmalloc and memcpy |
| Message-ID | <rOFoD-1gZ-45@gated-at.bofh.it> |
From: Amitoj Kaur Chawla <amitoj1606@gmail.com> Date: Thu, 23 Jun 2016 10:19:37 +0530 > Replace calls to kmalloc followed by a memcpy with a direct call to > kmemdup. > > The Coccinelle semantic patch used to make this change is as follows: > @@ > expression from,to,size,flag; > statement S; > @@ > > - to = \(kmalloc\|kzalloc\)(size,flag); > + to = kmemdup(from,size,flag); > if (to==NULL || ...) S > - memcpy(to, from, size); > > Signed-off-by: Amitoj Kaur Chawla <amitoj1606@gmail.com> Applied.
Back to top | Article view | linux.kernel
csiph-web