MelbourneDeveloper / Device.Net

A C# cross platform connected device framework
MIT License
628 stars 121 forks source link

Handle write buffer length of zero #217

Closed brendonparker closed 3 years ago

brendonparker commented 3 years ago

Addresses #199

For a device that is read-only, the write buffer size/length comes back as zero. The code to open the stream then throws an exception.

Proposed solution. Return Stream.Null under that condition.

brendonparker commented 3 years ago

Going to close this and re-open against the develop branch