Fix filestream read
Fix use-with issue #508