aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPerttu Ahola <celeron55@gmail.com>2011-11-27 13:19:20 +0200
committerPerttu Ahola <celeron55@gmail.com>2011-11-29 19:13:55 +0200
commit2e42391b869f8e0290ac9f5c94b9529c5e410d02 (patch)
tree785970cc3af0d2425f59516cc7cd5e1823c75d2d
parent21bd67907606ee89981951a626710b5d73222375 (diff)
downloadminetest-2e42391b869f8e0290ac9f5c94b9529c5e410d02.tar.gz
minetest-2e42391b869f8e0290ac9f5c94b9529c5e410d02.tar.bz2
minetest-2e42391b869f8e0290ac9f5c94b9529c5e410d02.zip
Fix mod dependency sort
-rw-r--r--src/server.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/server.cpp b/src/server.cpp
index f3e497ff1..4797965f2 100644
--- a/src/server.cpp
+++ b/src/server.cpp
@@ -986,7 +986,7 @@ static core::list<ModSpec> getMods(core::list<std::string> &modspaths)
mods_sorted.push_back(mod);
for(core::list<ModSpec>::Iterator i = mods_unsorted.begin();
i != mods_unsorted.end(); i++){
- ModSpec mod2 = *i;
+ ModSpec &mod2 = *i;
if(mod2.unsatisfied_depends.empty())
continue;
mod2.unsatisfied_depends.erase(mod.name);
@@ -998,7 +998,7 @@ static core::list<ModSpec> getMods(core::list<std::string> &modspaths)
// Check unsatisfied dependencies
for(core::list<ModSpec>::Iterator i = mods_unsorted.begin();
i != mods_unsorted.end(); i++){
- ModSpec mod = *i;
+ ModSpec &mod = *i;
if(mod.unsatisfied_depends.empty())
continue;
errorstream<<"mod \""<<mod.name