mirror of
https://github.com/wesnoth/wesnoth
synced 2025-05-03 14:52:26 +00:00
Fix 'Trying to open file with empty name' stdout spam in MP lobby
This commit is contained in:
parent
1399c95cbd
commit
a0b356fa5b
@ -680,7 +680,9 @@ void write_file(const std::string& fname, const std::string& data)
|
||||
|
||||
std::string read_map(const std::string& name)
|
||||
{
|
||||
std::string res = read_file(get_wml_location("maps/" + name));
|
||||
std::string res;
|
||||
std::string map_location = get_wml_location("maps/" + name);
|
||||
if(!map_location.empty()) res = read_file(map_location);
|
||||
|
||||
if (res.empty()) {
|
||||
res = read_file(get_user_data_dir() + "/editor/maps/" + name);
|
||||
|
Loading…
x
Reference in New Issue
Block a user