[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
test-utimens.h:105: assertion failed
From: |
Simon Josefsson |
Subject: |
test-utimens.h:105: assertion failed |
Date: |
Fri, 30 Oct 2009 09:32:14 +0100 |
User-agent: |
Gnus/5.110011 (No Gnus v0.11) Emacs/23.1 (gnu/linux) |
A (f)utimens test fail on Ubuntu 8.04 LTS:
../../gltests/test-utimens.h:105: assertion failed
FAIL: test-fdutimensat
../../gltests/test-futimens.h:109: assertion failed
FAIL: test-futimens
../../gltests/test-utimens.h:105: assertion failed
FAIL: test-utimens
Reproduce with:
gnulib-tool --test --with-tests utimens
I can't reproduce on current debian testing, so it is likely an old bug.
The code is:
{
struct timespec ts[2] = { { BILLION, UTIME_OMIT }, { 0, UTIME_NOW } };
ASSERT (func (BASE "file", ts) == 0);
^^^
That line fails. Changing the code slightly, I see that the return code
is -1 on this system.
ASSERT (stat (BASE "file", &st2) == 0);
ASSERT (st2.st_atime == Y2K);
ASSERT (0 <= get_stat_atime_ns (&st2));
ASSERT (get_stat_atime_ns (&st2) < BILLION / 2);
/* See comment above about this utimecmp call. */
ASSERT (0 <= utimecmp (BASE "file", &st2, &st1, UTIMECMP_TRUNCATE_SOURCE));
}
/Simon
- test-utimens.h:105: assertion failed,
Simon Josefsson <=