Anonymous | Login | 2024-10-09 03:42 UTC |
Main | My View | View Issues | Change Log | Docs |
Viewing Issue Simple Details [ Jump to Notes ] | [ Issue History ] [ Print ] | ||||||
ID | Category | Severity | Type | Date Submitted | Last Update | ||
0001807 | [1003.1(2016/18)/Issue7+TC2] Shell and Utilities | Comment | Clarification Requested | 2024-02-03 01:20 | 2024-03-28 16:23 | ||
Reporter | cquike | View Status | public | ||||
Assigned To | |||||||
Priority | normal | Resolution | Rejected | ||||
Status | Closed | ||||||
Name | Enrique Garcia | ||||||
Organization | |||||||
User Reference | |||||||
Section | 2.7 Redirection | ||||||
Page Number | (page or range of pages) | ||||||
Line Number | (Line or range of lines) | ||||||
Interp Status | --- | ||||||
Final Accepted Text | |||||||
Summary | 0001807: Allow number of redirection open files to be up to OPEN_MAX / 2 - 1 | ||||||
Description |
The redirection description states that numbers are used to represent the file descriptors and that "all implementations shall support at least 0 to 9, inclusive, for use by the application". The restriction to have "at least 9" seems a bit low to me, given that the implementation can support up to OPEN_MAX file descriptors. There are many pages in Internet that include examples like "exec 200<lock.file" that will fail in POSIX shells that don't allow more than 9 in the file descriptor. Some shells, like dash (which by the way has a limit of strictly 9), duplicates the original file descriptor (https://git.kernel.org/pub/scm/utils/dash/dash.git/tree/src/TOUR), [^] so in order to avoid issues with those implementations the file descriptor number shouldn't not be larger than OPEN_MAX / 2 - 1. |
||||||
Desired Action |
On section "2.7 Redirection" of "Shell Command Language" change: ...The largest possible value is implementation-defined; however, all implementations shall support at least 0 to 9, inclusive, for use by the application.... to: ...The largest possible value shall be OPEN_MAX / 2 - 1, inclusive, for use by the application, where OPEN_MAX is defined in sysconf.... |
||||||
Tags | No tags attached. | ||||||
Attached Files | |||||||
|
Mantis 1.1.6[^] Copyright © 2000 - 2008 Mantis Group |