Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:Step:15-SP1
qemu.12241
0066-sev-i386-fix-memory-leak-in-sev_gue.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File 0066-sev-i386-fix-memory-leak-in-sev_gue.patch of Package qemu.12241
From e0f404694a4b2d135b5df2d75e4f6e8469ed224c Mon Sep 17 00:00:00 2001 From: Greg Kurz <groug@kaod.org> Date: Thu, 29 Mar 2018 11:10:21 +0200 Subject: [PATCH] sev/i386: fix memory leak in sev_guest_init() The string returned by object_property_get_str() is dynamically allocated. Fixes: d8575c6c0242b Signed-off-by: Greg Kurz <groug@kaod.org> Message-Id: <152231462116.69730.14119625999092384450.stgit@bahia.lan> Reviewed-by: Cornelia Huck <cohuck@redhat.com> Reviewed-by: Thomas Huth <thuth@redhat.com> Signed-off-by: Eduardo Habkost <ehabkost@redhat.com> (cherry picked from commit 5d7bc72a4336f922ba42bab545529051c706ac4b) [BR: BSC#1091695] Signed-off-by: Bruce Rogers <brogers@suse.com> --- target/i386/sev.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/target/i386/sev.c b/target/i386/sev.c index 019d84cef2..c01167143f 100644 --- a/target/i386/sev.c +++ b/target/i386/sev.c @@ -748,9 +748,11 @@ sev_guest_init(const char *id) if (s->sev_fd < 0) { error_report("%s: Failed to open %s '%s'", __func__, devname, strerror(errno)); - goto err; } g_free(devname); + if (s->sev_fd < 0) { + goto err; + } ret = sev_platform_ioctl(s->sev_fd, SEV_PLATFORM_STATUS, &status, &fw_error);
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor