0ad/source
elexis 24f97d9fd5 Fix unreported glooxwrapper leaks following 61261d14fc, refs #2305.
Fixes an occurring leak indicated by the reported clang unused variable
compiler warning, refs #5294, #5550,
by adding the missing glooxwrapper::Jingle::Session::Session destructor
.

Fix two leaks that would have occurred if the according code had been
used:
Delete unused glooxwrapper::Jingle::ICEUDP::ICEUDP instead of adding the
missing destructor.
Delete unused glooxwrapper::Jingle::Content::Content instead of adding
the missing destructor.

Explain why glooxwrapper::Client::registerStanzaExtension doesn't leak
the new StanzaExtensionWrapper.
Explain why glooxwrapper::Jingle::Session::sessionInitiate doesn't leak
the new gloox::Jingle::Content, nor the new gloox::Jingle::ICEUDP.
Explain why glooxwrapper::SessionManager::registerPlugins doesn't leak
the new gloox::Jingle::Content and new gloox::Jingle::ICEUDP.
Explain why glooxwrapper::SessionManager::createSession doesn't leak the
gloox::Jingle::Session.

I will not leak memory in the glooxwrapper.
I will not leak memory in the glooxwrapper.
I will not leak memory in the glooxwrapper.

Use references in the StunClient and glooxwrapper to anticipate any
confusion as to whose obligation it is to delete variables when they are
passed around across several files.
Use static_cast and reinterpret_cast instead of C-style casts in the
StunClient.

Differential Revision: https://code.wildfiregames.com/D2094
Refs D2093 for the reported leaks.
Reviewed By: Josh
Comments By: fcxSanya, Vladislav for D2094, and echotangoecho, leper in
61261d14fc

This was SVN commit r22678.
2019-08-17 00:12:19 +00:00
..
collada Fix compiler warnings on VS 2015, refs #3439, refs #5069. 2018-03-10 09:58:53 +00:00
graphics Fix build without precompiled headers in 107d3d461f. 2019-08-12 12:56:32 +00:00
gui PushGuiPage support for passing a function instead of a function name. 2019-08-16 18:46:04 +00:00
i18n Simple refactoring of Singleton. Make it non-copyable. 2019-01-13 15:11:40 +00:00
lib pthread -> std::thread (4/7) - Replace pthread in remaining files 2019-08-15 09:07:16 +00:00
lobby Fix unreported glooxwrapper leaks following 61261d14fc, refs #2305. 2019-08-17 00:12:19 +00:00
maths Cleanups BoundingBoxAxisAligned and fixes coding styles a bit. 2019-06-12 20:23:14 +00:00
mocks
network Fix unreported glooxwrapper leaks following 61261d14fc, refs #2305. 2019-08-17 00:12:19 +00:00
pch Update precompiled headers to improve build times. 2019-05-26 07:21:12 +00:00
ps Fix unreported glooxwrapper leaks following 61261d14fc, refs #2305. 2019-08-17 00:12:19 +00:00
renderer Fix 2a485c5e3b Wind computation - switch to signed integers. 2019-08-15 17:02:53 +00:00
scriptinterface Replace JS_THIS_OBJECT and JS::CallReceiver in preparation for SpiderMonkey 49 and 61. 2019-08-13 14:11:43 +00:00
simulation2 Hierarchical Pathfinder - Add Global Regions / Optimise MakeGoalReachable 2019-08-12 13:19:01 +00:00
soundmanager pthread -> std::thread (3/7) - Replace pthread in other engine files 2019-08-12 08:16:28 +00:00
third_party Removes deprecated 'register' storage class from mongoose. Refs #3068 2019-07-18 06:28:51 +00:00
tools Fix build without precompiled headers in 107d3d461f. 2019-08-12 12:56:32 +00:00
main.cpp Alt+tab fix for ca9109be75 - call sound IdleTask in Atlas and swap buffers only once in Atlas. 2019-07-24 16:40:34 +00:00
test_setup.cpp Fix string format of the JS test assertion failure following 7c2e9027c2 (cxxtest expects a char* instead of a std::wstring, so newlines were printed as \n characters). 2017-10-13 21:56:45 +00:00