[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: linkat test on AIX 7.1BETA
From: |
Bruno Haible |
Subject: |
Re: linkat test on AIX 7.1BETA |
Date: |
Sat, 31 Jul 2010 13:04:44 +0200 |
User-agent: |
KMail/1.9.9 |
Hello Rainer,
> > test-link.h:117: assertion failed
> > FAIL: test-linkat
> test_link(func = 0x200009a0, print = 1), line 117 in "test-link.h"
> main(), line 89 in "test-linkat.c"
> ...
> There is a second trap:
>
> ASSERT (func (BASE "a", BASE "c/") == -1);
>
> I have checked the return of func(), its 0.
Can you please show the output of this test program? If it's as expected,
I'll turn it into an autoconf test.
===============================================================================
#define _GNU_SOURCE 1
#define _ALL_SOURCE 1
#include <unistd.h>
#include <fcntl.h>
#include <errno.h>
#include <stdio.h>
int main ()
{
int fd;
int err;
int ret;
/* Ensure a clean working area. */
unlink ("conftesta");
unlink ("conftestb");
unlink ("conftestc");
unlink ("conftestd");
/* Create a regular file. */
fd = open ("conftesta", O_CREAT | O_EXCL | O_WRONLY, 0600);
if (fd < 0)
return 1;
if (write (fd, "hello", 5) < 5)
return 2;
if (close (fd) < 0)
return 3;
/* Test whether hard links are supported on the current device. */
if (linkat (AT_FDCWD, "conftesta", AT_FDCWD, "conftestb", AT_SYMLINK_FOLLOW)
< 0)
return 0;
/* Test whether a trailing "/" is treated like "/.". */
ret = linkat (AT_FDCWD, "conftesta/", AT_FDCWD, "conftestc",
AT_SYMLINK_FOLLOW);
err = errno;
fprintf (stderr, "ret = %d\n", ret);
if (ret < 0)
{
fprintf (stderr, "errno = %d\n", err);
errno = err;
perror ("");
}
ret = linkat (AT_FDCWD, "conftesta", AT_FDCWD, "conftestd/",
AT_SYMLINK_FOLLOW);
err = errno;
fprintf (stderr, "ret = %d\n", ret);
if (ret < 0)
{
fprintf (stderr, "errno = %d\n", err);
errno = err;
perror ("");
}
return 0;
}
===============================================================================
Bruno
- Re: dirfd on AIX 7.1BETA, (continued)
- iconv test on AIX 7.1BETA, Bruno Haible, 2010/07/30
- Re: iconv test on AIX 7.1BETA, Rainer Tammer, 2010/07/31
- Re: iconv test on AIX 7.1BETA, Bruno Haible, 2010/07/31
- Re: iconv test on AIX 7.1BETA, Rainer Tammer, 2010/07/31
- Re: iconv test on AIX 7.1BETA, Bruno Haible, 2010/07/31
- Re: iconv test on AIX 7.1BETA, Rainer Tammer, 2010/07/31
- linkat test on AIX 7.1BETA, Bruno Haible, 2010/07/30
- Re: linkat test on AIX 7.1BETA, Rainer Tammer, 2010/07/31
- Re: linkat test on AIX 7.1BETA,
Bruno Haible <=
- Re: linkat test on AIX 7.1BETA, Rainer Tammer, 2010/07/31
- Re: linkat test on AIX 7.1BETA, Bruno Haible, 2010/07/31
- fchownat test on AIX 7.1BETA, Bruno Haible, 2010/07/30
- Re: fchownat test on AIX 7.1BETA, Rainer Tammer, 2010/07/31
- Re: fchownat test on AIX 7.1BETA, Bruno Haible, 2010/07/31
- Re: fchownat test on AIX 7.1BETA, Rainer Tammer, 2010/07/31
- Re: fchownat test on AIX 7.1BETA, Bruno Haible, 2010/07/31
- utimens, utimensat tests on AIX 7.1BETA, Bruno Haible, 2010/07/30
- Re: utimens, utimensat tests on AIX 7.1BETA, Eric Blake, 2010/07/30
- duplocale test on AIX 7.1BETA, Bruno Haible, 2010/07/30