Project::OSiRiON - Git repositories
Project::OSiRiON
News . About . Screenshots . Downloads . Forum . Wiki . Tracker . Git
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStijn Buys <ingar@osirion.org>2010-02-21 12:36:17 +0000
committerStijn Buys <ingar@osirion.org>2010-02-21 12:36:17 +0000
commit730c452ff5896ed66114e6b2153add9379edef5c (patch)
tree353c7c0449deb41f3396d776c0437a4141383d01 /src/core/info.cc
parent745b4e04e5f23a02e5d9b12ebabf38d6dd034136 (diff)
network info messages bugfixes
Diffstat (limited to 'src/core/info.cc')
-rw-r--r--src/core/info.cc6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/core/info.cc b/src/core/info.cc
index dc7a8b3..5615f8b 100644
--- a/src/core/info.cc
+++ b/src/core/info.cc
@@ -196,9 +196,11 @@ void Info::receive_server_update(std::istream &is)
set_modelname(n);
// read info text
- clear_text();
size_t s;
- is >> s;
+ if (!(is >> s))
+ s = 0;
+
+ clear_text();
for (size_t i = 0; (i < s) && is.good(); i++) {
n.clear();
while ((is.get(c)) && (c != '"'));