Skip to content

Commit

Permalink
webui: use global mount namespace by default.
Browse files Browse the repository at this point in the history
  • Loading branch information
tiann committed Feb 29, 2024
1 parent 622a7d7 commit e39a80f
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ class WebViewInterface(val context: Context, private val webView: WebView) {

@JavascriptInterface
fun exec(cmd: String): String {
val shell = createRootShell()
val shell = createRootShell(true)
return ShellUtils.fastCmd(shell, cmd)
}

Expand Down Expand Up @@ -63,7 +63,7 @@ class WebViewInterface(val context: Context, private val webView: WebView) {
processOptions(finalCommand, options)
finalCommand.append(cmd)

val shell = createRootShell()
val shell = createRootShell(true)
val result = shell.newJob().add(finalCommand.toString()).to(ArrayList(), ArrayList()).exec()
val stdout = result.out.joinToString(separator = "\n")
val stderr = result.err.joinToString(separator = "\n")
Expand Down Expand Up @@ -97,7 +97,7 @@ class WebViewInterface(val context: Context, private val webView: WebView) {
finalCommand.append(command)
}

val shell = createRootShell()
val shell = createRootShell(true)

val emitData = fun(name: String, data: String) {
val jsCode =
Expand Down

0 comments on commit e39a80f

Please sign in to comment.