mirror of
https://git.code.sf.net/p/ntfs-3g/ntfs-3g.git
synced 2024-11-23 18:14:24 +08:00
fix mount hang if kernel 2.6.29 audit is enabled: we ignore mtab update error as mount(8)
This commit is contained in:
parent
fd8e63faa3
commit
a5c720e21b
@ -58,7 +58,6 @@ int fuse_mnt_add_mount(const char *progname, const char *fsname,
|
||||
const char *mnt, const char *type, const char *opts)
|
||||
{
|
||||
int res;
|
||||
int status;
|
||||
|
||||
if (!mtab_needs_update(mnt))
|
||||
return 0;
|
||||
@ -66,7 +65,7 @@ int fuse_mnt_add_mount(const char *progname, const char *fsname,
|
||||
res = fork();
|
||||
if (res == -1) {
|
||||
fprintf(stderr, "%s: fork: %s\n", progname, strerror(errno));
|
||||
return -1;
|
||||
return 0;
|
||||
}
|
||||
if (res == 0) {
|
||||
char templ[] = "/tmp/fusermountXXXXXX";
|
||||
@ -96,14 +95,6 @@ int fuse_mnt_add_mount(const char *progname, const char *fsname,
|
||||
strerror(errno));
|
||||
exit(1);
|
||||
}
|
||||
res = waitpid(res, &status, 0);
|
||||
if (res == -1) {
|
||||
fprintf(stderr, "%s: waitpid: %s\n", progname, strerror(errno));
|
||||
return -1;
|
||||
}
|
||||
if (status != 0)
|
||||
return -1;
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user