diff --git a/src/action.py b/src/action.py index 63abca2..07cd498 100644 --- a/src/action.py +++ b/src/action.py @@ -110,8 +110,8 @@ def start(pkg_name: str, data_list: list, cmd: str) -> list: def save_action(actions_list: list) -> None: tmp_filename = "PEinjector.tmp" log.info(f"save action list to {config.TEMP_DIR.replace( - '{TEMP}', os.environ['TEMP'].replace("\\", "/"))+'/'+tmp_filename}") - with open(config.TEMP_DIR.replace("{TEMP}", os.environ["TEMP"])+"/"+tmp_filename, "wb") as file: + '{TEMP}', "X:\\PEinjector")+'\\'+tmp_filename}") + with open(config.TEMP_DIR.replace("{TEMP}", "X:\\PEinjector")+"\\"+tmp_filename, "wb") as file: pickle.dump(actions_list, file) return tmp_filename diff --git a/src/hook.pyw b/src/hook.pyw index 41f8a28..bac03e9 100644 --- a/src/hook.pyw +++ b/src/hook.pyw @@ -68,7 +68,7 @@ while 1: # load action list log.info("load action \"onload\"") -with open(config.TEMP_DIR.replace("{TEMP}", os.environ["TEMP"])+"/"+"PEinjector.tmp", "rb") as file: +with open(config.TEMP_DIR.replace("{TEMP}", "X:\\PEinjector")+"\\"+"PEinjector.tmp", "rb") as file: lists = pickle.load(file) alog = action.do_action(lists) with open(config.ACTIONLOGPATH.replace("{DISK}", utils.find_disk()), "w") as file: