I was looking for a FAQ on the site to see if it was allowed to open topics not related to bugs or improvements but I didn't find anything. And about manipulating bits in a file I meant it literally, it's just as I said above, I thin...stiuna (Juan Gregorio)
@xtkoba Hey thanks, your code gave me a great idea, with some modifications I can do what I needed. Very helpful. *(Just in case the '_writeSince_' thing is still an open question, hopefully someone can help with that).* stiuna (Juan Gregorio)
xtkoba (Tee KOBAYASHI) wrote in #note-3: > I would not even concatenate any strings and would `push` them to an array, as if they were immutable (like in Go language for example). But in the end that information will have to be writt...stiuna (Juan Gregorio)
@xtkoba But use this: ``` ruby # [header, str] data = ["", ""] data[1] << "some data" ``` Or this: ``` ruby data = {:header => "", :str => ""} data[:str] << "some data" ``` Isn't this slower than just using a string directly? `...stiuna (Juan Gregorio)
In my program a string increases considerably in size inside a loop, at the end of that loop a header is created that will have to go to the beginning of that string. During the whole loop: ``` ruby str << "some data" ``` At...stiuna (Juan Gregorio)
Can you try on a different machine to check if this is a local problem? Unfortunately I don't have another computer to test the bug with, what version of ruby do you use?stiuna (Juan Gregorio)
The first byte of my file starts with the value **'1A'** . Then: ``` ruby descriptor = IO.sysopen(filePath) file2Read = IO.new(descriptor) file2Read.sysseek(0) p file2Read.sysread(2).unpack('H*') #=> "EOFError (end of file r...stiuna (Juan Gregorio)
> pp Dir['/tmp/**/**/'] Hello, I loved your alternative, from now on I'll use Dir. Regarding the "bug" of Find I think I can prove it one of these days I report it.stiuna (Juan Gregorio)