public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
* [Bug ada/55119] New: Ada.Directories only handles files under 2GB @ 2012-10-29 15:56 simon at pushface dot org 2012-10-29 21:58 ` [Bug ada/55119] " simon at pushface dot org ` (2 more replies) 0 siblings, 3 replies; 4+ messages in thread From: simon at pushface dot org @ 2012-10-29 15:56 UTC (permalink / raw) To: gcc-bugs http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55119 Bug #: 55119 Summary: Ada.Directories only handles files under 2GB Classification: Unclassified Product: gcc Version: 4.7.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: ada AssignedTo: unassigned@gcc.gnu.org ReportedBy: simon@pushface.org In adaint.c, __gnat_stat_to_attr says /* st_size may be 32 bits, or 64 bits which is converted to long. We don't return a useful value for files larger than 2 gigabytes in either case. */ attr->file_length = statbuf.st_size; /* all systems */ where attr->file_length is a long. This fails with large files on 64-bit filesystems (eg, Mac OS X). I _think_ that a simple fix would be, in adaint.h, to define file_attributes.file_length as a long long. ^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug ada/55119] Ada.Directories only handles files under 2GB 2012-10-29 15:56 [Bug ada/55119] New: Ada.Directories only handles files under 2GB simon at pushface dot org @ 2012-10-29 21:58 ` simon at pushface dot org 2023-10-17 14:19 ` simon at pushface dot org 2023-10-17 16:28 ` ebotcazou at gcc dot gnu.org 2 siblings, 0 replies; 4+ messages in thread From: simon at pushface dot org @ 2012-10-29 21:58 UTC (permalink / raw) To: gcc-bugs http://gcc.gnu.org/bugzilla/show_bug.cgi?id=55119 --- Comment #1 from simon at pushface dot org 2012-10-29 21:57:02 UTC --- (In reply to comment #0) > where attr->file_length is a long. And on Mac OS X, sizeof(long) is 8. So there isn't a problem there (but the comment in adaint.c is still wrong). Are there systems where the size of the largest file can't be held in a long? Shouldn't attr->file_length be an off_t? ^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug ada/55119] Ada.Directories only handles files under 2GB 2012-10-29 15:56 [Bug ada/55119] New: Ada.Directories only handles files under 2GB simon at pushface dot org 2012-10-29 21:58 ` [Bug ada/55119] " simon at pushface dot org @ 2023-10-17 14:19 ` simon at pushface dot org 2023-10-17 16:28 ` ebotcazou at gcc dot gnu.org 2 siblings, 0 replies; 4+ messages in thread From: simon at pushface dot org @ 2023-10-17 14:19 UTC (permalink / raw) To: gcc-bugs https://gcc.gnu.org/bugzilla/show_bug.cgi?id=55119 --- Comment #2 from simon at pushface dot org --- I think this is OBE: fixed 2014-08-01, r213412, by making attr->file_length __int64. The comment in adaint.c is still wrong! Just tested on macOS with a 5GB download. ^ permalink raw reply [flat|nested] 4+ messages in thread
* [Bug ada/55119] Ada.Directories only handles files under 2GB 2012-10-29 15:56 [Bug ada/55119] New: Ada.Directories only handles files under 2GB simon at pushface dot org 2012-10-29 21:58 ` [Bug ada/55119] " simon at pushface dot org 2023-10-17 14:19 ` simon at pushface dot org @ 2023-10-17 16:28 ` ebotcazou at gcc dot gnu.org 2 siblings, 0 replies; 4+ messages in thread From: ebotcazou at gcc dot gnu.org @ 2023-10-17 16:28 UTC (permalink / raw) To: gcc-bugs https://gcc.gnu.org/bugzilla/show_bug.cgi?id=55119 Eric Botcazou <ebotcazou at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |RESOLVED Target Milestone|--- |5.0 Resolution|--- |FIXED --- Comment #3 from Eric Botcazou <ebotcazou at gcc dot gnu.org> --- The comment should probably go away indeed. ^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2023-10-17 16:28 UTC | newest] Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed) -- links below jump to the message on this page -- 2012-10-29 15:56 [Bug ada/55119] New: Ada.Directories only handles files under 2GB simon at pushface dot org 2012-10-29 21:58 ` [Bug ada/55119] " simon at pushface dot org 2023-10-17 14:19 ` simon at pushface dot org 2023-10-17 16:28 ` ebotcazou at gcc dot gnu.org
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).