------ art_113954_1104990.1153479132774 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: quoted-printable Content-Disposition: inline On 7/21/06, axel.friedrich_smail / gmx.de <axel.friedrich_smail / gmx.de> wrote: > > Hello all, > > is there a way to do an io.write _with a certain buffer size_ ? > > I need to do the same as somebody else did in TcL like this: > > fconfigure $file -buffersize 16 -buffering none -encoding binary > -translation binary > > puts -nonewline $file [binary format "h*" $string] > > Thanks Not as such I am afraid. If you do a write of your data having the size you need and flush the stream, is that not good enough? If I understand correctly you have alas no control over the OS buffer of the underlying stream. flushing the stream empties the Ruby buffer but not more. Cheers Robert Axel > > OS: Linux > Ruby 1.8.4 > > > -- Deux choses sont infinies : l'univers et la bóŐise humaine ; en ce qui concerne l'univers, je n'en ai pas acquis la certitude absolue. - Albert Einstein ------ art_113954_1104990.1153479132774--