OSDN Git Service
(root)
/
android-x86
/
external-efivar.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8a27d0a
)
Fix getting back a wrong relpath
author
Lans Zhang
<jia.zhang@windriver.com>
Sat, 26 Sep 2015 06:00:04 +0000
(14:00 +0800)
committer
Peter Jones
<pjones@redhat.com>
Mon, 5 Oct 2015 14:50:55 +0000
(10:50 -0400)
If a device is mounted at more than one mount points, the relpath
may be created with unexpected result because there is no compare
before doing it.
Resolvs #34
Signed-off-by: Lans Zhang <jia.zhang@windriver.com>
Signed-off-by: Peter Jones <pjones@redhat.com>
src/creator.c
patch
|
blob
|
history
diff --git
a/src/creator.c
b/src/creator.c
index
1244cb8
..
c33b935
100644
(file)
--- a/
src/creator.c
+++ b/
src/creator.c
@@
-116,6
+116,8
@@
find_file(const char * const filepath, char **devicep, char **relpathp)
errno = ENAMETOOLONG;
goto err;
}
+ if (strncmp(linkbuf, me->mnt_dir, mntlen))
+ continue;
*devicep = strdup(me->mnt_fsname);
if (!*devicep)
goto err;