projects
/
oweals
/
minetest.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
11723cf
)
Add missing sao->isGone() checks
author
sfan5
<sfan5@live.de>
Mon, 18 May 2020 21:23:25 +0000
(23:23 +0200)
committer
sfan5
<sfan5@live.de>
Mon, 18 May 2020 21:23:25 +0000
(23:23 +0200)
fixes #9883
src/collision.cpp
patch
|
blob
|
history
src/serverenvironment.cpp
patch
|
blob
|
history
diff --git
a/src/collision.cpp
b/src/collision.cpp
index 06ef820c5095b3cf8d5118ace2749c23dc34e317..d85a5688435a516b879c35a1b7811f7cdb2ce423 100644
(file)
--- a/
src/collision.cpp
+++ b/
src/collision.cpp
@@
-397,7
+397,8
@@
collisionMoveResult collisionMoveSimple(Environment *env, IGameDef *gamedef,
// we directly use the callback to populate the result to prevent
// a useless result loop here
auto include_obj_cb = [self, &objects] (ServerActiveObject *obj) {
- if (!self || (self != obj && self != obj->getParent())) {
+ if (!obj->isGone() &&
+ (!self || (self != obj && self != obj->getParent()))) {
objects.push_back((ActiveObject *)obj);
}
return false;
diff --git
a/src/serverenvironment.cpp
b/src/serverenvironment.cpp
index 6bf7399cff43c8625e745c3947e25686c1fd41a4..d485c32e8111323548bedf15786d5bacfe0cd0e9 100644
(file)
--- a/
src/serverenvironment.cpp
+++ b/
src/serverenvironment.cpp
@@
-1623,6
+1623,8
@@
void ServerEnvironment::getSelectedActiveObjects(
const v3f line_vector = shootline_on_map.getVector();
for (auto obj : objs) {
+ if (obj->isGone())
+ continue;
aabb3f selection_box;
if (!obj->getSelectionBox(&selection_box))
continue;