lib: uefi: reset out parameters earlier

Make sure they are always reset, no matter the code branches later on.

This is mostly code motion.
This commit is contained in:
Pino Toscano
2020-01-15 17:11:58 +01:00
parent 9484136fd0
commit 777a21b16b

View File

@@ -56,6 +56,9 @@
int
guestfs_int_get_uefi (guestfs_h *g, char **code, char **vars, int *flags)
{
*code = *vars = NULL;
*flags = 0;
#ifdef __aarch64__
size_t i;
@@ -102,7 +105,5 @@ guestfs_int_get_uefi (guestfs_h *g, char **code, char **vars, int *flags)
#endif
/* Not found. */
*code = *vars = NULL;
*flags = 0;
return 0;
}