[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Bug-tar] Problem with fstatat on AIX 7.1
From: |
Paul Eggert |
Subject: |
Re: [Bug-tar] Problem with fstatat on AIX 7.1 |
Date: |
Wed, 31 Aug 2011 17:34:18 -0700 |
User-agent: |
Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.2.20) Gecko/20110805 Thunderbird/3.1.12 |
On 08/31/11 07:06, Kevin Brott wrote:
> If we do not use fstatat then tar builds and passes almost all of the checks
> (only the two sparse file ones fail).
> If we use fstatat, then almost all of the checks fail - because the resulting
> binary is dropping zero-byte files into the archives, and doesn't function.
>
> So either there is a bug or enough of a fundamental difference in the way AIX
> 7.1's new fstatat call works, that it's not usable with the way the existing
> GNU tar code is trying to use it.
It semmed pretty clear there is a bug there.
Unfortunately, the test program does not seem to expose the bug.
How about this test program instead? Please run it in a directory
where conftest.file has been created via "echo xxx >conftest.file".
If this test program works on AIX 7.1, can you modify it in a minor
way so that it correctly exposes the AIX bug? There must be some
way to do it, since 'tar' is doing it.
#include <fcntl.h>
#include <sys/stat.h>
int
main (void)
{
struct stat a;
struct stat b;
int fd = open (".", O_RDONLY);
if (fd < 0)
return 10;
if (fstatat (fd, "conftest.file", &a,
AT_SYMLINK_NOFOLLOW)
!= 0)
return 1;
if (lstat ("conftest.file", &b) != 0)
return 2;
if (a.st_size != b.st_size) return 3;
if (a.st_dev != b.st_dev) return 4;
if (a.st_ino != b.st_ino) return 5;
if (a.st_mode != b.st_mode) return 6;
if (a.st_nlink != b.st_nlink) return 7;
if (a.st_uid != b.st_uid) return 8;
if (a.st_gid != b.st_gid) return 9;
/* Don't check time members, to avoid caching issues. */
return 0;
}
- Re: [Bug-tar] [GNU tar 1.26] testsuite: 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 25 26 27 28 30 31 34 36 38 39 40 42 43 44 45 46 47 48 49 51 52 53 54 55 57 58 59 60 61 62 64 65 66 67 68 69 71 72 73 74 79 80 81 82 83 84 85 87 90 91 92, (continued)
- Re: [Bug-tar] [GNU tar 1.26] testsuite: 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 25 26 27 28 30 31 34 36 38 39 40 42 43 44 45 46 47 48 49 51 52 53 54 55 57 58 59 60 61 62 64 65 66 67 68 69 71 72 73 74 79 80 81 82 83 84 85 87 90 91 92, Kevin Brott, 2011/08/18
- Re: [Bug-tar] [GNU tar 1.26] testsuite: 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 25 26 27 28 30 31 34 36 38 39 40 42 43 44 45 46 47 48 49 51 52 53 54 55 57 58 59 60 61 62 64 65 66 67 68 69 71 72 73 74 79 80 81 82 83 84 85 87 90 91 92, Paul Eggert, 2011/08/18
- Re: [Bug-tar] [GNU tar 1.26] testsuite: 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 25 26 27 28 30 31 34 36 38 39 40 42 43 44 45 46 47 48 49 51 52 53 54 55 57 58 59 60 61 62 64 65 66 67 68 69 71 72 73 74 79 80 81 82 83 84 85 87 90 91 92, Kevin Brott, 2011/08/18
- Re: [Bug-tar] [GNU tar 1.26] testsuite: 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 25 26 27 28 30 31 34 36 38 39 40 42 43 44 45 46 47 48 49 51 52 53 54 55 57 58 59 60 61 62 64 65 66 67 68 69 71 72 73 74 79 80 81 82 83 84 85 87 90 91 92, Kevin Brott, 2011/08/18
- Re: [Bug-tar] [GNU tar 1.26] testsuite: 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 25 26 27 28 30 31 34 36 38 39 40 42 43 44 45 46 47 48 49 51 52 53 54 55 57 58 59 60 61 62 64 65 66 67 68 69 71 72 73 74 79 80 81 82 83 84 85 87 90 91 92, Paul Eggert, 2011/08/18
- Message not available
- Re: [Bug-tar] Problem with fstatat on AIX 7.1, Paul Eggert, 2011/08/18
- Re: [Bug-tar] Problem with fstatat on AIX 7.1, Kevin Brott, 2011/08/19
- Re: [Bug-tar] Problem with fstatat on AIX 7.1, Paul Eggert, 2011/08/30
- Re: [Bug-tar] Problem with fstatat on AIX 7.1, Bruno Haible, 2011/08/31
- Re: [Bug-tar] Problem with fstatat on AIX 7.1, Kevin Brott, 2011/08/31
- Re: [Bug-tar] Problem with fstatat on AIX 7.1,
Paul Eggert <=
- Re: [Bug-tar] Problem with fstatat on AIX 7.1, Kevin Brott, 2011/08/31
- Re: [Bug-tar] Problem with fstatat on AIX 7.1, Kevin Brott, 2011/08/31