Fix a potential memory leak in crypto/provider_child.c