git://wimlib.net
/
wimlib
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
d490e6e
)
ntfs-3g_apply.c: Only warn when DOS names cannot be applied
author
Eric Biggers
<ebiggers3@gmail.com>
Tue, 21 May 2013 01:40:27 +0000
(20:40 -0500)
committer
Eric Biggers
<ebiggers3@gmail.com>
Tue, 21 May 2013 01:40:36 +0000
(20:40 -0500)
src/ntfs-3g_apply.c
patch
|
blob
|
history
diff --git
a/src/ntfs-3g_apply.c
b/src/ntfs-3g_apply.c
index 0de2bb042da01fc98a5421a5f7567ad60f1775d7..4e5926bcc71f21ea0fad433e043b33095b8e0abc 100644
(file)
--- a/
src/ntfs-3g_apply.c
+++ b/
src/ntfs-3g_apply.c
@@
-476,9
+476,9
@@
do_apply_dentry_ntfs(struct wim_dentry *dentry, ntfs_inode *dir_ni,
short_name_mbs_nbytes, 0);
FREE(short_name_mbs);
if (ret) {
short_name_mbs_nbytes, 0);
FREE(short_name_mbs);
if (ret) {
-
ERROR
_WITH_ERRNO("Could not set DOS (short) name for `%s'",
- dentry->_full_path);
- ret =
WIMLIB_ERR_NTFS_3G
;
+
WARNING
_WITH_ERRNO("Could not set DOS (short) name for `%s'",
+
dentry->_full_path);
+ ret =
0
;
}
/* inodes have been closed by ntfs_set_ntfs_dos_name(). */
goto out;
}
/* inodes have been closed by ntfs_set_ntfs_dos_name(). */
goto out;
@@
-513,6
+513,10
@@
apply_root_dentry_ntfs(struct wim_dentry *dentry,
ntfs_inode *ni;
int ret = 0;
ntfs_inode *ni;
int ret = 0;
+ ret = calculate_dentry_full_path(dentry);
+ if (ret)
+ return ret;
+
ni = ntfs_pathname_to_inode(vol, NULL, "/");
if (!ni) {
ERROR_WITH_ERRNO("Could not find root NTFS inode");
ni = ntfs_pathname_to_inode(vol, NULL, "/");
if (!ni) {
ERROR_WITH_ERRNO("Could not find root NTFS inode");
@@
-539,10
+543,6
@@
apply_dentry_ntfs(struct wim_dentry *dentry, void *arg)
struct wim_dentry *other;
int ret;
struct wim_dentry *other;
int ret;
- ret = calculate_dentry_full_path(dentry);
- if (ret)
- return ret;
-
/* Treat the root dentry specially. */
if (dentry_is_root(dentry))
return apply_root_dentry_ntfs(dentry, vol, w,
/* Treat the root dentry specially. */
if (dentry_is_root(dentry))
return apply_root_dentry_ntfs(dentry, vol, w,
@@
-598,10
+598,10
@@
apply_dentry_ntfs(struct wim_dentry *dentry, void *arg)
again:
orig_dentry = NULL;
if (!dentry->d_inode->i_dos_name_extracted &&
again:
orig_dentry = NULL;
if (!dentry->d_inode->i_dos_name_extracted &&
-
!dentry_has_short_name(dentry
))
+
(!dentry_has_short_name(dentry) || dentry->dos_name_invalid
))
{
inode_for_each_dentry(other, dentry->d_inode) {
{
inode_for_each_dentry(other, dentry->d_inode) {
- if (dentry_has_short_name(other)) {
+ if (dentry_has_short_name(other)
&& !other->dos_name_invalid
) {
orig_dentry = dentry;
dentry = other;
break;
orig_dentry = dentry;
dentry = other;
break;
@@
-609,6
+609,11
@@
again:
}
}
dentry->d_inode->i_dos_name_extracted = 1;
}
}
dentry->d_inode->i_dos_name_extracted = 1;
+
+ ret = calculate_dentry_full_path(dentry);
+ if (ret)
+ return ret;
+
ntfs_inode *dir_ni = dentry_open_parent_ni(dentry, vol);
if (dir_ni) {
ret = do_apply_dentry_ntfs(dentry, dir_ni, arg);
ntfs_inode *dir_ni = dentry_open_parent_ni(dentry, vol);
if (dir_ni) {
ret = do_apply_dentry_ntfs(dentry, dir_ni, arg);