mozilla / webrtc-sdp

Rust SDP parser for WebRTC
Mozilla Public License 2.0
155 stars 30 forks source link

Should parsing an empty document yield specific error? #181

Open na-g opened 5 years ago

na-g commented 5 years ago

@nils-ohlmeier, what should happen when an empty document is parsed?

nils-ohlmeier commented 5 years ago

Well we do have a test verifying that it returns an error https://github.com/mozilla/webrtc-sdp/blob/master/src/lib.rs#L1297

What would be arguments to make this a success instead?

na-g commented 5 years ago

I have updated the question to ask if we want to yield a specific error (which would be matchable) if the document is empty.

nils-ohlmeier commented 5 years ago

Yes that probably makes sense to improve.