Overview
| Artifact ID: | 9bb3a529ef9f9c8004530691c00b9555dd87f950 |
|---|---|
| Ticket: | 558932ffffffffffffffffffffffffffffffffff
read one byte: fconfigure -buffersize 1 |
| User & Date: | dgp on 2016-08-24 12:15:49 |
Changes
- assignee changed to: "dgp"
- closedate changed to: "2457625.01099422"
- closer changed to: "dgp"
- comment changed to:
Allow read(n) to read one byte, i.e. a system call of read(2) asks for one byte. At the moment fconfigure(n) accepts a -buffersize argument but it has a minimum size of 10, perhaps this minimun could be 1 instead. It seems really bad not being able to do a read(fd, buf, 1) in tcl. If you do a "read $chan 1" a system call read is performed with the "buffersize" specified in fconfigure or some default (4k on Linux). So, if you do fconfigure $chan -buffersize 10 read $chan 1 a read(fd, buf, 10) system call is issued. So far, so good. However, you cannot specify a -buffersize of less than 10. Actually, fconfigure accepts it but no reads are ever issued. regards, john
- icomment:
This was fixed in 2005.
- login: "dgp"
- mimetype: "text/plain"
- resolution changed to: "Out of Date"
- severity changed to: "Minor"
- status changed to: "Closed"