mirror of
https://github.com/xpipe-io/xpipe.git
synced 2024-11-21 23:20:23 +00:00
Fix powershell temp dir stack overflow
This commit is contained in:
parent
d482c23cf6
commit
e91b6da9dd
1 changed files with 4 additions and 6 deletions
|
@ -23,13 +23,11 @@ public class XPipeTempDirectory {
|
|||
var base = proc.getOsType().getTempDirectory(proc);
|
||||
var dir = FileNames.join(base, "xpipe");
|
||||
|
||||
if (!proc.getShellDialect().createFileExistsCommand(proc, dir).executeAndCheck()) {
|
||||
proc.executeSimpleCommand(proc.getShellDialect().getMkdirsCommand(dir),
|
||||
"Unable to access or create temporary directory " + dir);
|
||||
proc.executeSimpleCommand(proc.getShellDialect().getMkdirsCommand(dir),
|
||||
"Unable to access or create temporary directory " + dir);
|
||||
|
||||
if (proc.getOsType().equals(OsType.LINUX) || proc.getOsType().equals(OsType.MACOS)) {
|
||||
proc.executeSimpleCommand("chmod -f 777 \"" + dir + "\"");
|
||||
}
|
||||
if (proc.getOsType().equals(OsType.LINUX) || proc.getOsType().equals(OsType.MACOS)) {
|
||||
proc.executeSimpleCommand("chmod -f 777 \"" + dir + "\"");
|
||||
}
|
||||
|
||||
return dir;
|
||||
|
|
Loading…
Reference in a new issue