You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-17 14:11:06 +00:00
Zero initialize all pointer class and struct members
This prevents the pitfall of UB when checking if they have been assigned something valid by comparing to nullptr.
This commit is contained in:
@@ -37,7 +37,7 @@
|
||||
class CollisionPolygon2DEditor : public AbstractPolygon2DEditor {
|
||||
GDCLASS(CollisionPolygon2DEditor, AbstractPolygon2DEditor);
|
||||
|
||||
CollisionPolygon2D *node;
|
||||
CollisionPolygon2D *node = nullptr;
|
||||
|
||||
protected:
|
||||
virtual Node2D *_get_node() const override;
|
||||
|
||||
Reference in New Issue
Block a user