The following sequence of events and conditions will cause a segfault to
occur:
1. Delete a misc_model
2. Undo the delete
3. Delete the same model again
4. Undo the delete
A segfault will occur in CEntityMiscModel::Draw when m_model is
dereferenced as it has been deleted and cleared.
When cloning the misc_model entity, a new CEntityMiscModel is created and
the name is set. However, CEntityMiscModel::BuildCacheRequestString relies
on all epairs to be present before being able to generate the *correct*
request string for the misc_model. Not doing so will cause incorrect
behaviour - in this case, the reference count for the CEntityMiscModel is
decremented one too many times and causes the object to be deleted. The
misc_model object is then used later on after it has been freed.
This commit fixes the problem by copying all epairs, before firing the
OnKeyValueChanged events. This way, all epairs will be available when
BuildCacheRequestString is called.
A couple of things are broken right now:
- OpenGL font in Windows not appearing (expected to be broken, will fix)
- Linux build broken because it loads some .vcproj files that are removed
- 3rd party libs are downloaded from porky.nerius.com, not id Software
git-svn-id: svn://svn.icculus.org/gtkradiant/GtkRadiant/trunk@473 8a3a26a2-13c4-0310-b231-cf6edde360e5
fixed/optimized a number of VC9 project settings
fixed sprintf being hijacked by intl.dll stuff
git-svn-id: svn://svn.icculus.org/gtkradiant/GtkRadiant/trunk@345 8a3a26a2-13c4-0310-b231-cf6edde360e5
made Visual Studio files work in VS2005 Express
fixed a ton of warnings in VS2005 Express
fixed some compile problems on OpenSUSE 11.0
git-svn-id: svn://svn.icculus.org/gtkradiant/GtkRadiant/trunk@302 8a3a26a2-13c4-0310-b231-cf6edde360e5