mirror of
https://github.com/Ylianst/MeshCentral.git
synced 2024-12-23 14:01:43 +03:00
Fixed Powershell crash
This commit is contained in:
parent
bac1a1010b
commit
d2483e6acf
@ -134,8 +134,12 @@ function windows_terminal() {
|
||||
|
||||
this.PowerShellCapable = function()
|
||||
{
|
||||
if (require('os').arch() == 'x64') {
|
||||
return (require('fs').existsSync(process.env['windir'] + '\\SysWow64\\WindowsPowerShell\\v1.0\\powershell.exe'));
|
||||
} else {
|
||||
return (require('fs').existsSync(process.env['windir'] + '\\System32\\WindowsPowerShell\\v1.0\\powershell.exe'));
|
||||
}
|
||||
}
|
||||
|
||||
this.StartEx = function Start(CONSOLE_SCREEN_WIDTH, CONSOLE_SCREEN_HEIGHT, terminalTarget)
|
||||
{
|
||||
@ -219,9 +223,16 @@ function windows_terminal() {
|
||||
return (this.StartEx(CONSOLE_SCREEN_WIDTH, CONSOLE_SCREEN_HEIGHT, process.env['windir'] + '\\System32\\cmd.exe'));
|
||||
}
|
||||
this.StartPowerShell = function StartPowerShell(CONSOLE_SCREEN_WIDTH, CONSOLE_SCREEN_HEIGHT)
|
||||
{
|
||||
if (require('os').arch() == 'x64')
|
||||
{
|
||||
return (this.StartEx(CONSOLE_SCREEN_WIDTH, CONSOLE_SCREEN_HEIGHT, process.env['windir'] + '\\SysWow64\\WindowsPowerShell\\v1.0\\powershell.exe'));
|
||||
}
|
||||
else
|
||||
{
|
||||
return (this.StartEx(CONSOLE_SCREEN_WIDTH, CONSOLE_SCREEN_HEIGHT, process.env['windir'] + '\\System32\\WindowsPowerShell\\v1.0\\powershell.exe'));
|
||||
}
|
||||
}
|
||||
|
||||
this._stop = function () {
|
||||
if (this.stopping) { return (this.stopping); }
|
||||
|
File diff suppressed because one or more lines are too long
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "meshcentral",
|
||||
"version": "0.3.8-n",
|
||||
"version": "0.3.8-o",
|
||||
"keywords": [
|
||||
"Remote Management",
|
||||
"Intel AMT",
|
||||
|
Loading…
Reference in New Issue
Block a user