summaryrefslogtreecommitdiff
path: root/util/inteltool
diff options
context:
space:
mode:
authorPatrick Georgi <pgeorgi@chromium.org>2016-07-29 22:30:20 +0200
committerMartin Roth <martinroth@google.com>2016-07-31 19:16:45 +0200
commit030c73031defb881fe379c002729b55919c5be3a (patch)
treef205f2d0625faad41994bdf8c82b93c5b2f771f9 /util/inteltool
parentbe8f0fa2bb43f80915d0635c06fbfda0285f113f (diff)
downloadcoreboot-030c73031defb881fe379c002729b55919c5be3a.tar.xz
util/inteltool: fix memory leak
A struct pci_dev was allocated but not freed. Change-Id: I6a8bbef6a118fc1f0aa7037e72c4d0dda9208f4b Signed-off-by: Patrick Georgi <pgeorgi@chromium.org> Found-by: Coverity Scan #1353037 Reviewed-on: https://review.coreboot.org/15971 Tested-by: build bot (Jenkins) Reviewed-by: Duncan Laurie <dlaurie@chromium.org> Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net>
Diffstat (limited to 'util/inteltool')
-rw-r--r--util/inteltool/amb.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/util/inteltool/amb.c b/util/inteltool/amb.c
index ca6b9cd471..26bece04e3 100644
--- a/util/inteltool/amb.c
+++ b/util/inteltool/amb.c
@@ -439,6 +439,7 @@ int print_ambs(struct pci_dev *dev, struct pci_access *pacc)
max_channel = pci_read_byte(dev16, 0x56)/max_branch;
max_amb = pci_read_byte(dev16, 0x57);
+ pci_free_dev(dev16);
break;
default: