[move_units_fake]: fixed a segfault

This commit is contained in:
Elvish_Hunter 2015-05-09 21:55:56 +02:00
parent cea5239bb5
commit 31436e85bb
3 changed files with 5 additions and 1 deletions

View file

@ -27,6 +27,7 @@ Version 1.13.0+dev:
displaying stdout+stderr (Windows-only).
* Updated mainline campaigns and multiplayer scenarios to use [filter] status=
instead of [filter] [filter_wml] [status]
* Fixed a segfault in [move_units_fake]
Version 1.13.0:
* Security fixes:

View file

@ -18,6 +18,9 @@ Version 1.13.0+dev:
* Units:
* Fixed the Shuja not having the default AMLA.
* Miscellaneous and bug fixes:
* Fixed a segfault in [move_units_fake]
Version 1.13.0:
* Security fixes:

View file

@ -768,7 +768,7 @@ WML_HANDLER_FUNCTION(move_units_fake, /*event_info*/, cfg)
const std::vector<std::string> yvals = utils::split(config["y"]);
int skip_steps = config["skip_steps"];
fake_unit_ptr u = create_fake_unit(config);
units[paths.size()] = u;
units.push_back(u);
paths.push_back(fake_unit_path(*u, xvals, yvals));
if(skip_steps > 0)
paths.back().insert(paths.back().begin(), skip_steps, paths.back().front());