[PATCH 1/3] rtems-bin2c.c: Define _GNU_SOURCE for strnlen()

Gedare Bloom gedare at rtems.org
Wed Mar 31 14:55:12 UTC 2021


The --subject-prefix is helpful to guide reviewers.
https://docs.rtems.org/branches/master/eng/vc-users.html#creating-a-patch

On Tue, Mar 30, 2021 at 3:16 PM Joel Sherrill <joel at rtems.org> wrote:
>
> ---
>  misc/bin2c/rtems-bin2c.c | 1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/misc/bin2c/rtems-bin2c.c b/misc/bin2c/rtems-bin2c.c
> index 7ed79dd..397f2ad 100644
> --- a/misc/bin2c/rtems-bin2c.c
> +++ b/misc/bin2c/rtems-bin2c.c
> @@ -25,6 +25,7 @@
>   *
>   */
>
> +#define _GNU_SOURCE // for strnlen
>  #include <ctype.h>
>  #include <stdio.h>
>  #include <stdlib.h>

The feature check for strnlen in glibc is now _POSIX_C_SOURCE >= 200809L


> --
> 1.8.3.1
>
> _______________________________________________
> devel mailing list
> devel at rtems.org
> http://lists.rtems.org/mailman/listinfo/devel


More information about the devel mailing list