Merge remote-tracking branch 'remotes/philmd-gitlab/tags/fw_cfg-20200918' into staging
fw_cfg patches
Fixes a bug in the recently introduced fw_cfg_add_from_generator().
CI jobs results:
. https://gitlab.com/philmd/qemu/-/pipelines/191714875
. https://travis-ci.org/github/philmd/qemu/builds/728288784
. https://app.shippable.com/github/philmd/qemu/runs/869/1/console
# gpg: Signature made Fri 18 Sep 2020 16:20:56 BST
# gpg: using RSA key FAABE75E12917221DCFD6BB2E3E32C2CDEADC0DE
# gpg: Good signature from "Philippe Mathieu-Daudé (F4BUG) <f4bug@amsat.org>" [full]
# Primary key fingerprint: FAAB E75E 1291 7221 DCFD 6BB2 E3E3 2C2C DEAD C0DE
* remotes/philmd-gitlab/tags/fw_cfg-20200918:
hw/nvram/fw_cfg: fix FWCfgDataGeneratorClass::get_data() consumption
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
diff --git a/hw/nvram/fw_cfg.c b/hw/nvram/fw_cfg.c
index f3a4728..0e95d05 100644
--- a/hw/nvram/fw_cfg.c
+++ b/hw/nvram/fw_cfg.c
@@ -1056,7 +1056,7 @@
return false;
}
size = array->len;
- fw_cfg_add_file(s, filename, g_byte_array_free(array, TRUE), size);
+ fw_cfg_add_file(s, filename, g_byte_array_free(array, FALSE), size);
return true;
}