View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0000596 | file | General | public | 2024-12-20 03:04 | 2024-12-20 03:04 |
Reporter | Anton Monroe | Assigned To | |||
Priority | normal | Severity | minor | Reproducibility | N/A |
Status | new | Resolution | open | ||
Product Version | 5.46 | ||||
Summary | 0000596: End-Of-File character 0x1A | ||||
Description | On OS/2 it is not uncommon to see older text files that end with an End-Of-File character 0x1A. Maybe it was inherited from some IBM mainframe operating system? It is obsolete and useless, but until a few years ago OS/2 came with a text editor that created files like that, and there are sure to be people still using it. Even the current version of OS/2 ships with some text files with EOF characters. The problem is that 'file' describes all of those text files as simply "data", which is not very helpful. Would it be reasonable to include character 0x1A in the list of "ASCII" characters? I =think= it would be just a matter of changing one letter in /src/encoding.c. See the comments in that file. I changed line 243 from F, F, F, F, F, F, F, F, F, F, F, T, F, F, F, F, /* 0x1X */ to F, F, F, F, F, F, F, F, F, F, T, T, F, F, F, F, /* 0x1X */ then recompiled 'file' and it does what I want. But I don't know enough C to be sure if anything else is needed or what side-effects there might be. Of course, it would also be nice if 'file' also mentioned the EOF. Something like "ASCII text, with CRLF line terminators, with End-Of-File character". I have seen an ASCII chart that labels that control character as "SUB" rather than "EOF". I don't know what to make of that. | ||||
Tags | No tags attached. | ||||
Date Modified | Username | Field | Change |
---|---|---|---|
2024-12-20 03:04 | Anton Monroe | New Issue |