qemu-e2k/hw/9pfs
Michael Tokarev 1b6f85e2cb 9pfs-local: simplify/optimize local_mapped_attr_path()
Omit one unnecessary memory allocation for components
of the path and create the resulting path directly given
lengths of the components.

Do not use basename(3) because there are 2 versions of
this function which differs when argument ends with
slash character, use strrchr() instead so we have
consistent result.  This also makes sure the function
will do the right thing in corner cases (eg, empty
pathname is given), when basename(3) return entirely
another string.

Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
2015-03-12 15:23:05 +05:30
..
codir.c misc: move include files to include/qemu/ 2012-12-19 08:32:39 +01:00
cofile.c hw/9pfs: fix P9_STATS_GEN handling 2014-02-02 22:09:16 +05:30
cofs.c hw/9pfs: use g_strdup_printf() instead of PATH_MAX limitation 2014-03-04 00:57:57 +05:30
coxattr.c misc: move include files to include/qemu/ 2012-12-19 08:32:39 +01:00
Makefile.objs Remove libhw 2012-10-05 16:07:49 -05:00
virtio-9p-coth.c 9pfs: changed to use event_notifier instead of qemu_pipe 2015-01-09 23:41:11 +01:00
virtio-9p-coth.h 9pfs: changed to use event_notifier instead of qemu_pipe 2015-01-09 23:41:11 +01:00
virtio-9p-device.c virtio: feature bit manipulation helpers 2015-02-26 13:04:07 +01:00
virtio-9p-handle.c hw/9pfs: use g_strdup_printf() instead of PATH_MAX limitation 2014-03-04 00:57:57 +05:30
virtio-9p-local.c 9pfs-local: simplify/optimize local_mapped_attr_path() 2015-03-12 15:23:05 +05:30
virtio-9p-posix-acl.c hw/9pfs: use g_strdup_printf() instead of PATH_MAX limitation 2014-03-04 00:57:57 +05:30
virtio-9p-proxy.c virtio-9p-proxy: improve error messages in connect_namedsocket() 2014-11-02 10:04:34 +03:00
virtio-9p-proxy.h hw/9pfs: Proxy getversion 2012-01-04 20:20:55 +05:30
virtio-9p-synth.c rcu: introduce RCU-enabled QLIST 2015-02-16 17:30:19 +01:00
virtio-9p-synth.h janitor: add guards to headers 2012-12-19 08:31:31 +01:00
virtio-9p-xattr-user.c hw/9pfs: use g_strdup_printf() instead of PATH_MAX limitation 2014-03-04 00:57:57 +05:30
virtio-9p-xattr.c hw/9pfs: use g_strdup_printf() instead of PATH_MAX limitation 2014-03-04 00:57:57 +05:30
virtio-9p-xattr.h hw/9pfs: use g_strdup_printf() instead of PATH_MAX limitation 2014-03-04 00:57:57 +05:30
virtio-9p.c virtio: Drop superfluous conditionals around g_free() 2014-06-19 16:41:53 +03:00
virtio-9p.h virtio-9p: use standard headers 2015-02-26 13:04:04 +01:00