[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Wesnoth-cvs-commits] wesnoth/src multiplayer_connect.cpp
From: |
David White |
Subject: |
[Wesnoth-cvs-commits] wesnoth/src multiplayer_connect.cpp |
Date: |
Sun, 20 Feb 2005 22:02:55 -0500 |
CVSROOT: /cvsroot/wesnoth
Module name: wesnoth
Branch:
Changes by: David White <address@hidden> 05/02/21 03:02:55
Modified files:
src : multiplayer_connect.cpp
Log message:
changed assertion failure when starting a multiplayer game using a
scenario with no sides to an in-game error message
CVSWeb URLs:
http://savannah.gnu.org/cgi-bin/viewcvs/wesnoth/wesnoth/src/multiplayer_connect.cpp.diff?tr1=1.106&tr2=1.107&r1=text&r2=text
Patches:
Index: wesnoth/src/multiplayer_connect.cpp
diff -u wesnoth/src/multiplayer_connect.cpp:1.106
wesnoth/src/multiplayer_connect.cpp:1.107
--- wesnoth/src/multiplayer_connect.cpp:1.106 Mon Feb 21 00:37:28 2005
+++ wesnoth/src/multiplayer_connect.cpp Mon Feb 21 03:02:55 2005
@@ -1,4 +1,4 @@
-/* $Id: multiplayer_connect.cpp,v 1.106 2005/02/21 00:37:28 Sirp Exp $ */
+/* $Id: multiplayer_connect.cpp,v 1.107 2005/02/21 03:02:55 Sirp Exp $ */
/*
Copyright (C)
Part of the Battle for Wesnoth Project http://www.wesnoth.org
@@ -437,8 +437,10 @@
// Adds the current user as default user.
users_.push_back(connected_user(preferences::login(), CNTR_LOCAL, 0));
- update_user_combos();
- wassert(sides_.size() > 0);
+ update_user_combos();
+ if(sides_.empty()) {
+ throw config::error(_("The scenario is invalid because it has
no sides."));
+ }
int side_choice = 0;
for(side_list::const_iterator s = sides_.begin(); s != sides_.end();
++s) {