rp2040_flash: Fix the type when printing num_blocks (#6279)

image->num_blocks is of type unsigned size_t thus unsigned int
or unsigned long int.

%lu specifies a type of long unsigned int. Thus resulting in compiler warning about type mismatch on some systems.
Fix this by printing the value with length modified z.

Signed-off-by: Martin Botka <martin.botka@somainline.org>
This commit is contained in:
Martin Botka 2023-07-28 02:34:32 +02:00 committed by GitHub
parent d725dfd309
commit ba4eed175d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -174,7 +174,7 @@ int main(int argc, char *argv[]) {
rc = 1; rc = 1;
goto do_exit; goto do_exit;
} }
fprintf(stderr, "Loaded UF2 image with %lu pages\n", image->num_blocks); fprintf(stderr, "Loaded UF2 image with %zu pages\n", image->num_blocks);
bool has_target = false; bool has_target = false;
uint8_t target_bus = 0; uint8_t target_bus = 0;