linux/fs/ceph
Julia Lawall 61413c2f59 fs/ceph/xattr.c: Use kmemdup
Convert a sequence of kmalloc and memcpy to use kmemdup.

The semantic patch that performs this transformation is:
(http://coccinelle.lip6.fr/)

// <smpl>
@@
expression a,flag,len;
expression arg,e1,e2;
statement S;
@@

  a =
-  \(kmalloc\|kzalloc\)(len,flag)
+  kmemdup(arg,len,flag)
  <... when != a
  if (a == NULL || ...) S
  ...>
- memcpy(a,arg,len+1);
// </smpl>

Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: Sage Weil <sage@newdream.net>
2010-10-20 15:38:26 -07:00
..
addr.c ceph: factor out libceph from Ceph file system 2010-10-20 15:37:28 -07:00
caps.c ceph: use mapping->nrpages to determine if mapping is empty 2010-10-20 15:38:15 -07:00
ceph_frag.c ceph: factor out libceph from Ceph file system 2010-10-20 15:37:28 -07:00
debugfs.c ceph: fix debugfs warnings 2010-10-20 15:38:21 -07:00
dir.c ceph: do not hide .snap in root directory 2010-10-20 15:38:14 -07:00
export.c ceph: factor out libceph from Ceph file system 2010-10-20 15:37:28 -07:00
file.c ceph: factor out libceph from Ceph file system 2010-10-20 15:37:28 -07:00
inode.c ceph: factor out libceph from Ceph file system 2010-10-20 15:37:28 -07:00
ioctl.c ceph: add CEPH_MDS_OP_SETDIRLAYOUT and associated ioctl. 2010-10-20 15:38:23 -07:00
ioctl.h ceph: add CEPH_MDS_OP_SETDIRLAYOUT and associated ioctl. 2010-10-20 15:38:23 -07:00
Kconfig ceph: factor out libceph from Ceph file system 2010-10-20 15:37:28 -07:00
locks.c ceph: preallocate flock state without locks held 2010-10-20 15:38:17 -07:00
Makefile ceph: factor out libceph from Ceph file system 2010-10-20 15:37:28 -07:00
mds_client.c ceph: switch from BKL to lock_flocks() 2010-10-20 15:38:18 -07:00
mds_client.h ceph: factor out libceph from Ceph file system 2010-10-20 15:37:28 -07:00
mdsmap.c ceph: factor out libceph from Ceph file system 2010-10-20 15:37:28 -07:00
snap.c ceph: factor out libceph from Ceph file system 2010-10-20 15:37:28 -07:00
strings.c ceph: factor out libceph from Ceph file system 2010-10-20 15:37:28 -07:00
super.c ceph: factor out libceph from Ceph file system 2010-10-20 15:37:28 -07:00
super.h ceph: factor out libceph from Ceph file system 2010-10-20 15:37:28 -07:00
xattr.c fs/ceph/xattr.c: Use kmemdup 2010-10-20 15:38:26 -07:00