[libvirt] [PATCH] hash: fix memory leak and regression