Merge pull request #517 from marckleinebudde/bcmserver-fix-warning

bcmserver: use pragma to silence gnu-variable-sized-type-not-at-end warning
pull/537/head
Marc Kleine-Budde 2024-05-28 11:39:43 +02:00 committed by GitHub
commit c2e40edd24
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 5 additions and 2 deletions

View File

@ -155,10 +155,13 @@ int main(void)
char format[FORMATSZ];
char rxmsg[50];
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wgnu-variable-sized-type-not-at-end"
struct {
struct bcm_msg_head msg_head;
struct can_frame frame;
} msg;
#pragma GCC diagnostic pop
if (snprintf(format, FORMATSZ, "< %%%ds %%c %%lu %%lu %%x %%hhu "
"%%hhx %%hhx %%hhx %%hhx %%hhx %%hhx "