check both edge and msedge binary names, force user-data-dir if edge, even in unsafe mode

Former-commit-id: f469ee39c4
Former-commit-id: ab48e332277f8b5f7a44c6302f515ddf6a1c496c
This commit is contained in:
idk
2022-10-23 12:07:47 -04:00
parent fb71a82527
commit 67454c21fe

View File

@ -276,7 +276,13 @@ public class I2PGenericUnsafeBrowser extends I2PCommonBrowser {
//
public ProcessBuilder baseProcessBuilder(String[] args) {
String browser = findUnsafeBrowserAnywhere();
if (browser.contains("edge.exe") || browser.contains("msedge.exe")){
ArrayList<String> argsList = new ArrayList<String>(Arrays.asList("--user-data-dir="+profileDirectory("","generic","unsafe",false)));
argsList.addAll(Arrays.asList(args));
args = argsList.toArray(args);
}
if (!browser.isEmpty()) {
int arglength = 0;
if (args != null)