Re: format-truncation

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, 14 Feb 2019 at 10:52, Kalamatee <kalamatee@xxxxxxxxx> wrote:
>
> it is used by acpica to implement snprintf and sprint -:
>
> https://github.com/acpica/acpica/blob/master/source/components/utilities/utprint.c
>
> see line 837.
>
> Clearly Format and Args aren't known at compile time, however the invocation is correct and valid so I don't get why the incorrect warning is shown.
>
> (I could understand a message similar to other -format ones that suggest the operation may overflow the buffer - but that's not what the diagnostic says, it implies the second parameter cant be over INT_MAX).

It doesn't say it can't be over INT_MAX, it just warns you that it is
over INT_MAX (because that means no checking on the output length).



[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux