Adding late-replace envvar filenames to ATT

Change-Id: I5df51934ffa25358503013e1a230adb894d6ff94
This commit is contained in:
Giovanni LB
2024-02-16 14:19:22 -03:00
committed by Giovanni Baraldi
parent a1999fa366
commit fe00badc6e
3 changed files with 43 additions and 6 deletions
+5 -2
View File
@@ -482,12 +482,15 @@ void plugins_load(void* userdata) {
else
plugin_name = "libcli_plugin.so";
}
env_var_replace("OUTPUT_PATH");
bool bIsATT = std::string_view(plugin_name) == "libatt_plugin.so";
if (!bIsATT)
env_var_replace("OUTPUT_PATH");
env_var_replace("OUT_FILE_NAME");
std::string out_path = getenv("OUTPUT_PATH") ? getenv("OUTPUT_PATH") : "";
if (out_path.size()) {
if (out_path.size() && !bIsATT) {
try {
std::experimental::filesystem::create_directories(out_path);
} catch (...) {