bug-indent
[Top][All Lists]
Advanced

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

Re: Patch to make GNU indent work on 64-bit file systems


From: Petr Pisar
Subject: Re: Patch to make GNU indent work on 64-bit file systems
Date: Tue, 26 Mar 2013 14:40:05 +0100
User-agent: Mutt/1.5.21 (2010-09-15)

On Mon, Mar 25, 2013 at 01:43:19PM -0700, Eric Fischer wrote:
> Indent doesn't work on file systems with 64-bit inode numbers because calls
> to fstat() will overflow and fail.
> 
> Here is a minimal patch to make it use fstat64() instead, also at
> https://github.com/ericfischer/indent/commit/b9e8ee5c9b0e6b36737fab5cc821dfc7f2f57237
> 
I've already posted patch
<http://lists.gnu.org/archive/html/bug-indent/2013-02/msg00001.html>
targeting the same issue.

Your patch forces stat64 unconditionally which is not portable. Moreover the
indent itself does not handle 64-bit file size. My patch makes indent 64-bit
safe while still using stat() and struct stat. 64-bit interface can be enabled
but putting -D_FILE_OFFSET_BITS=64 to CFLAGS at configure time.

-- Petr

Attachment: pgpPqOXmXKbnw.pgp
Description: PGP signature


reply via email to

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