fileio: make read_full_file_full() usable with size and READ_FULL_FILE_UNBASE64
authorYu Watanabe <watanabe.yu+github@gmail.com>
Sun, 1 Oct 2023 07:48:36 +0000 (16:48 +0900)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Mon, 2 Oct 2023 01:36:43 +0000 (10:36 +0900)
commit7e2a5fbd851bf195a45c650dacad45d6456910bd
tree660712a3deca10902778d7cea9fc74c5d7026483
parentb503c766898387f872c93300f64b6bdcf44c439f
fileio: make read_full_file_full() usable with size and READ_FULL_FILE_UNBASE64

When READ_FULL_FILE_UNBASE64 (or READ_FULL_FILE_UNHEX) is specified,
setting size argument by caller is difficult, as it is hard to estimate
the encoded length.

This makes when size is specified with decoding option, let's read file
more, and check decoded size later with the specified size.
src/basic/fileio.c