[PATCH v2 7/9] coresight: Fix resource leaks on coresight_build_path() errors