Re: [PATCH 1/2] selftests/mlock2: Add missing #define _GNU_SOURCE

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

 



On Mon, 09 Nov 2015, Geert Uytterhoeven wrote:

> On glibc 2.3.6:
> 
>     mlock2-tests.c: In function 'seek_to_smaps_entry':
>     mlock2-tests.c:158: warning: implicit declaration of function 'getline'
> 
> According to the manpage of getline(), it needs _GNU_SOURCE before glibc
> 2.10.
> 
> Signed-off-by: Geert Uytterhoeven <geert@xxxxxxxxxxxxxx>

Acked-by: Eric B Munson <emunson@xxxxxxxxxx>

> ---
>  tools/testing/selftests/vm/mlock2-tests.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/tools/testing/selftests/vm/mlock2-tests.c b/tools/testing/selftests/vm/mlock2-tests.c
> index 4431994aade2ef6f..cb247219f1f72889 100644
> --- a/tools/testing/selftests/vm/mlock2-tests.c
> +++ b/tools/testing/selftests/vm/mlock2-tests.c
> @@ -1,3 +1,4 @@
> +#define _GNU_SOURCE
>  #include <sys/mman.h>
>  #include <stdint.h>
>  #include <stdio.h>
> -- 
> 1.9.1
> 

Attachment: signature.asc
Description: Digital signature


[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux