Skip to content

Commit 85e68bd

Browse files
author
nitrocaster
committed
Add virtual destructors to server object interfaces.
1 parent 36b3107 commit 85e68bd

File tree

1 file changed

+15
-3
lines changed

1 file changed

+15
-3
lines changed

src/xrServerEntities/xrServer_Objects_Abstract.h

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,11 +29,15 @@ class CDUInterface;
2929
#pragma warning(push)
3030
#pragma warning(disable:4005)
3131

32-
class ISE_Shape{
32+
class ISE_Shape
33+
{
3334
public:
34-
virtual void __stdcall assign_shapes (CShapeData::shape_def* shapes, u32 cnt)=0;
35+
virtual ~ISE_Shape() = 0;
36+
virtual void __stdcall assign_shapes (CShapeData::shape_def* shapes, u32 cnt)=0;
3537
};
3638

39+
IC ISE_Shape::~ISE_Shape() {}
40+
3741
class CSE_Visual
3842
{
3943
public:
@@ -86,10 +90,13 @@ class CSE_Motion
8690
virtual CSE_Motion* __stdcall motion () = 0;
8791
};
8892

89-
struct ISE_AbstractLEOwner{
93+
struct ISE_AbstractLEOwner {
94+
virtual ~ISE_AbstractLEOwner() = 0;
9095
virtual void __stdcall get_bone_xform (LPCSTR name, Fmatrix& xform) = 0;
9196
};
9297

98+
IC ISE_AbstractLEOwner::~ISE_AbstractLEOwner() {}
99+
93100
#pragma pack(push,1)
94101
struct visual_data {
95102
Fmatrix matrix;
@@ -106,6 +113,9 @@ struct ISE_Abstract {
106113
flMotionChange = u32(1 << 3),
107114
flVisualAnimationPauseChange= u32(1 << 4),
108115
};
116+
117+
virtual ~ISE_Abstract() = 0;
118+
109119
Flags32 m_editor_flags;
110120
IC void set_editor_flag (u32 mask) {m_editor_flags.set (mask,TRUE);}
111121

@@ -132,6 +142,8 @@ struct ISE_Abstract {
132142
virtual bool __stdcall validate () = 0;
133143
};
134144

145+
IC ISE_Abstract::~ISE_Abstract() {}
146+
135147
#pragma warning(pop)
136148

137149
#pragma pack(pop)

0 commit comments

Comments
 (0)