]> git.ipfire.org Git - thirdparty/grub.git/commit
cryptodisk: Move global variables into grub_cryptomount_args struct
authorGlenn Washburn <development@efficientek.com>
Thu, 9 Dec 2021 17:14:57 +0000 (11:14 -0600)
committerDaniel Kiper <daniel.kiper@oracle.com>
Thu, 23 Dec 2021 01:31:44 +0000 (02:31 +0100)
commitebdd82b00ce9d35325b9b46f2a566198f031abe3
tree85efb6ae46a1c266bf5e27de7059c78976bec6fd
parentba9fb5d721aae1d6f95f4a53f5f42042699b2f7d
cryptodisk: Move global variables into grub_cryptomount_args struct

Note that cargs.search_uuid does not need to be initialized in various parts
of the cryptomount argument parsing, just once when cargs is declared with
a struct initializer. The previous code used a global variable which would
retain the value across cryptomount invocations.

Signed-off-by: Glenn Washburn <development@efficientek.com>
Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com>
grub-core/disk/cryptodisk.c
grub-core/disk/geli.c
grub-core/disk/luks.c
grub-core/disk/luks2.c
include/grub/cryptodisk.h