summaryrefslogtreecommitdiffstats
path: root/meta/recipes-extended/ltp/ltp/0019-tomoyo-Replace-canonicalize_file_name-with-realpath.patch
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-extended/ltp/ltp/0019-tomoyo-Replace-canonicalize_file_name-with-realpath.patch')
-rw-r--r--meta/recipes-extended/ltp/ltp/0019-tomoyo-Replace-canonicalize_file_name-with-realpath.patch32
1 files changed, 32 insertions, 0 deletions
diff --git a/meta/recipes-extended/ltp/ltp/0019-tomoyo-Replace-canonicalize_file_name-with-realpath.patch b/meta/recipes-extended/ltp/ltp/0019-tomoyo-Replace-canonicalize_file_name-with-realpath.patch
new file mode 100644
index 0000000000..0a4c5f0b3c
--- /dev/null
+++ b/meta/recipes-extended/ltp/ltp/0019-tomoyo-Replace-canonicalize_file_name-with-realpath.patch
@@ -0,0 +1,32 @@
1From 721e94985b9cff3e2724af7ea5be7d005bc12dec Mon Sep 17 00:00:00 2001
2From: Khem Raj <raj.khem@gmail.com>
3Date: Fri, 8 Jan 2016 06:55:27 +0000
4Subject: [PATCH 19/32] tomoyo: Replace canonicalize_file_name() with
5 realpath()
6
7canonicalize_file_name() API is specific to glibc
8
9Signed-off-by: Khem Raj <raj.khem@gmail.com>
10---
11 testcases/kernel/security/tomoyo/tomoyo_filesystem_test.c | 4 ++--
12 1 file changed, 2 insertions(+), 2 deletions(-)
13
14diff --git a/testcases/kernel/security/tomoyo/tomoyo_filesystem_test.c b/testcases/kernel/security/tomoyo/tomoyo_filesystem_test.c
15index da4af0f..5c1a3ca 100644
16--- a/testcases/kernel/security/tomoyo/tomoyo_filesystem_test.c
17+++ b/testcases/kernel/security/tomoyo/tomoyo_filesystem_test.c
18@@ -274,9 +274,9 @@ int main(int argc, char *argv[])
19 /* Test mount(). */
20 {
21 static char buf[4096];
22- char *dev_ram_path = canonicalize_file_name("/dev/ram0");
23+ char *dev_ram_path = realpath("/dev/ram0", NULL);
24 if (!dev_ram_path)
25- dev_ram_path = canonicalize_file_name("/dev/ram");
26+ dev_ram_path = realpath("/dev/ram", NULL);
27 if (!dev_ram_path) {
28 dev_ram_path = "/dev/ram0";
29 mknod(dev_ram_path, S_IFBLK, MKDEV(1, 0));
30--
312.7.0
32