hw/uefi: open json file in binary mode
Fixes file length discrepancies due to line ending conversions on windows hosts. Resolves: https://gitlab.com/qemu-project/qemu/-/issues/3058 Reviewed-by: Philippe Mathieu-Daudé <philmd@linaro.org> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Message-ID: <20250811130110.820958-4-kraxel@redhat.com>
This commit is contained in:
parent
fc8ee8fe58
commit
040237436f
1 changed files with 1 additions and 1 deletions
|
|
@ -172,7 +172,7 @@ static GString *uefi_vars_to_json(uefi_vars_state *uv)
|
|||
void uefi_vars_json_init(uefi_vars_state *uv, Error **errp)
|
||||
{
|
||||
if (uv->jsonfile) {
|
||||
uv->jsonfd = qemu_create(uv->jsonfile, O_RDWR, 0666, errp);
|
||||
uv->jsonfd = qemu_create(uv->jsonfile, O_RDWR | O_BINARY, 0666, errp);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue