[wesnoth-commits] [wesnoth/wesnoth] f5626d: Campaignd: made use of vector::at

GitHub noreply at github.com
Thu Apr 26 09:56:15 UTC 2018


  Branch: refs/heads/master
  Home:   https://github.com/wesnoth/wesnoth
  Commit: f5626ddc301f4762b488d1006b20123fe9c8edcd
      https://github.com/wesnoth/wesnoth/commit/f5626ddc301f4762b488d1006b20123fe9c8edcd
  Author: Charles Dang <exodia339 at gmail.com>
  Date:   2018-04-26 (Thu, 26 Apr 2018)

  Changed paths:
    M src/campaign_server/control.hpp

  Log Message:
  -----------
  Campaignd: made use of vector::at

This work since vector::at throws if i < size(), and the current check was for
> size() - 1, which equated to >= size(), which is equivalent to not < size().

It does lose the error message, though.




More information about the Commits mailing list