In sockets, derived class is deallocated first, then the base class.

Signed-off-by: Martin Sustrik <sustrik@250bpm.com>