[Vm-dev] Re: [squeak-dev] Linux VM can't read files from /proc
Alexander Lazarević
laza at blobworks.com
Mon Feb 21 23:28:23 UTC 2011
2011/2/21 Bert Freudenberg <bert at freudenbergs.de>
>
> On 21.02.2011, at 14:19, Alexander Lazarević wrote:
>
> > Ah, you're right. The Squeak VM gets the file size via stat and does not
> just read the contents from the file. So for squeak the file looks just
> empty.
>
> (FileStream readOnlyFileNamed: '/proc/self/environ') next: 1e6
>
> works for me
>
And so
(FileStream readOnlyFileNamed: '/proc/self/environ') upToEnd
also works nicely. conentsOfEntireFile (which is used by the FileList) looks
for a size which it gets from a stat and returns no content. Looking at the
strace log I was lead to believe it was the VM itself.
Thanks,
Bert
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.squeakfoundation.org/pipermail/vm-dev/attachments/20110222/19d6552e/attachment.htm
More information about the Vm-dev
mailing list