webui: use global mount namespace by default.
This commit is contained in:
@@ -27,7 +27,7 @@ class WebViewInterface(val context: Context, private val webView: WebView) {
|
|||||||
|
|
||||||
@JavascriptInterface
|
@JavascriptInterface
|
||||||
fun exec(cmd: String): String {
|
fun exec(cmd: String): String {
|
||||||
val shell = createRootShell()
|
val shell = createRootShell(true)
|
||||||
return ShellUtils.fastCmd(shell, cmd)
|
return ShellUtils.fastCmd(shell, cmd)
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -63,7 +63,7 @@ class WebViewInterface(val context: Context, private val webView: WebView) {
|
|||||||
processOptions(finalCommand, options)
|
processOptions(finalCommand, options)
|
||||||
finalCommand.append(cmd)
|
finalCommand.append(cmd)
|
||||||
|
|
||||||
val shell = createRootShell()
|
val shell = createRootShell(true)
|
||||||
val result = shell.newJob().add(finalCommand.toString()).to(ArrayList(), ArrayList()).exec()
|
val result = shell.newJob().add(finalCommand.toString()).to(ArrayList(), ArrayList()).exec()
|
||||||
val stdout = result.out.joinToString(separator = "\n")
|
val stdout = result.out.joinToString(separator = "\n")
|
||||||
val stderr = result.err.joinToString(separator = "\n")
|
val stderr = result.err.joinToString(separator = "\n")
|
||||||
@@ -97,7 +97,7 @@ class WebViewInterface(val context: Context, private val webView: WebView) {
|
|||||||
finalCommand.append(command)
|
finalCommand.append(command)
|
||||||
}
|
}
|
||||||
|
|
||||||
val shell = createRootShell()
|
val shell = createRootShell(true)
|
||||||
|
|
||||||
val emitData = fun(name: String, data: String) {
|
val emitData = fun(name: String, data: String) {
|
||||||
val jsCode =
|
val jsCode =
|
||||||
|
|||||||
Reference in New Issue
Block a user