]> git.ipfire.org Git - thirdparty/grub.git/commit
json: Get rid of casts for "jsmntok_t"
authorPatrick Steinhardt <ps@pks.im>
Thu, 16 Apr 2020 10:20:15 +0000 (12:20 +0200)
committerDaniel Kiper <daniel.kiper@oracle.com>
Tue, 21 Apr 2020 20:16:41 +0000 (22:16 +0200)
commite933feb5786b0c5817b2f6e7f306bf559329186a
tree861b2b659cd7eedb0438c910b30c551b5c6861ad
parent3b81607b55cdd399543e1a9fae2f4fdd42934b61
json: Get rid of casts for "jsmntok_t"

With the upstream change having landed that adds a name to the
previously anonymous "jsmntok" typedef, we can now add a forward
declaration for that struct in our code. As a result, we no longer have
to store the "tokens" member of "struct grub_json" as a void pointer but
can instead use the forward declaration, allowing us to get rid of casts
of that field.

Signed-off-by: Patrick Steinhardt <ps@pks.im>
Reviewed-by: Daniel Kiper <daniel.kiper@oracle.com>
grub-core/lib/json/json.c
grub-core/lib/json/json.h