Fix some benign warnings with gcc-12.

The string buffer is large enough, but gcc do not understant it.
Easy to avoid these warnings with a larger buffer here.
This commit is contained in:
Milan Broz
2022-02-06 18:03:49 +01:00
parent 685148af00
commit e4091fe8a5
2 changed files with 2 additions and 2 deletions

View File

@@ -215,7 +215,7 @@ static int json_luks1_segments(const struct luks_phdr *hdr_v1, struct json_objec
static int json_luks1_digest(const struct luks_phdr *hdr_v1, struct json_object **digest_object)
{
char keyslot_str[2], *base64_str;
char keyslot_str[16], *base64_str;
int r, ks;
size_t base64_len;
struct json_object *digest_obj, *array, *field;

View File

@@ -67,7 +67,7 @@ struct loop_config {
static char *crypt_loop_get_device_old(void)
{
char dev[20];
char dev[64];
int i, loop_fd;
struct loop_info64 lo64 = {0};