Fix memory leak in HostManager.
Merge branch 'release_31' into development

Fix memory leak in HostManager.