Fix issue #795 — Struct dtor called twice under some circumstances
Merge pull request #799 from AlexeyProkhin/issue795

Fix issue #795 — Struct dtor called twice under some circumstances