Examples | Examples need warnings addressed from RTEMS warnings update (#9)
Somil Gupta (@somil)
gitlab at rtems.org
Thu Mar 5 22:15:57 UTC 2026
Somil Gupta commented: https://gitlab.rtems.org/rtems/rtos/rtems-examples/-/issues/9#note_144441
I've opened a merge request to address the warning in `ticker/low_ticker2/init.c`. The code previously used `%zd` for `uptime.tv_sec`, which expects a `size_t`, while `tv_sec` is `time_t`. I updated the format specifier to `%ld` and cast `uptime.tv_sec` to `long` so the argument type matches the specifier.
I chose `long` instead of `long long` this keeps the formatting portable while removing the warning seen .
Please let me know if you’d prefer a different approach.
@joel
--
View it on GitLab: https://gitlab.rtems.org/rtems/rtos/rtems-examples/-/issues/9#note_144441
You're receiving this email because of your account on gitlab.rtems.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rtems.org/pipermail/bugs/attachments/20260305/bd004636/attachment.htm>
More information about the bugs
mailing list