lkml.org 
[lkml]   [2007]   [Feb]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [patch] x86-64 ext2/ext3 datestamp problem
Markus Rechberger wrote:
> Hi,
>
> there is an issue with ext2/ext3 date stamps, if someone creates a file
> with a timestamp between 1902 and 1970(epoch 0) it will overflow and
> result in a higher date than 2038.
>
> $ touch --date "1905-01-01" test
> $ ls -lah test
> -rw-r--r-- 1 root root 0 Jan 1 1905 test (this is a cached value here)
> (remount the partition/clear the cache)
> $ ls -lah test
> -rw-r--r-- 1 root root 0 Feb 6 2041 test
>
> 10000101101111001100011001110000 .. -2051226000 (1905)
> 10000101101111001100011001110000 .. 2243741296 (2041)
>
> this was tested against linus git tree
>

I believe the timestamp fields in ext2/ext3 are defined as unsigned.

-hpa
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2007-02-06 22:53    [W:0.037 / U:1.200 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site