--- src/parallels/parallels_utils.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/parallels/parallels_utils.c b/src/parallels/parallels_utils.c index 171f5d0..0b589ab 100644 --- a/src/parallels/parallels_utils.c +++ b/src/parallels/parallels_utils.c @@ -135,8 +135,10 @@ parallelsAddFileExt(const char *path, const char *ext) return NULL; } - if (!virStrcpy(new_path, path, len)) + if (!virStrcpy(new_path, path, len)) { + VIR_FREE(new_path); return NULL; + } strcat(new_path, ext); return new_path; -- 1.7.11.7 -- libvir-list mailing list libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list