hostmem-file: fixed the memory leak while get pmem path.
commita1f3bb1845e23c38c3bb6ca5e90ac184cfaf1a57
authorZhang Yi <yi.z.zhang@linux.intel.com>
Tue, 28 Aug 2018 16:14:22 +0000 (29 00:14 +0800)
committerEduardo Habkost <ehabkost@redhat.com>
Wed, 24 Oct 2018 09:44:59 +0000 (24 06:44 -0300)
treebcb01f03d6bd34a83fe4c0e8a3b9da0f4d816127
parent13399aad4fa87b2878c49d02a5d3bafa6c966ba3
hostmem-file: fixed the memory leak while get pmem path.

object_get_canonical_path_component() returns a string which
must be freed using g_free().

Reported-by: Peter Maydell <peter.maydell@linaro.org>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Zhang Yi <yi.z.zhang@linux.intel.com>
Message-Id: <7328fb16c394eaf5d65437d11c2a9343647b6d3d.1535471899.git.yi.z.zhang@linux.intel.com>
Reviewed-by: Eduardo Habkost <ehabkost@redhat.com>
Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
backends/hostmem-file.c