diff options
author | smitsohu <smitsohu@gmail.com> | 2019-06-17 14:40:02 +0200 |
---|---|---|
committer | smitsohu <smitsohu@gmail.com> | 2019-06-17 14:40:02 +0200 |
commit | e3cafb7fac7a8b17c8376616c93317c9d51cdda7 (patch) | |
tree | 2ff3d356f553d9bb49906bfacd8818954492b2e5 /src/firejail/pulseaudio.c | |
parent | cleanup (diff) | |
download | firejail-e3cafb7fac7a8b17c8376616c93317c9d51cdda7.tar.gz firejail-e3cafb7fac7a8b17c8376616c93317c9d51cdda7.tar.zst firejail-e3cafb7fac7a8b17c8376616c93317c9d51cdda7.zip |
no postmount checks when building basic filesystem
fixes #2782
Diffstat (limited to 'src/firejail/pulseaudio.c')
-rw-r--r-- | src/firejail/pulseaudio.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/firejail/pulseaudio.c b/src/firejail/pulseaudio.c index a62d123ae..b82473476 100644 --- a/src/firejail/pulseaudio.c +++ b/src/firejail/pulseaudio.c | |||
@@ -88,7 +88,7 @@ void pulseaudio_init(void) { | |||
88 | if (mkdir(RUN_PULSE_DIR, 0700) == -1) | 88 | if (mkdir(RUN_PULSE_DIR, 0700) == -1) |
89 | errExit("mkdir"); | 89 | errExit("mkdir"); |
90 | // mount it nosuid, noexec, nodev | 90 | // mount it nosuid, noexec, nodev |
91 | fs_remount(RUN_PULSE_DIR, MOUNT_NOEXEC); | 91 | fs_remount(RUN_PULSE_DIR, MOUNT_NOEXEC, 0); |
92 | 92 | ||
93 | // create the new client.conf file | 93 | // create the new client.conf file |
94 | char *pulsecfg = NULL; | 94 | char *pulsecfg = NULL; |
@@ -155,8 +155,10 @@ void pulseaudio_init(void) { | |||
155 | if (fstatvfs(fd, &vfs) == -1) | 155 | if (fstatvfs(fd, &vfs) == -1) |
156 | errExit("fstatvfs"); | 156 | errExit("fstatvfs"); |
157 | if ((vfs.f_flag & MS_RDONLY) == MS_RDONLY) | 157 | if ((vfs.f_flag & MS_RDONLY) == MS_RDONLY) |
158 | fs_remount(RUN_PULSE_DIR, MOUNT_READONLY); | 158 | fs_remount(RUN_PULSE_DIR, MOUNT_READONLY, 0); |
159 | // mount via the link in /proc/self/fd | 159 | // mount via the link in /proc/self/fd |
160 | if (arg_debug) | ||
161 | printf("Mounting %s on %s\n", RUN_PULSE_DIR, homeusercfg); | ||
160 | char *proc; | 162 | char *proc; |
161 | if (asprintf(&proc, "/proc/self/fd/%d", fd) == -1) | 163 | if (asprintf(&proc, "/proc/self/fd/%d", fd) == -1) |
162 | errExit("asprintf"); | 164 | errExit("asprintf"); |