bug-gnulib
[Top][All Lists]
Advanced

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

Re: sys/stat.h and nlink


From: Jim Meyering
Subject: Re: sys/stat.h and nlink
Date: Wed, 14 Jan 2009 20:00:39 +0100

Simon Josefsson <address@hidden> wrote:
> The test-sys_stat self-test fails on debian etch x86, see:
>
> http://autobuild.josefsson.org/gnulib/log-200901140954236318000.txt
>
> The problem is that sys/stat.h does not define nlink_t (at least not
> unconditionally), however sys/types.h does:
>
> address@hidden:~$ cat>foo.c
> #include <sys/stat.h>
> int main (void) { nlink_t foo; }
> address@hidden:~$ gcc -o foo foo.c
> foo.c: In function 'main':
> foo.c:2: error: 'nlink_t' undeclared (first use in this function)
> foo.c:2: error: (Each undeclared identifier is reported only once
> foo.c:2: error: for each function it appears in.)
> foo.c:2: error: expected ';' before 'foo'
> address@hidden:~$ cat>bar.c
> #include <sys/types.h>
> int main (void) { nlink_t foo; }
> address@hidden:~$ gcc -o bar bar.c
>
> I see two solutions.  I pushed 2).  Thoughts?

Your change looks fine.
Thanks!




reply via email to

[Prev in Thread] Current Thread [Next in Thread]