[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] Re: [PATCH] docs/misra: rules for mass adoption
On 23.05.2024 03:26, Stefano Stabellini wrote: > @@ -725,12 +787,25 @@ maintainers if you want to suggest a change. > - The Standard Library function system of <stdlib.h> shall not be used > - > > + * - `Rule 22.1 > <https://gitlab.com/MISRA/MISRA-C/MISRA-C-2012/Example-Suite/-/blob/master/R_22_01.c>`_ > + - Required > + - All resources obtained dynamically by means of Standard Library > + functions shall be explicitly released > + - > + - Xen doesn't provide, use, or link against a Standard Library > [#xen-stdlib]_ The empty sub-bullet-point looks stray here. > @@ -748,6 +823,31 @@ maintainers if you want to suggest a change. > stream has been closed > - > > + * - `Rule 22.7 > <https://gitlab.com/MISRA/MISRA-C/MISRA-C-2012/Example-Suite/-/blob/master/R_22_07.c>`_ > + - Required > + - The macro EOF shall only be compared with the unmodified return > + value from any Standard Library function capable of returning EOF > + - Xen doesn't provide, use, or link against a Standard Library > [#xen-stdlib]_ Shouldn't this remark also be replicated ... > + * - `Rule 22.8 > <https://gitlab.com/MISRA/MISRA-C/MISRA-C-2012/Example-Suite/-/blob/master/R_22_08.c>`_ > + - Required > + - The value of errno shall be set to zero prior to a call to an > + errno-setting-function > + - > + > + * - `Rule 22.9 > <https://gitlab.com/MISRA/MISRA-C/MISRA-C-2012/Example-Suite/-/blob/master/R_22_09.c>`_ > + - Required > + - The value of errno shall be tested against zero after calling an > + errno-setting-function > + - > + > + * - `Rule 22.10 > <https://gitlab.com/MISRA/MISRA-C/MISRA-C-2012/Example-Suite/-/blob/master/R_22_10.c>`_ > + - Required > + - The value of errno shall only be tested when the last function to > + be called was an errno-setting-function > + - ... for all three of these, seeing that errno is something a (standard) library would provide? Or alternatively should remarks here say that we simply have no errno? Jan
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |