Better error message if writing read-only streams
Merge pull request #260 from botic/textstream-writable

Better error message if writing read-only streams, fixes #245