mirror of
https://git.proxmox.com/git/fwupd
synced 2025-07-27 06:10:13 +00:00
trivial: Fix style for fu-fuzzer-firmware.c
This was skipped because pre-commit identified c.in as text not C.
This commit is contained in:
parent
40c7f7ba21
commit
b70d3a73e8
@ -5,6 +5,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "config.h"
|
#include "config.h"
|
||||||
|
|
||||||
#include "@INCLUDE@"
|
#include "@INCLUDE@"
|
||||||
|
|
||||||
int
|
int
|
||||||
@ -17,7 +18,8 @@ LLVMFuzzerTestOneInput (const guint8 *data, gsize size)
|
|||||||
g_setenv("G_DEBUG", "fatal-criticals", FALSE);
|
g_setenv("G_DEBUG", "fatal-criticals", FALSE);
|
||||||
ret = fu_firmware_parse(firmware, fw, FWUPD_INSTALL_FLAG_NONE, NULL);
|
ret = fu_firmware_parse(firmware, fw, FWUPD_INSTALL_FLAG_NONE, NULL);
|
||||||
if (!ret && fu_firmware_has_flag(firmware, FU_FIRMWARE_FLAG_HAS_CHECKSUM)) {
|
if (!ret && fu_firmware_has_flag(firmware, FU_FIRMWARE_FLAG_HAS_CHECKSUM)) {
|
||||||
ret = fu_firmware_parse (firmware, fw,
|
ret = fu_firmware_parse(firmware,
|
||||||
|
fw,
|
||||||
FWUPD_INSTALL_FLAG_NO_SEARCH |
|
FWUPD_INSTALL_FLAG_NO_SEARCH |
|
||||||
FWUPD_INSTALL_FLAG_IGNORE_VID_PID |
|
FWUPD_INSTALL_FLAG_IGNORE_VID_PID |
|
||||||
FWUPD_INSTALL_FLAG_IGNORE_CHECKSUM,
|
FWUPD_INSTALL_FLAG_IGNORE_CHECKSUM,
|
||||||
@ -27,10 +29,8 @@ LLVMFuzzerTestOneInput (const guint8 *data, gsize size)
|
|||||||
g_autofree gchar *str = fu_firmware_to_string(firmware);
|
g_autofree gchar *str = fu_firmware_to_string(firmware);
|
||||||
g_autoptr(GBytes) fw2 = fu_firmware_write(firmware, NULL);
|
g_autoptr(GBytes) fw2 = fu_firmware_write(firmware, NULL);
|
||||||
g_print("%s", str);
|
g_print("%s", str);
|
||||||
if (fw2 != NULL) {
|
if (fw2 != NULL)
|
||||||
g_print ("[%" G_GSIZE_FORMAT " bytes]\n",
|
g_print("[%" G_GSIZE_FORMAT " bytes]\n", g_bytes_get_size(fw2));
|
||||||
g_bytes_get_size (fw2));
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user