diff --git a/link.cpp b/link.cpp index 3eed87e..afcfa7c 100644 --- a/link.cpp +++ b/link.cpp @@ -555,6 +555,7 @@ void finish(void) { resolve(); print_symbols(); + if (save_file.empty()) save_file = "gs.out"; try { save_omf(save_file, segments, compress, express); set_file_type(save_file, ftype, atype); diff --git a/main.cpp b/main.cpp index 623918b..e23f7e2 100644 --- a/main.cpp +++ b/main.cpp @@ -105,7 +105,7 @@ static bool is_S(std::string_view sv) { bool verbose = false; -std::string save_file = "gs.out"; +std::string save_file; bool express = true; bool compress = true;